在当前的计算机系统架构和软件生态环境下,ROP(return—oriented programming)等基于二进制代码重用的攻击技术被广泛用于内存漏洞利用.近年来,网络空间安全形势愈加严峻,学术界、工业界分别从攻击和防护的角度对二进制代码重用技术开展了大量研究.首先介绍了二进制代码重用技术的基础.然后分析了二进制代码重用攻击技术的演变和典型攻击向量.同时,对基于控制流完整性和随机化的防护方法进行了讨论,对工业界最新的二进制代码重用防护机制CET(control-flow enforcement technology)和CFG(control flow guard)进行了剖析.最后讨论了二进制代码重用技术今后的发展方向,包括潜在的攻击面和防御机制增强的思路.
Within the current commercial system achitecture and software ecosystem, code reuse techniques, such as ROP (return- oriented programming), are widely adopted to exploit memory vulnerabilities. Driven by the serve situation of cyberspace security, academical and industrial communities have carried out a great amount of research on binary code reuse from both defensive and offsensive perspevtives. This paper discusses the essence and basics of binary code reuse, along with an analysis of its technique roadmap and typical attack vectors. Corresponding defences and mitigations based on control flow integrity and memory randomization are analyzed as well. Dissections on CET (control flow enforcement technology) and CFG (control flow guard), two latest industrial techniques for binary code reuse mitigation, are presented. The future of binary code reuse, including protential attack vectors and possible mitigation strategies, is also discussed at the end of this paper.