用于开发的自动堆布局操作
Automatic Heap Layout Manipulation for Exploitation
摘要:
堆布局操作是利用基于堆的内存损坏漏洞所不可或缺的。在本文中,我们提出了第一个自动的方法来解决这个问题,基于伪随机黑箱搜索。我们的方法搜索所需的输入,将基于堆的缓冲区溢出或下溢的源放置在利用开发人员或自动利用生成系统希望读取或损坏的堆分配对象旁边。我们提出了一个基准堆布局操作算法的框架,并使用它来评估我们的方法在几个现实世界的分配器,表明伪随机黑盒搜索可以是非常有效的。然后,我们提出了SHRIKE,一个新的系统,可以执行自动堆布局操作的PHP解释器,并可用于建设控制流劫持漏洞。从PHP的回归测试开始,SHRIKE发现以有用的方式与解释器堆交互的PHP代码片段,例如进行特定大小的分配和释放,或分配包含敏感数据(如指针)的对象。然后,SHRIKE使用我们的搜索算法将这些片段拼凑成程序,搜索一个实现所需堆布局的程序。SHRIKE允许漏洞利用开发人员专注于漏洞利用中的更高级别概念,并将堆布局约束的解决方案推迟到SHRIKE。我们证明了这一点,使用SHRIKE在建设一个控制流劫持利用PHP解释器。
英文摘要:
Heap layout manipulation is integral to exploiting heap-based memory corruption vulnerabilities. In this paper we present the first automatic approach to the problem, based on pseudo-random black-box search. Our approach searches for the inputs required to place the source of a heap-based buffer overflow or underflow next to heap-allocated objects that an exploit developer, or automatic exploit generation system, wishes to read or corrupt. We present a framework for benchmarking heap layout manipulation algorithms, and use it to evaluate our approach on several real-world allocators, showing that pseudo-random black box search can be highly effective. We then present SHRIKE, a novel system that can perform automatic heap layout manipulation on the PHP interpreter and can be used in the construction of control-flow hijacking exploits. Starting from PHP's regression tests, SHRIKE discovers fragments of PHP code that interact with the interpreter's heap in useful ways, such as making allocations and deallocations of particular sizes, or allocating objects containing sensitive data, such as pointers. SHRIKE then uses our search algorithm to piece together these fragments into programs, searching for one that achieves a desired heap layout. SHRIKE allows an exploit developer to focus on the higher level concepts in an exploit, and to defer the resolution of heap layout constraints to SHRIKE. We demonstrate this by using SHRIKE in the construction of a control-flow hijacking exploit for the PHP interpreter.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。