当前位置: X-MOL 学术IEEJ Trans. Electr. Electron. Eng. › 论文详情
Our official English website, www.x-mol.net, welcomes your feedback! (Note: you will need to create a separate account there.)
DFlow: A Data Flow Analysis Tool for C/C++
IEEJ Transactions on Electrical and Electronic Engineering ( IF 1 ) Pub Date : 2021-08-03 , DOI: 10.1002/tee.23467
Qiaoqiao Yan 1 , Yongjun Li 1 , Yuanhao Wu 1 , Jialong Zhou 1
Affiliation  

Abstract syntax trees (ASTs), control flow graphs (CFGs), and data flow analysis (DFA) are prerequisites for static and dynamic analysis and vulnerability detection for programs; thus, obtaining them is significant. Recently, many tools related to generating ASTs, CFGs, and DFA have been proposed. However, most tools can only construct ASTs, very few can construct ASTs and CFGs, and almost none can construct all three. The vast majority of AST, CFG, and DFA tools are for other languages (e.g., Java and Python), and while a few are for C/C++, they are implemented in other languages, creating complex working environments, and overreliance on other language-related libraries. To address these shortcomings, we present a DFA tool, DFlow, for C/C++. First, a lexical/grammatical analyzer generated by Flex and Bison is used to analyze the program. Second, an AST is constructed from the results; then, a CFG is obtained from the analysis results and the information from the AST. Finally, based on the AST and CFG, DFA is performed, and the vulnerabilities of simple programs are determined. We test some common vulnerable code and common weakness enumeration slicing code, which show the effectiveness of DFlow in program data flow analysis and vulnerability checking. The results show that our tool can implement ASTs, CFGs, and DFA, and we add some rules to the tool for vulnerability detection. © 2021 Institute of Electrical Engineers of Japan. Published by Wiley Periodicals LLC.

中文翻译:

DFlow:C/C++ 的数据流分析工具

摘要语法树(AST)、控制流图(CFG)和数据流分析(DFA)是程序进行静态和动态分析和漏洞检测的先决条件;因此,获得它们意义重大。最近,已经提出了许多与生成 AST、CFG 和 DFA 相关的工具。但是,大多数工具只能构建 AST,很少能构建 AST 和 CFG,几乎没有任何工具可以同时构建三者。绝大多数 AST、CFG 和 DFA 工具适用于其他语言(例如 Java 和 Python),而少数适用于 C/C++,它们是用其他语言实现的,创建了复杂的工作环境,并且过度依赖其他语言- 相关的图书馆。为了解决这些缺点,我们提出了一个用于 C/C++ 的 DFA 工具 DFlow。首先,使用由 Flex 和 Bison 生成的词法/语法分析器来分析程序。第二,根据结果​​构建 AST;然后,从分析结果和来自 AST 的信息中获得一个 CFG。最后基于AST和CFG进行DFA,判断简单程序的漏洞。我们测试了一些常见的漏洞代码和常见的漏洞枚举切片代码,展示了DFlow在程序数据流分析和漏洞检查中的有效性。结果表明,我们的工具可以实现 AST、CFG 和 DFA,并且我们在工具中添加了一些用于漏洞检测的规则。© 2021 日本电气工程师学会。由 Wiley Periodicals LLC 出版。并确定简单程序的漏洞。我们测试了一些常见的漏洞代码和常见的漏洞枚举切片代码,展示了DFlow在程序数据流分析和漏洞检查中的有效性。结果表明,我们的工具可以实现 AST、CFG 和 DFA,并且我们在工具中添加了一些用于漏洞检测的规则。© 2021 日本电气工程师学会。由 Wiley Periodicals LLC 出版。并确定简单程序的漏洞。我们测试了一些常见的漏洞代码和常见的漏洞枚举切片代码,展示了DFlow在程序数据流分析和漏洞检查中的有效性。结果表明,我们的工具可以实现 AST、CFG 和 DFA,并且我们在工具中添加了一些用于漏洞检测的规则。© 2021 日本电气工程师学会。由 Wiley Periodicals LLC 出版。
更新日期:2021-08-03
down
wechat
bug