Skip to content

Back to the catalog

VulDec: Vulnerability Detection in Binaries via Neural Decompilation
arxiv.orgpaper

VulDec: Vulnerability Detection in Binaries via Neural Decompilation

VulDec is a dataset and framework for detecting vulnerabilities in binaries by first decompiling them with fine-tuned LLMs. The dataset aligns real-world Assembly-C function pairs across several architectures with CWE labels. Tuned neural decompilers reach about 56% Edit Similarity and 43% BLEU-4, and tuned detectors reach a macro F1 of 0.61 on a realistic test set with a 3% vulnerability rate.

TL;DR Introduces a CWE-labelled Assembly-C dataset and an end-to-end pipeline that fine-tunes LLMs to decompile binaries and then detect vulnerabilities.
Also seen from another angle🛡️ Security →
Document

What it claims

VulDec is a dataset of more than 59,000 vulnerable and non-vulnerable C–Assembly function pairs extracted from about 7,000 real-world commits. Every pair carries a CWE label. The assembly comes from official Debian packages, not from code the authors compiled themselves. The same data trains both stages of the pipeline: an LLM neural decompiler (assembly to pseudo-C) and an LLM vulnerability classifier that runs on the decompiled output. The authors argue that training both on one data distribution keeps the stages semantically consistent and reduces the shift between the detector's training input and its inference input.

How it works

  1. Start from DiverseVul (Chen et al. 2023). It has about 19,000 vulnerable and over 330,000 non-vulnerable C/C++ functions across 150 CWE categories, labelled through vulnerability-fixing commits.
  2. DiverseVul source does not compile on its own. Instead, the authors locate the matching Debian package versions, disassemble the shipped binaries with objdump across several architectures, and align the resulting functions to the DiverseVul source functions.
  3. Fine-tune an LLM to translate disassembled functions into C. The paper calls this neural decompilation.
  4. Fine-tune an LLM to classify the decompiled function as vulnerable or not.

The pipeline works at function level. The authors say this suits neural decompilers, which can handle isolated fragments where Ghidra, IDA and RetDec need complete, compilable binaries with closed control-flow graphs.

Evidence

Tuned decompilers reach about 56% Edit Similarity and about 43% BLEU-4 against the original source across architectures. Tuned detectors reach macro F1 0.61 on an in-distribution test set with a 3% vulnerability rate, a ratio the authors chose to be realistic. The fetched text contains no per-architecture breakdown, no names or sizes of the base models, and no comparison against Ghidra-decompiled code or assembly-level detectors.

How to use it

The dataset is on Figshare. The page gives no link, licence or file format. Because the labels come from DiverseVul, its licence and labelling caveats likely carry over.

Limits

The fetched text stops partway through dataset construction, so results tables, ablations and the threats-to-validity section are not visible. The 0.61 F1 is in-distribution only, and no cross-project or out-of-distribution figure appears. The authors list general risks of neural decompilers:

  • output that is not syntactically correct
  • weak generalisation beyond the training distribution
  • bias toward particular compilers, optimisation levels or coding styles
  • no interpretability or deterministic guarantees

They present neural decompilation as a complement to traditional decompilers, not a replacement. Debian packages fix the compiler settings, so robustness to other toolchains or to stripped proprietary binaries is not shown.

Organisations named here

  • CWE

Technologies named here

  • Tuned LLM-based neural decompilers
  • VulDec
  • Tuned LLM-based vulnerability detectors
  • LLM

Techniques named here

  • Neural decompilation for binary vulnerability detection