Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
skip to main content
10.1145/2884781.2884856acmconferencesArticle/Chapter ViewAbstractPublication PagesicseConference Proceedingsconference-collections
research-article
Public Access

Synthesizing framework models for symbolic execution

Published: 14 May 2016 Publication History
  • Get Citation Alerts
  • Abstract

    Symbolic execution is a powerful program analysis technique, but it is difficult to apply to programs built using frameworks such as Swing and Android, because the framework code itself is hard to symbolically execute. The standard solution is to manually create a framework model that can be symbolically executed, but developing and maintaining a model is difficult and error-prone. In this paper, we present Pasket, a new system that takes a first step toward automatically generating Java framework models to support symbolic execution. Pasket's focus is on creating models by instantiating design patterns. Pasket takes as input class, method, and type information from the framework API, together with tutorial programs that exercise the framework. From these artifacts and Pasket's internal knowledge of design patterns, Pasket synthesizes a framework model whose behavior on the tutorial programs matches that of the original framework. We evaluated Pasket by synthesizing models for subsets of Swing and Android. Our results show that the models derived by Pasket are sufficient to allow us to use off-the-shelf symbolic execution tools to analyze Java programs that rely on frameworks.

    References

    [1]
    H. Albin-amiot, Y. gaël Guéhéneuc, and R. A. Kastler. Meta-Modeling Design Patterns: Application to Pattern Detection and Code Synthesis. In Workshop Automating OOSD Methods, pages 01--35, 2001.
    [2]
    T. R. Andersen. Add Logging at Class Load Time, Apr. 22 2008. https://today.java.net/article/2008/04/22/add-logging-class-load-time-java-instrumentation.
    [3]
    M. Antkiewicz, T. T. Bartolomei, and K. Czarnecki. Automatic extraction of framework-specific models from framework-based application code. In Proceedings of the Twenty-second IEEE/ACM International Conference on Automated Software Engineering, ASE '07, pages 214--223, 2007.
    [4]
    S. Blackshear, A. Gendreau, and B.-Y. E. Chang. Droidel: A general approach to android framework modeling. In SOAP, pages 19--25. ACM, 2015.
    [5]
    C. Cadar, D. Dunbar, and D. R. Engler. KLEE: unassisted and automatic generation of high-coverage tests for complex systems programs. In OSDI, pages 209--224, 2008.
    [6]
    Y. Cao, Y. Fratantonio, A. Bianchi, M. Egele, C. Kruegel, G. Vigna, and Y. Chen. Edgeminer: Automatically detecting implicit control flow transitions through the android framework. In NDSS '15, 2015.
    [7]
    M. Ceccarello and O. Tkachuk. Automated generation of model classes for java pathfinder. SIGSOFT Softw. Eng. Notes, 39(1):1--5, Feb. 2014.
    [8]
    S. Chiba. Load-Time Structural Reflection in Java. In ECOOP, pages 313--336, 2000.
    [9]
    L. Clapp, S. Anand, and A. Aiken. Modelgen: Mining explicit information flow specifications from concrete executions. In ISSTA, pages 129--140. ACM, 2015.
    [10]
    A. Demaille, R. Levillain, and B. Sigoure. TWEAST: A Simple and Effective Technique to Implement Concrete-syntax AST Rewriting Using Partial Parsing. In SAC, pages 1924--1929, 2009.
    [11]
    M. Fowler. InversionOfControl, June 2005. http://martinfowler.com/bliki/InversionOfControl.html.
    [12]
    E. Gamma, R. Helm, R. Johnson, and J. Vlissides. Design Patterns: Elements of Reusable Object-Oriented Software. Addison-Wesley Professional, 1994.
    [13]
    P. Godefroid and A. Taly. Automated Synthesis of Symbolic Instruction Encodings from I/O Samples. In PLDI, pages 441--452, 2012.
    [14]
    S. Gulwani, S. Jha, A. Tiwari, and R. Venkatesan. Synthesis of Loop-free Programs. In PLDI, pages 62--73, 2011.
    [15]
    S. Heule, M. Sridharan, and S. Chandra. Mimic: Computing models for opaque code. In European Software Engineering Conference and Foundations of Software Engineering (ESEC/FSE), pages 710--720. ACM, Sep 2015.
    [16]
    J. Jeon. Framework Synthesis for Symbolic Execution of Event-Driven Frameworks. PhD thesis, University of Maryland, College Park, Feb 2016.
    [17]
    J. Jeon, K. K. Micinski, and J. S. Foster. SymDroid: Symbolic Execution for Dalvik Bytecode. Technical Report CS-TR-5022, Department of Computer Science, University of Maryland, College Park, Jul 2012.
    [18]
    J. Jeon, K. K. Micinski, J. A. Vaughan, A. Fogel, N. Reddy, J. S. Foster, and T. Millstein. Dr. Android and Mr. Hide: Fine-grained Permissions in Android Applications. In ACM CCS Workshop on Security and Privacy in Smartphones and Mobile Devices (SPSM), pages 3--14, Oct 2012.
    [19]
    J. Jeon, X. Qiu, A. Solar-Lezama, and J. S. Foster. Adaptive Concretization for Parallel Program Synthesis. In Computer Aided Verification (CAV), volume 9207 of Lecture Notes in Computer Science, pages 377--394, Jul 2015.
    [20]
    J. Jeon, X. Qiu, A. Solar-Lezama, and J. S. Foster. JSketch: Sketching for Java. In European Software Engineering Conference and Foundations of Software Engineering (ESEC/FSE), Sep 2015.
    [21]
    S.-U. Jeon, J.-S. Lee, and D.-H. Bae. An automated refactoring approach to design pattern-based program transformations in Java programs. In Asia-Pacific Software Engineering Conference, pages 337--345, 2002.
    [22]
    S. Jha, S. Gulwani, S. A. Seshia, and A. Tiwari. Oracle-guided component-based program synthesis. In ICSE, pages 215--224, 2010.
    [23]
    M. Loy, R. Eckstein, D. Wood, J. Elliott, and B. Cole. Java swing, 2nd edition: Code examples, 2003. http://examples.oreilly.com/jswing2/code/.
    [24]
    P. C. Mehlitz, O. Tkachuk, and M. Ujma. JPF-AWT: Model checking GUI applications. In ASE, pages 584--587, 2011.
    [25]
    K. Micinski, J. Fetter-Degges, J. Jeon, J. S. Foster, and M. R. Clarkson. Checking Interaction-Based Declassification Policies for Android Using Symbolic Execution. In European Symposium on Research in Computer Security (ESORICS), Vienna, Austria, Sep 2015.
    [26]
    T. Mikkonen. Formalizing Design Patterns. In ICSE, pages 115--124, 1998.
    [27]
    Oracle Corporation. Using swing components: Examples, 2015. https://docs.oracle.com/javase/tutorial/uiswing/examples/components/.
    [28]
    T. Parr and K. Fisher. LL(*): The Foundation of the ANTLR Parser Generator. In PLDI, pages 425--436, 2011.
    [29]
    A. Pnueli and R. Rosner. On the Synthesis of an Asynchronous Reactive Module. In ICALP, pages 652--671, 1989.
    [30]
    N. Rungta, P. C. Mehlitz, and W. Visser. JPF Tutorial, ASE 2013, 2013. URL http://babelfish.arc.nasa.gov/trac/jpf/raw-attachment/wiki/presentations/start/ASE13-tutorial.pdf.
    [31]
    H. Samimi, R. Hicks, A. Fogel, and T. Millstein. Declarative mocking. In Proceedings of the 2013 International Symposium on Software Testing and Analysis, ISSTA 2013, pages 246--256, 2013.
    [32]
    R. Singh and A. Solar-Lezama. Synthesizing data structure manipulations from storyboards. In FSE, pages 289--299, 2011.
    [33]
    R. Singh, S. Gulwani, and A. Solar-Lezama. Automated Feedback Generation for Introductory Programming Assignments. In PLDI, pages 15--26, 2013.
    [34]
    A. Solar-Lezama. Program sketching. International Journal on Software Tools for Technology Transfer, 15 (5-6):475--495, 2013.
    [35]
    A. Solar-Lezama. The Sketch Programmers Manual, 2015. Version 1.6.7.
    [36]
    A. Solar-Lezama, R. Rabbah, R. Bodík, and K. Ebcioğlu. Programming by sketching for bit-streaming programs. In PLDI, pages 281--294, 2005.
    [37]
    A. Solar-Lezama, G. Arnold, L. Tancau, R. Bodik, V. Saraswat, and S. Seshia. Sketching stencils. In PLDI, pages 167--178, 2007.
    [38]
    A. Solar-Lezama, C. G. Jones, and R. Bodik. Sketching concurrent data structures. In PLDI, pages 136--148, 2008.
    [39]
    A. Udupa, A. Raghavan, J. V. Deshmukh, S. Mador-Haim, M. M. Martin, and R. Alur. TRANSIT: Specifying Protocols with Concolic Snippets. In PLDI, pages 287--296, 2013.
    [40]
    H. van der Merwe, O. Tkachuk, B. van der Merwe, and W. Visser. Generation of library models for verification of android applications. SIGSOFT Softw. Eng. Notes, 40(1):1--5, Feb. 2015.

    Cited By

    View all
    • (2022)Type-directed program synthesis for RESTful APIsProceedings of the 43rd ACM SIGPLAN International Conference on Programming Language Design and Implementation10.1145/3519939.3523450(122-136)Online publication date: 9-Jun-2022
    • (2022)Bootstrapping Library-Based SynthesisStatic Analysis10.1007/978-3-031-22308-2_13(272-298)Online publication date: 2-Dec-2022
    • (2021)SPOT: Testing Stream Processing Programs with Symbolic Execution and Stream SynthesizingApplied Sciences10.3390/app1117805711:17(8057)Online publication date: 30-Aug-2021
    • Show More Cited By

    Recommendations

    Comments

    Information & Contributors

    Information

    Published In

    cover image ACM Conferences
    ICSE '16: Proceedings of the 38th International Conference on Software Engineering
    May 2016
    1235 pages
    ISBN:9781450339001
    DOI:10.1145/2884781
    Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

    Sponsors

    Publisher

    Association for Computing Machinery

    New York, NY, United States

    Publication History

    Published: 14 May 2016

    Permissions

    Request permissions for this article.

    Check for updates

    Author Tags

    1. framework model
    2. program synthesis
    3. sketch
    4. symbolic execution

    Qualifiers

    • Research-article

    Funding Sources

    Conference

    ICSE '16
    Sponsor:

    Acceptance Rates

    Overall Acceptance Rate 276 of 1,856 submissions, 15%

    Upcoming Conference

    ICSE 2025

    Contributors

    Other Metrics

    Bibliometrics & Citations

    Bibliometrics

    Article Metrics

    • Downloads (Last 12 months)113
    • Downloads (Last 6 weeks)17
    Reflects downloads up to 11 Aug 2024

    Other Metrics

    Citations

    Cited By

    View all
    • (2022)Type-directed program synthesis for RESTful APIsProceedings of the 43rd ACM SIGPLAN International Conference on Programming Language Design and Implementation10.1145/3519939.3523450(122-136)Online publication date: 9-Jun-2022
    • (2022)Bootstrapping Library-Based SynthesisStatic Analysis10.1007/978-3-031-22308-2_13(272-298)Online publication date: 2-Dec-2022
    • (2021)SPOT: Testing Stream Processing Programs with Symbolic Execution and Stream SynthesizingApplied Sciences10.3390/app1117805711:17(8057)Online publication date: 30-Aug-2021
    • (2021)Active Learning for Inference and Regeneration of Applications that Access DatabasesACM Transactions on Programming Languages and Systems10.1145/343095242:4(1-119)Online publication date: 22-Jan-2021
    • (2021)FrameFix: Automatically Repairing Statically-Detected Directive Violations in Framework Applications2021 IEEE International Conference on Software Analysis, Evolution and Reengineering (SANER)10.1109/SANER50967.2021.00027(201-212)Online publication date: Mar-2021
    • (2021)Program Sketching by Automatically Generating Mocks from TestsComputer Aided Verification10.1007/978-3-030-81685-8_38(808-831)Online publication date: 15-Jul-2021
    • (2020)Tainting-Assisted and Context-Migrated Symbolic Execution of Android Framework for Vulnerability Discovery and Exploit GenerationIEEE Transactions on Mobile Computing10.1109/TMC.2019.293656119:12(2946-2964)Online publication date: 1-Dec-2020
    • (2020)Vision Paper: Grand Challenges in Resilience: Autonomous System Resilience through Design and Runtime MeasuresIEEE Open Journal of the Computer Society10.1109/OJCS.2020.30068071(155-172)Online publication date: 2020
    • (2019)Program synthesis with algebraic library specificationsProceedings of the ACM on Programming Languages10.1145/33605583:OOPSLA(1-25)Online publication date: 10-Oct-2019
    • (2019)Sample-Guided Automated Synthesis for CCSL SpecificationsProceedings of the 56th Annual Design Automation Conference 201910.1145/3316781.3317904(1-6)Online publication date: 2-Jun-2019
    • Show More Cited By

    View Options

    View options

    PDF

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader

    Get Access

    Login options

    Media

    Figures

    Other

    Tables

    Share

    Share

    Share this Publication link

    Share on social media