SAFER: Efficient and Error-Tolerant Binary Instrumentation
Soumyakant Priyadarshan, Huan Nguyen, Rohit Chouhan, R. Sekar
摘要
Recent advances in binary instrumentation have been focused on performance. By statically transforming the code to avoid additional runtime operations, systems such as Egalito and RetroWrite achieve near zero overheads. The safety of these static transformations relies on several assumptions: (a) errorfree and complete disassembly, (b) exclusive use of positionindependent code, and (c) code pointer identification that is free of both false positives and false negatives. Violations of these assumptions can cause an instrumented program to crash, or worse, experience delayed failures that corrupt data or compromise security. Many earlier binary instrumentation techniques (e.g., DynamoRio, Pin, and BinCFI) minimized such assumptions, but the price to be paid is a much higher overhead, especially for indirect-call-intensive (e.g., C++) applications. Thus, an open research question is whether the safety benefits of the earlier works can be combined with the performance benefits of recent works. We answer this question in the affirmative by presenting a new instrumentation technique that (a) tolerates the use of position-dependent code and common disassembly and static analysis errors, and (b) detects assumption violations at runtime before they can lead to undefined behavior. Our approach provides a fail-crash primitive for graceful shutdown or recovery. We achieve safe instrumentation without sacrificing performance, introducing a low overhead of about ∼ 2%.
问 Lune
几分钟读透这篇 Paper,不用再花一下午。
Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。
已有 5 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。
脉络
- Superset Disassembly: Statically Rewriting x86 Binaries Without Heuristics 引用了 Ramblr: Making Reassembly Great Again
- Scalable, Sound, and Accurate Jump Table Analysis 引用了 Ramblr: Making Reassembly Great Again
- Scalable, Sound, and Accurate Jump Table Analysis 引用了 SOK: (State of) The Art of War: Offensive Techniques in Binary Analysis
- RetroWrite: Statically Instrumenting COTS Binaries for Fuzzing and Sanitization 引用了 Superset Disassembly: Statically Rewriting x86 Binaries Without Heuristics
- RetroWrite: Statically Instrumenting COTS Binaries for Fuzzing and Sanitization 引用了 Ramblr: Making Reassembly Great Again
- RetroWrite: Statically Instrumenting COTS Binaries for Fuzzing and Sanitization 引用了 SOK: (State of) The Art of War: Offensive Techniques in Binary Analysis
- Accurate Disassembly of Complex Binaries Without Use of Compiler Metadata 引用了 Superset Disassembly: Statically Rewriting x86 Binaries Without Heuristics
- Accurate Disassembly of Complex Binaries Without Use of Compiler Metadata 引用了 RetroWrite: Statically Instrumenting COTS Binaries for Fuzzing and Sanitization
- Accurate Disassembly of Complex Binaries Without Use of Compiler Metadata 引用了 Ramblr: Making Reassembly Great Again
- Accurate Disassembly of Complex Binaries Without Use of Compiler Metadata 引用了 SOK: (State of) The Art of War: Offensive Techniques in Binary Analysis
- Analyzing Bytes: Pre-Disassembly Static Binary Analysis 引用了 Superset Disassembly: Statically Rewriting x86 Binaries Without Heuristics
- Analyzing Bytes: Pre-Disassembly Static Binary Analysis 引用了 Scalable, Sound, and Accurate Jump Table Analysis
- Analyzing Bytes: Pre-Disassembly Static Binary Analysis 引用了 RetroWrite: Statically Instrumenting COTS Binaries for Fuzzing and Sanitization
- Analyzing Bytes: Pre-Disassembly Static Binary Analysis 引用了 Accurate Disassembly of Complex Binaries Without Use of Compiler Metadata
- Analyzing Bytes: Pre-Disassembly Static Binary Analysis 引用了 Ramblr: Making Reassembly Great Again
- Analyzing Bytes: Pre-Disassembly Static Binary Analysis 引用了 SOK: (State of) The Art of War: Offensive Techniques in Binary Analysis
- You Can't Judge a Binary by Its Header: Data-Code Separation for Non-Standard ARM Binaries Using Pseudo Labels 引用了 Superset Disassembly: Statically Rewriting x86 Binaries Without Heuristics
- You Can't Judge a Binary by Its Header: Data-Code Separation for Non-Standard ARM Binaries Using Pseudo Labels 引用了 RetroWrite: Statically Instrumenting COTS Binaries for Fuzzing and Sanitization
- You Can't Judge a Binary by Its Header: Data-Code Separation for Non-Standard ARM Binaries Using Pseudo Labels 引用了 SOK: (State of) The Art of War: Offensive Techniques in Binary Analysis
- Too Subtle to Notice: Investigating Executable Stack Issues in Linux Systems 引用了 Superset Disassembly: Statically Rewriting x86 Binaries Without Heuristics
- Too Subtle to Notice: Investigating Executable Stack Issues in Linux Systems 引用了 RetroWrite: Statically Instrumenting COTS Binaries for Fuzzing and Sanitization
- Too Subtle to Notice: Investigating Executable Stack Issues in Linux Systems 引用了 Ramblr: Making Reassembly Great Again
- Too Subtle to Notice: Investigating Executable Stack Issues in Linux Systems 引用了 SOK: (State of) The Art of War: Offensive Techniques in Binary Analysis
引用它的顶会 Paper5
- Accurate Disassembly of Complex Binaries Without Use of Compiler MetadataSoumyakant Priyadarshan, Huan Nguyen, R. SekarASPLOS 2023 · 7 次引用
- Scalable, Sound, and Accurate Jump Table AnalysisHuan Nguyen, Soumyakant Priyadarshan, R. SekarISSTA 2024 · 3 次引用
- Analyzing Bytes: Pre-Disassembly Static Binary AnalysisHuan Nguyen, Soumyakant Priyadarshan, Chencheng Jiang, R. SekarPLDI 2026
- You Can't Judge a Binary by Its Header: Data-Code Separation for Non-Standard ARM Binaries Using Pseudo LabelsHadjer Benkraouda, Nirav Diwan, Gang WangS&P 2025
- Too Subtle to Notice: Investigating Executable Stack Issues in Linux SystemsHengkai Ye, Hong HuNDSS 2025
它引用的 Paper11
- SOK: (State of) The Art of War: Offensive Techniques in Binary AnalysisYan Shoshitaishvili, Ruoyu Wang, Christopher Salls, Nick Stephens 等S&P 2016 · 1,085 次引用
- RetroWrite: Statically Instrumenting COTS Binaries for Fuzzing and SanitizationSushant Dinesh, Nathan Burow, Dongyan Xu, Mathias PayerS&P 2020 · 187 次引用
- SoK: Shining Light on Shadow StacksNathan Burow, Xinping Zhang, Mathias PayerS&P 2019 · 170 次引用
- Ramblr: Making Reassembly Great AgainRuoyu Wang, Yan Shoshitaishvili, Antonio Bianchi, Aravind Machiry 等NDSS 2017 · 155 次引用
- Superset Disassembly: Statically Rewriting x86 Binaries Without HeuristicsErick Bauman, Zhiqiang Lin, Kevin W. HamlenNDSS 2018 · 112 次引用
相关 Paper
- Incremental CFG patching for binary rewritingXiaozhu Meng, Weijie LiuASPLOS 2021 · 8 次引用
- Egalito: Layout-Agnostic Binary RecompilationDavid Williams-King, Hidenori Kobayashi, Kent Williams-King, Graham Patterson 等ASPLOS 2020 · 68 次引用
- SoK: Demystifying Binary Lifters Through the Lens of Downstream ApplicationsZhibo Liu, Yuanyuan Yuan, Shuai Wang, Yuyan BaoS&P 2022 · 29 次引用
- StochFuzz: Sound and Cost-effective Fuzzing of Stripped Binaries by Incremental and Stochastic RewritingZhuo Zhang, Wei You, Guanhong Tao, Yousra Aafer 等S&P 2021 · 53 次引用
- Stack Bounds Protection with Low Fat PointersGregory J. Duck, Roland H. C. Yap, Lorenzo CavallaroNDSS 2017 · 121 次引用
