skip to main content
10.1145/2976749.2978340acmconferencesArticle/Chapter ViewAbstractPublication PagesccsConference Proceedingsconference-collections
research-article
Public Access

CREDAL: Towards Locating a Memory Corruption Vulnerability with Your Core Dump

Authors Info & Claims
Published:24 October 2016Publication History

ABSTRACT

After a program has crashed and terminated abnormally, it typically leaves behind a snapshot of its crashing state in the form of a core dump. While a core dump carries a large amount of information, which has long been used for software debugging, it barely serves as informative debugging aids in locating software faults, particularly memory corruption vulnerabilities. A memory corruption vulnerability is a special type of software faults that an attacker can exploit to manipulate the content at a certain memory. As such, a core dump may contain a certain amount of corrupted data, which increases the difficulty in identifying useful debugging information (e.g. , a crash point and stack traces). Without a proper mechanism to deal with this problem, a core dump can be practically useless for software failure diagnosis. In this work, we develop CREDAL, an automatic tool that employs the source code of a crashing program to enhance core dump analysis and turns a core dump to an informative aid in tracking down memory corruption vulnerabilities. Specifically, CREDAL systematically analyzes a core dump potentially corrupted and identifies the crash point and stack frames. For a core dump carrying corrupted data, it goes beyond the crash point and stack trace. In particular, CREDAL further pinpoints the variables holding corrupted data using the source code of the crashing program along with the stack frames. To assist software developers (or security analysts) in tracking down a memory corruption vulnerability, CREDAL also performs analysis and highlights the code fragments corresponding to data corruption.

To demonstrate the utility of CREDAL, we use it to analyze 80 crashes corresponding to 73 memory corruption vulnerabilities archived in Offensive Security Exploit Database. We show that, CREDAL can accurately pinpoint the crash point and (fully or partially) restore a stack trace even though a crashing program stack carries corrupted data. In addition, we demonstrate CREDAL can potentially reduce the manual effort of finding the code fragment that is likely to contain memory corruption vulnerabilities.

