UBFuzz: Finding Bugs in Sanitizer Implementations
Shaohua Li, Zhendong Su
摘要
In this paper, we propose a testing framework for validating sanitizer implementations in compilers. Our core components are (1) a program generator specifically designed for producing programs containing undefined behavior (UB), and (2) a novel test oracle for sanitizer testing. The program generator employs Shadow Statement Insertion, a general and effective approach for introducing UB into a valid seed program. The generated UB programs are subsequently utilized for differential testing of multiple sanitizer implementations. Nevertheless, discrepant sanitizer reports may stem from either compiler optimization or sanitizer bugs. To accurately determine if a discrepancy is caused by sanitizer bugs, we introduce a new test oracle called crash-site mapping.
We have incorporated our techniques into UBfuzz, a practical tool for testing sanitizers. Over a five-month testing period, UBfuzz successfully found 31 bugs in both GCC and LLVM sanitizers. These bugs reveal the serious false negative problems in sanitizers, where certain UBs in programs went unreported. This research paves the way for further investigation in this crucial area of study.
问 Lune
几分钟读透这篇 Paper,不用再花一下午。
Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。
已有 11 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。
脉络
- Janus: Detecting Rendering Bugs in Web Browsers via Visual Delta Consistency 引用了 Random testing for C and C++ compilers with YARPGen
- Boosting Compiler Testing by Injecting Real-World Code 引用了 Random testing for C and C++ compilers with YARPGen
- Interleaving Large Language Models for Compiler Testing 引用了 Boosting Compiler Testing by Injecting Real-World Code
- Interleaving Large Language Models for Compiler Testing 引用了 Random testing for C and C++ compilers with YARPGen
- Unveiling Compiler Faults via Attribute-Guided Compilation Space Exploration 引用了 Debug information validation for optimized code
- Unveiling Compiler Faults via Attribute-Guided Compilation Space Exploration 引用了 Finding missed optimizations through the lens of dead code elimination
- Unveiling Compiler Faults via Attribute-Guided Compilation Space Exploration 引用了 Boosting Compiler Testing by Injecting Real-World Code
- Unveiling Compiler Faults via Attribute-Guided Compilation Space Exploration 引用了 Random testing for C and C++ compilers with YARPGen
- Optimization-Directed Compiler Fuzzing for Continuous Translation Validation 引用了 Boosting Compiler Testing by Injecting Real-World Code
- Optimization-Directed Compiler Fuzzing for Continuous Translation Validation 引用了 Random testing for C and C++ compilers with YARPGen
- SANRAZOR: Reducing Redundant Sanitizer Checks in C/C++ Programs 引用了 FuZZan: Efficient Sanitizer Metadata Design for Fuzzing
引用它的顶会 Paper11
- Boosting Compiler Testing by Injecting Real-World CodeShaohua Li, Theodoros Theodoridis, Zhendong SuPLDI 2024 · 24 次引用
- Unveiling Compiler Faults via Attribute-Guided Compilation Space ExplorationJiangchang Wu, Yibiao Yang, Maolin Sun, Yuming ZhouUSENIX ATC 2025 · 6 次引用
- Optimization-Directed Compiler Fuzzing for Continuous Translation ValidationJaeseong Kwon, Bongjun Jang, Juneyoung Lee, Kihong HeoPLDI 2025 · 5 次引用
- Interleaving Large Language Models for Compiler TestingYunbo Ni, Shaohua LiOOPSLA 2025 · 4 次引用
- Janus: Detecting Rendering Bugs in Web Browsers via Visual Delta ConsistencyChijin Zhou, Quan Zhang, Bingzhou Qian, Yu JiangICSE 2025 · 2 次引用
它引用的 Paper10
- Random testing for C and C++ compilers with YARPGenVsevolod Livinskii, Dmitry Babokin, John RegehrOOPSLA 2020 · 140 次引用
- FuZZan: Efficient Sanitizer Metadata Design for FuzzingYuseok Jeon, Wookhyun Han, Nathan Burow, Mathias PayerUSENIX ATC 2020 · 52 次引用
- Finding missed optimizations through the lens of dead code eliminationTheodoros Theodoridis, Manuel Rigger, Zhendong SuASPLOS 2022 · 48 次引用
- SANRAZOR: Reducing Redundant Sanitizer Checks in C/C++ ProgramsJiang Zhang, Shuai Wang, Manuel Rigger, Pinjia He 等OSDI 2021 · 38 次引用
- Debug information validation for optimized codeYuanbo Li, Shuo Ding, Qirun Zhang, Davide ItalianoPLDI 2020 · 30 次引用
相关 Paper
- Don't Look UB: Exposing Sanitizer-Eliding Compiler OptimizationsRaphael Isemann, Cristiano Giuffrida, Herbert Bos, Erik van der Kouwe 等PLDI 2023 · 5 次引用
- CombiSan: Unifying Software Sanitizers for Comprehensive FuzzingMatteo Marini, Floris Gorter, Daniele Cono D'Elia, Cristiano GiuffridaUSENIX Security 2026
- Finding Unstable Code via Compiler-Driven Differential TestingShaohua Li, Zhendong SuASPLOS 2023 · 19 次引用
- WBSan: WebAssembly Bug Detection for Sanitization and Binary-Only FuzzingXiao Wu, Junzhou He, Liyan Huang, Cai Fu 等WWW 2025 · 5 次引用
- Sand: Decoupling Sanitization from Fuzzing for Low OverheadZiqiao Kong, Shaohua Li, Heqing Huang, Zhendong SuICSE 2025 · 1 次引用
