Skip to main content
QUICK REVIEW

[论文解读] On Benchmarking the Capability of Symbolic Execution Tools with Logic Bombs

Hui Xu, Zirui Neil Zhao|arXiv (Cornell University)|Dec 5, 2017
Software Testing and Debugging Techniques参考文献 37被引用 3
一句话总结

本文提出了一种细粒度、高效的符号执行工具基准测试框架,采用逻辑炸弹——即仅在特定挑战(如浮点数运算、符号内存)被正确处理时才会触发的小型、针对性程序——来评估工具性能。该方法对KLEE、Angr和Triton在12项挑战中进行了评估,结果显示Angr表现优于其他工具,成功解决了27个测试用例中的21个,而Triton在浮点数运算和复杂外部调用方面表现不佳。

ABSTRACT

Symbolic execution now becomes an indispensable technique for software testing and program analysis. There are several symbolic execution tools available off-the-shelf, and we need a practical benchmark approach to learn their capabilities. Therefore, this paper introduces a novel approach to benchmark symbolic execution tools in a fine-grained and efficient manner. In particular, our approach evaluates the performance of such tools against the known challenges faced by general symbolic execution techniques, such as floating-point numbers and symbolic memories. To this end, we first survey related papers and systematize the challenges of symbolic execution. We extract 12 distinct challenges from the literature and categorize them into two categories: symbolic-reasoning challenges and path-explosion challenges. Then, we develop a dataset of logic bombs and a framework to benchmark symbolic execution tools automatically. For each challenge, our dataset contains several logic bombs, each of which is guarded by a specific challenging problem. If a symbolic execution tool can find test cases to trigger logic bombs, it indicates that the tool can handle the corresponding problems. We have conducted real-world experiments with three popular symbolic execution tools: KLEE, Angr, and Triton. Experimental results show that our approach can reveal their capabilities and limitations in handling particular issues accurately and efficiently. The benchmark process generally takes only dozens of minutes to evaluate a tool. We release our dataset on GitHub as open source, with an aim to better facilitate the community to conduct future work on benchmarking symbolic execution tools.

研究动机与目标

  • 为解决符号执行工具缺乏细粒度、无偏见的评估方法的问题,该方法不依赖于真实程序的变异性。
  • 识别并系统化整理阻碍符号执行的关键挑战,将其分类为符号推理挑战和路径爆炸挑战。
  • 设计一种可扩展、自动化的基准测试框架,利用逻辑炸弹隔离并测试符号执行工具的特定能力。
  • 通过标准化的逻辑炸弹数据集,对主流符号执行工具(KLEE、Angr、Triton)进行实证评估,揭示其优势与局限性。
  • 将基准测试数据集和框架作为开源资源发布,以支持社区未来对工具的评估与开发。

提出的方法

  • 系统性地从文献中调研符号执行中的12项不同挑战,将其分类为符号推理挑战(如浮点数、符号内存)和路径爆炸挑战(如循环、外部调用)。
  • 设计一组最小化、自包含的逻辑炸弹数据集——每个逻辑炸弹由特定挑战保护——使得成功执行将触发逻辑炸弹,从而表明工具具备相应能力。
  • 构建一个自动化基准测试框架,将逻辑炸弹编译为二进制文件,批量运行符号执行工具,并验证测试用例的正确性。
  • 使用小型、聚焦的程序以最小化副作用并减少符号执行时间,确保基准测试的效率与准确性。
  • 对Angr和Triton等工具采用二进制级别分析,而对KLEE则采用源代码级别分析,以确保在不同工具范式间实现公平比较。
  • 通过检查生成的测试用例是否触发逻辑炸弹来验证结果,从而确认底层挑战已被正确解决。

实验结果

研究问题

  • RQ1如何以细粒度、可复现且无偏见的方式评估符号执行工具,且不依赖于真实程序的特性?
  • RQ2哪些具体挑战(如浮点数运算、符号内存)最严重地限制了符号执行工具的有效性?
  • RQ3主流符号执行工具——KLEE、Angr和Triton——在处理复杂符号推理和路径爆炸挑战方面的能力如何?
  • RQ4基于逻辑炸弹的基准测试方法能否准确且高效地揭示不同工具在多样化符号执行挑战中的特定优势与不足?
  • RQ5当前符号执行工具在处理真实世界边缘情况(如嵌套数组、函数指针和外部函数调用)时存在哪些实际局限性?

主要发现

  • Angr成功解决了27个逻辑炸弹用例中的21个,表明其在符号推理和路径爆炸挑战方面优于KLEE和Triton。
  • KLEE解决了9个用例,主要在使用STP求解器时表现出色,尤其在数组和符号跳转处理方面,但在C++特定功能(如vector和list)上失败。
  • Triton仅解决了3个用例,主要由于缺乏对浮点数运算和复杂外部函数调用(如`atof`)的支持。
  • Angr成功处理了五个浮点数用例中的两个,但在所有需要通过`atof`进行十进制输入转换的用例中均失败,表明其在外部函数建模方面存在局限。
  • KLEE因数组推理能力不足,在两级数组挑战中失败,而Angr成功解决,凸显了求解器级别数组支持的重要性。
  • 二进制级别符号执行工具(Angr、Triton)在应对低级别挑战(如`jmp`指令和栈布局问题)方面比源代码级别工具(如KLEE)更具鲁棒性。

更好的研究,从现在开始

从阅读论文到最终审阅,大幅缩短您的研究时间。

无需绑定信用卡

本解读由 AI 生成,并经人工编辑审核。