Understanding Binary Code Similarity for Real-World Vulnerability Detection: A Large-Scale Empirical Study
Jingdong Guo, Chaopeng Dong, Yimo Ren, Siyuan Li, Jie Liu, Hong Li, Hongsong Zhu
Abstract
Firmware lies at the heart of IoT devices. Its development depends heavily on third-party libraries (TPLs), which greatly accelerate the process but simultaneously introduce associated vulnerabilities. Binary Code Similarity Detection (BCSD) is an effective technique for identifying vulnerabilities in firmware by comparing pairs of code segments. However, existing studies either evaluate their performance only on small-scale datasets or lack diversity in terms of vulnerabilities, TPLs, and firmware. Consequently, a comprehensive understanding of BCSD for real-world vulnerability detection remains absent.
To bridge this gap, we conduct a large-scale study of vulnerability detection across 60,000 firmware images from 200 vendors using BCSD. Rather than introducing a novel model, we examine the influence of four key factors-vulnerable function versions, vulnerability search space, function sizes, and compilation toolchains on BCSD performance. Our results reveal that these factors substantially affect performance, often by wide margins. To address this, we propose a build-aware query strategy that derives queries from representative real-world binaries, effectively closing the gap and raising the mean reciprocal rank (MRR) from 0.818 to 0.981. Furthermore, we demonstrate that a TPL-aware, two-stage search process significantly enhances accuracy, improving MRR by 18.5% by limiting the search space.
Ask Lune
Know this paper in minutes, not an afternoon.
Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.
Lineage
- Asm2Vec: Boosting Static Representation Robustness for Binary Clone Search against Code Obfuscation and Compiler Optimization cites Neural Network-based Graph Embedding for Cross-Platform Binary Code Similarity Detection
- Asm2Vec: Boosting Static Representation Robustness for Binary Clone Search against Code Obfuscation and Compiler Optimization cites discovRE: Efficient Cross-Architecture Identification of Bugs in Binary Code
- Asm2Vec: Boosting Static Representation Robustness for Binary Clone Search against Code Obfuscation and Compiler Optimization cites Scalable Graph-based Bug Search for Firmware Images
- Neural Network-based Graph Embedding for Cross-Platform Binary Code Similarity Detection cites Towards Automated Dynamic Analysis for Linux-based Embedded Firmware
- Neural Network-based Graph Embedding for Cross-Platform Binary Code Similarity Detection cites discovRE: Efficient Cross-Architecture Identification of Bugs in Binary Code
- Neural Network-based Graph Embedding for Cross-Platform Binary Code Similarity Detection cites Scalable Graph-based Bug Search for Firmware Images
- Scalable Graph-based Bug Search for Firmware Images cites Towards Automated Dynamic Analysis for Linux-based Embedded Firmware
- Scalable Graph-based Bug Search for Firmware Images cites discovRE: Efficient Cross-Architecture Identification of Bugs in Binary Code
Builds on20
- Neural Network-based Graph Embedding for Cross-Platform Binary Code Similarity DetectionXiaojun Xu, Chang Liu, Qian Feng, Heng Yin et al.CCS 2017 · 682 citations
- Scalable Graph-based Bug Search for Firmware ImagesQian Feng, Rundong Zhou, Chengcheng Xu, Yao Cheng et al.CCS 2016 · 456 citations
- Asm2Vec: Boosting Static Representation Robustness for Binary Clone Search against Code Obfuscation and Compiler OptimizationSteven H. H. Ding, Benjamin C. M. Fung, Philippe CharlandS&P 2019 · 447 citations
- Towards Automated Dynamic Analysis for Linux-based Embedded FirmwareDaming D. Chen, Maverick Woo, David Brumley, Manuel EgeleNDSS 2016 · 428 citations
- discovRE: Efficient Cross-Architecture Identification of Bugs in Binary CodeSebastian Eschweiler, Khaled Yakdan, Elmar Gerhards-PadillaNDSS 2016 · 342 citations
Related papers
- A Large Scale Study of AI-based Binary Function Similarity Detection Techniques for Security Researchers and PractitionersJingyi Shi, Yufeng Chen, Yang Xiao, Yuekang Li et al.ASE 2025
- A large-scale empirical analysis of the vulnerabilities introduced by third-party components in IoT firmwareBinbin Zhao, Shouling Ji, Jiacheng Xu, Yuan Tian et al.ISSTA 2022 · 49 citations
- CEBin: A Cost-Effective Framework for Large-Scale Binary Code Similarity DetectionHao Wang, Zeyu Gao, Chao Zhang, Mingyang Sun et al.ISSTA 2024 · 21 citations
- Understanding the Limitations of C/C++ Binary Third-Party Library Detection Tool: An Empirical Study at ScaleChengyue Liu, Zhengzi Xu, Kaixuan Li, Jiahui Wu et al.FSE 2026
- Revisiting Graph Representations for ML-Based Binary Code Similarity Detection: A Systematic StudyTengteng Yang, Yikun Hu, Jican Zhang, Lei Xue et al.ISSTA 2026
