论文标题

迈向自动化的扩展和仪器的传统密码可执行文件:扩展版本

Towards Automated Augmentation and Instrumentation of Legacy Cryptographic Executables: Extended Version

论文作者

Eldefrawy, Karim, Locasto, Michael, Rattanavipanon, Norrathep, Saidi, Hassen

论文摘要

加密库中的实现缺陷,潜在的加密原始图中的设计缺陷以及使用两者的协议中的弱点都可以导致软件中可剥削的漏洞。手动解决此类问题是具有挑战性和消耗资源的,尤其是在维护包含破碎或过时的密码学的旧软件时,并且可能无法提供源代码。尽管有现有的工作来识别加密原语(通常是在恶意软件分析的背景下),但此前的工作都没有集中于在识别出更强(或更安全的)之后替换此类原语。本文探讨了设计和实施工具链的可行性,用于增强和遗产软件的加密可执行文件(Alice)。爱丽丝的关键特征是:(i)自动检测和提取从二进制文件中的弱或损坏的加密原语的实现,而无需源代码或调试符号,(ii)确定使用此类原始词的上下文和范围,在这些上下文和范围中,在使用更稳固的实施方面替换此类替换的效果,并替换了更稳定的弱点,并替换了更稳定的实施方法,并替换了更稳定的实现。我们证明了我们在加密哈希功能方面的方法的实际可行性,该功能具有多个流行的加密库和各种复杂性的现实计划。我们的实验结果表明,即使在大型二进制文件中(我们测试了最高1.5mb的大小),同时保留了原始二进制文件的现有功能,并且在重新编写的二进制文件中,也可以保留最小的执行时间,即使在大型二进制文件中,Alice也可以定位和替换不安全的哈希功能。我们还通过https://github.com/sri-csl/alice开源爱丽丝代码。

Implementation flaws in cryptographic libraries, design flaws in underlying cryptographic primitives, and weaknesses in protocols using both, can all lead to exploitable vulnerabilities in software. Manually fixing such issues is challenging and resource consuming, especially when maintaining legacy software that contains broken or outdated cryptography, and for which source code may not be available. While there is existing work on identifying cryptographic primitives (often in the context of malware analysis), none of this prior work has focused on replacing such primitives with stronger (or more secure ones) after they have been identified. This paper explores feasibility of designing and implementing a toolchain for Augmentation and Legacy-software Instrumentation of Cryptographic Executables (ALICE). The key features of ALICE are: (i) automatically detecting and extracting implementations of weak or broken cryptographic primitives from binaries without requiring source code or debugging symbols, (ii) identifying the context and scope in which such primitives are used, and performing program analysis to determine the effects of replacing such implementations with more secure ones, and (iii) replacing implementations of weak primitives with those of stronger or more secure ones. We demonstrate practical feasibility of our approach on cryptographic hash functions with several popular cryptographic libraries and real-world programs of various levels of complexity. Our experimental results show that ALICE can locate and replace insecure hash functions, even in large binaries (we tested ones of size up to 1.5MB), while preserving existing functionality of the original binaries, and while incurring minimal execution-time overhead in the rewritten binaries. We also open source ALICE's code at https://github.com/SRI-CSL/ALICE.

扫码加入交流群

加入微信交流群

微信交流群二维码

扫码加入学术交流群,获取更多资源