Cross-language program slicing for dynamic web applications
Open Access
- 30 August 2015
- conference paper
- Published by Association for Computing Machinery (ACM)
- p. 369-380
Abstract
During software maintenance, program slicing is a useful technique to assist developers in understanding the impact of their changes. While different program-slicing techniques have been proposed for traditional software systems, program slicing for dynamic web applications is challenging since the client-side code is generated from the server-side code and data entities are referenced across different languages and are often embedded in string literals in the server-side program. To address those challenges, we introduce WebSlice, an approach to compute program slices across different languages for web applications. We first identify data-flow dependencies among data entities for PHP code based on symbolic execution. We also compute SQL queries and a conditional DOM that represents client-code variations and construct the data flows for embedded languages: SQL, HTML, and JavaScript. Next, we connect the data flows across different languages and across PHP pages. Finally, we compute a program slice for a given entity based on the established data flows. Running WebSlice on five real-world, open-source PHP systems, we found that, out of 40,670 program slices, 10% cross languages, 38% cross files, and 13% cross string fragments, demonstrating the potential benefit of tool support for cross-language program slicing in dynamic web applications.Keywords
Funding Information
- National Science Foundation (CCF-1318808, CCF-1018600, CNS-1223828, CCF-1349153, CCF-1320578, CCF-1413927)
This publication has 46 references indexed in Scilit:
- A vocabulary of program slicing-based techniquesACM Computing Surveys, 2012
- Applying static analysis for automated extraction of database interactions in web applicationsInformation and Software Technology, 2008
- Web Application Slicing in Presence of Dynamic Code GenerationAutomated Software Engineering, 2005
- A brief survey of program slicingACM SIGSOFT Software Engineering Notes, 2005
- An overview of program slicingSoftware Focus, 2001
- Conditioned program slicingInformation and Software Technology, 1998
- Program slicingInformation and Software Technology, 1998
- Program Slicing1996
- Dynamic program slicingInformation Processing Letters, 1988
- Information-flow and data-flow analysis of while-programsACM Transactions on Programming Languages and Systems, 1985