Study of Statically Detecting Buffer Overflow in C/C++ Program
- Author
- WangWenJun
- Advisor
- LiuJian
- School
- Xi'an University of Electronic Science and Technology
- Major
- Computer Software and Theory
- Classification
- TP312.1 Programming language ALGOL
- Degree
- Master's thesis
- Year
- 2006
- Downloads
- 194
- Citations
- 3
Abstract
Statically detecting buffer overflow in C/C++ program is studied in this paper. Based on analyzing intermediate representation files generated by GCC front end, buffer overflow vulnerabilities are detected by embedding safety rules via syntax-directed translation.In order to make safety judgment in intra-procedural analysis, it is necessary to track variables’ information with the help of attribute computation. According to the original structure, it is clear to handle variables with scope and look up variables using their names. Appropriate pointer attribute design will effectively eliminate the confusion induced by pointer alias, thereby simplify analysis and increase precision of analysis. In order to detect vulnerabilities in inter-procedural analysis, limit condition is collected in a function and used later when called. The precondition checks prerequisite before function call, and the post condition records the effect after function call.
Table of contents
Abstract 3-4
Abstract 4-7
first chapter 7-11
1.1 Background 7-8
1.2 existing research 8-9
1.3 papers 9-11
the
buffer cross-border performance and solutions 11-19
2.1 buffer out of bounds of performance and analysis 11-12
2.2 based on the analysis of the abstract syntax tree 12-14
2.2.1 GCC compiler intermediate representation 12-13
2.2.2 abstract syntax tree node processing 13-14
2.3 XDCHECK overall design 14-19
2.3.1 detection tool architecture 14-16
2.3.2 buffer bounds checking module 16-19
the
key technologies of Chapter buffer boundary detection 19-25
3.1 array with pointer 19-22
3.1.1 array pointer 19-21
3.1.2 string and character array 21
3.1.3 pointer aliasing analysis 21-22
3.2 integer limit 22-23
3.2.1 cross-border issues integer processing 22-23
3.2.2 to track and record data 23
3.3 interprocedural analysis 23-25
3.3.1 before and after the set conditions generated 24
3.3.2 cross-process inspection 24-25
Chapter Design and Implementation of the buffer boundary detection 25-39
4.1 attributes of grammar symbols 25-27
4.1.1 pointer attribute design 25-26
4.1.2 properties of other types of variable design 26
4.1.3 Properties calculated 26-27
the
variables in the process within the 4.2 track 27-35
4.2.1 design ideas 27-30
4.2.1.1 scope management variables 27-29
4.2.1.2 variable names to find information 29
4.2.1.3 special handling control statements 29-30
4.2.2 organizational structure 30-31
4.2.3 Operation 31-33
4.2.3.1 operating variable information interface 31-33
4.2.3.2 operating scope information interface 33
4.2.4 intermediate file program analysis 33-35
4.3 buffer boundary detection 35-39
4.3.1 buffer boundary detection algorithm 35-37
4.3.2 dangerous library function security rules 37-39
Chapter V Conclusion 39-41
Acknowledgements 41-43
the
References 43-45
The
Appendix source instance 45-49
process analysis 45-47
two cross-process analysis 47-49
the
author reading during research 49
Related dissertations
- Static Security Detection of C Applications
- P2P worm design based on buffer overflow
- Research of Windows Buffer Overflow Exploits Technology Heap Spray
- Reasearch on Detection and Prevention Techniques of Buffer Overflow Attacking Code
- Research on Detecting Buffer Overflow in Binary Code
- Vulnerability Discovering and Its Use in Meteorological Network Security
- Design and Verification of Program Buffer Overflow Inspection Method
- Research on Memory Modeling Based Automatic Test Data Generation Technique
- The Research on Buffer Overflow Attack Defense Based on Trusted Execution Environment
- Research on Technology of Buffer Overflow Discovery Based on Hex-Rays
- Code-Reuse Attack Detection and Defense Based on Dynamic Binary Translation Framework
- Research and implementation of software encryption key protection
- Flow Control Strategies of LTE-Advanced Relay Networks
- Research on Key Technologies of Network Security Language
- Research on Some Issues of Software Vulnerability Testing
- Research on Software Design and Implementation Techniques for Non-Functional Requirements
- Vulnerability Attack and Defense and Vulnerability Database Design
- The Design and Implementation of a Static Analysis System in Source Code
- Research on Finding Windows Buffer Overflow Vulnerabilities by Security Patch Comparison
- Detecting Buffer Overflow in Binary Code by Analyzing Unsafe Functions