References

  1. Abc2midi 2004--12-04 - multiple stack buffer overflow vulnerabilities. https://www.exploit-db.com/exploits/25019/.Google ScholarGoogle Scholar
  2. Analysis of nginx 1.3.9/1.4.0 stack buffer overflow and x64 exploitation (cve-2013--2028). http://www.vnsecurity.net/research/2013/05/21/analysis-of-nginx-cve-2013--2028.html.Google ScholarGoogle Scholar
  3. Apple quicktime (rtsp url handler) stack buffer overflow exploit. https://www.exploit-db.com/exploits/3064/.Google ScholarGoogle Scholar
  4. Asterisk <= 1.0.12 / 1.2.12.1 (chan_skinny) remote heap overflow (poc). https://www.exploit-db.com/exploits/2597/.Google ScholarGoogle Scholar
  5. Blender blenloader 2.x file processing integer overflow vulnerability. https://www.exploit-db.com/exploits/26915/.Google ScholarGoogle Scholar
  6. Da's dwarf page. https://www.prevanders.net/dwarf.html.Google ScholarGoogle Scholar
  7. Gaim <= 1.2.1 url handling remote stack overflow exploit. https://www.exploit-db.com/exploits/999/.Google ScholarGoogle Scholar
  8. libdisasm: x86 disassembler library. http://bastard.sourceforge.net/libdisasm.html.Google ScholarGoogle Scholar
  9. Libelf - free software directory. https://directory.fsf.org/wiki/Libelf.Google ScholarGoogle Scholar
  10. The libunwind project. http://www.nongnu.org/libunwind/.Google ScholarGoogle Scholar
  11. Linux programmer's manual. http://man7.org/linux/man-pages/man7/signal.7.html.Google ScholarGoogle Scholar
  12. The llvm compiler infrastructure. http://llvm.org/.Google ScholarGoogle Scholar
  13. Nginx 1.3.9--1.4.0 - dos poc. http://seclists.org/fulldisclosure/2013/Jul/att-90/ngxunlock_pl.bin.Google ScholarGoogle Scholar
  14. Offensive security exploit database archive. https://www.exploit-db.com/.Google ScholarGoogle Scholar
  15. Safari 5.02 - stack overflow denial of service. https://www.exploit-db.com/exploits/15558/.Google ScholarGoogle Scholar
  16. Sun java runtime environment 1.6 - web start jnlp file stack buffer overflow vulnerability. https://www.exploit-db.com/exploits/30284/.Google ScholarGoogle Scholar
  17. H. Cleve and A. Zeller. Locating causes of program failures. In Proceedings of the 27th International Conference on Software Engineering, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. D. D. I. F. Committee. Dwarf debugging information format (version 4). http://www.dwarfstd.org/doc/DWARF4.pdf, 2010.Google ScholarGoogle Scholar
  19. W. Cui, M. Peinado, S. K. Cha, Y. Fratantonio, and V. P. Kemerlis. Retracer: Triaging crashes by reverse execution from partial memory dumps. In Proceedings of the 38th International Conference on Software Engineering, 2016. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. Y. Dang, R. Wu, H. Zhang, D. Zhang, and P. Nobel. Rebucket: A method for clustering duplicate crash reports based on call stack similarity. In Proceedings of the 34th International Conference on Software Engineering, 2012. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. K. Glerum, K. Kinshumann, S. Greenberg, G. Aul, V. Orgovan, G. Nichols, D. Grant, G. Loihle, and G. Hunt. Debugging in the (very) large: Ten years of implementation and experience. In Proceedings of the ACM SIGOPS 22Nd Symposium on Operating Systems Principles, 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. S. Hangal and M. S. Lam. Tracking down software bugs using automatic anomaly detection. In Proceedings of the 24th International Conference on Software Engineering, 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. S. Horwitz, B. Liblit, and M. Polishchuk. Better debugging via output tracing and callstack-sensitive slicing. IEEE Transaction Software Engineering, 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  24. S. Kim, T. Zimmermann, and N. Nagappan. Crash graphs: An aggregated view of multiple crashes to improve crash triage. In Proceedings of the 2011 IEEE/IFIP 41st International Conference on Dependable Systems&Networks, 2011. Google ScholarGoogle ScholarDigital LibraryDigital Library
  25. V. Kuznetsov, L. Szekeres, M. Payer, G. Candea, R. Sekar, and D. Song. Code-pointer integrity. In 11th USENIX Symposium on Operating Systems Design and Implementation (OSDI 14), pages 147--163, Broomfield, CO, Oct. 2014. USENIX Association. Google ScholarGoogle ScholarDigital LibraryDigital Library
  26. B. Liblit and A. Aiken. Building a better backtrace: Techniques for postmortem program analysis. Technical report, 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  27. R. Manevich, M. Sridharan, S. Adams, M. Das, and Z. Yang. Pse: Explaining program failures via postmortem static analysis. In Proceedings of the 12th ACM SIGSOFT Twelfth International Symposium on Foundations of Software Engineering, 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  28. D. Molnar, X. C. Li, and D. A. Wagner. Dynamic test generation to find integer bugs in x86 binary linux programs. In Proceedings of the 18th Conference on USENIX Security Symposium, 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  29. S. Nagarakatte, J. Zhao, M. M. Martin, and S. Zdancewic. Softbound: Highly compatible and complete spatial memory safety for c. ACM Sigplan Notices, 44(6):245--258, 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  30. P. Ohmann. Making your crashes work for you (doctoral symposium). In Proceedings of the 2015 International Symposium on Software Testing and Analysis, 2015. Google ScholarGoogle ScholarDigital LibraryDigital Library
  31. P. Ohmann and B. Liblit. Cores, debugging, and coverage. Technical report, 2015.Google ScholarGoogle Scholar
  32. P. Ohmann and B. Liblit. Csiclipse: Presenting crash analysis data to developers. In Proceedings of the on Eclipse Technology eXchange, 2015. Google ScholarGoogle ScholarDigital LibraryDigital Library
  33. M. Polishchuk, B. Liblit, and C. W. Schulze. Dynamic heap type inference for program understanding and debugging. In Proceedings of the 34th Annual ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  34. M. Renieris and S. P. Reiss. Fault localization with nearest neighbor queries. In Proceedings of IEEE/ACM International Conference on Automated Software Engineering, 2003.Google ScholarGoogle ScholarCross RefCross Ref
  35. T. Reps, T. Ball, M. Das, and J. Larus. The use of program profiling for software maintenance with applications to the year 2000 problem. In Proceedings of the 6th European SOFTWARE ENGINEERING Conference, 1997. Google ScholarGoogle ScholarDigital LibraryDigital Library
  36. S. K. Sahoo, J. Criswell, C. Geigle, and V. Adve. Using likely invariants for automated software fault localization. In Proceedings of the Eighteenth International Conference on Architectural Support for Programming Languages and Operating Systems, 2013. Google ScholarGoogle ScholarDigital LibraryDigital Library
  37. R. Salkeld and G. Kiczales. Interacting with dead objects. In Proceedings of the 2013 ACM SIGPLAN International Conference on Object Oriented Programming Systems Languages & Applications, 2013. Google ScholarGoogle ScholarDigital LibraryDigital Library
  38. A. Schröter, N. Bettenburg, and R. Premraj. Do stack traces help developers fix bugs? In Proceedings of the 7th IEEE Working Conference on Mining Software Repositories, 2010.Google ScholarGoogle ScholarCross RefCross Ref
  39. K. Serebryany, D. Bruening, A. Potapenko, and D. Vyukov. Addresssanitizer: a fast address sanity checker. In Presented as part of the 2012 USENIX Annual Technical Conference (USENIX ATC 12), pages 309--318, 2012. Google ScholarGoogle ScholarDigital LibraryDigital Library
  40. M. Sharir and A. Pnueli. Two approaches to interprocedural data flow analysis. New York University. Courant Institute of Mathematical Sciences. Computer Science Department, 1978.Google ScholarGoogle Scholar
  41. R. E. Strom and D. M. Yellin. Extending typestate checking using conditional liveness analysis. IEEE Transaction Software Engineering, 1993. Google ScholarGoogle ScholarDigital LibraryDigital Library
  42. R. E. Strom and S. Yemini. Typestate: A programming language concept for enhancing software reliability. IEEE Transaction Software Engineering, 1986. Google ScholarGoogle ScholarDigital LibraryDigital Library
  43. R. Wu, H. Zhang, S.-C. Cheung, and S. Kim. Crashlocator: Locating crashing faults based on crash stacks. In Proceedings of the 2014 International Symposium on Software Testing and Analysis, 2014. Google ScholarGoogle ScholarDigital LibraryDigital Library
  44. D. Yuan, H. Mai, W. Xiong, L. Tan, Y. Zhou, and S. Pasupathy. Sherlog: Error diagnosis by connecting clues from run-time logs. In Proceedings of the Fifteenth Edition of ASPLOS on Architectural Support for Programming Languages and Operating Systems, 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  45. D. Yuan, J. Zheng, S. Park, Y. Zhou, and S. Savage. Improving software diagnosability via log enhancement. In Proceedings of the Sixteenth International Conference on Architectural Support for Programming Languages and Operating Systems, 2011. Google ScholarGoogle ScholarDigital LibraryDigital Library
  46. A. Zeller. Isolating cause-effect chains from computer programs. In Proceedings of the 10th ACM SIGSOFT Symposium on Foundations of Software Engineering, 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. CREDAL: Towards Locating a Memory Corruption Vulnerability with Your Core Dump

    Recommendations

    Comments

    Login options

    Check if you have access through your login credentials or your institution to get full access on this article.

    Sign in
    • Published in

      cover image ACM Conferences
      CCS '16: Proceedings of the 2016 ACM SIGSAC Conference on Computer and Communications Security
      October 2016
      1924 pages
      ISBN:9781450341394
      DOI:10.1145/2976749

      Copyright © 2016 ACM

      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]

      Publisher

      Association for Computing Machinery

      New York, NY, United States

      Publication History

      • Published: 24 October 2016

      Permissions

      Request permissions about this article.

      Request Permissions

      Check for updates

      Qualifiers

      • research-article

      Acceptance Rates

      CCS '16 Paper Acceptance Rate137of831submissions,16%Overall Acceptance Rate1,261of6,999submissions,18%

      Upcoming Conference

      CCS '24
      ACM SIGSAC Conference on Computer and Communications Security
      October 14 - 18, 2024
      Salt Lake City , UT , USA

    PDF Format

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader