ANT-VAT: Knowledge-guided virtual adversarial training for robust vulnerability detection
Deep learning-based vulnerability detectors have achieved promising results, but their reliability is often weakened by scarce labeled data and semantics-preserving code variations arising from identifier renaming, programming-style differences, and project-specific conventions. We present ANT-VAT, a knowledge-guided virtual adversarial training framework for low-resource vulnerability detection. ANT-VAT constructs a lightweight function-level vulnerability prior from local source/sink evidence, short intra-function propagation fragments, and path-related bridge tokens. After being aligned with the token sequence, the prior is used to reweight the VAT gradient before normalization. This preserves the global perturbation budget while directing consistency regularization toward code regions supported by vulnerability-related evidence. We evaluate ANT-VAT using LineVul on Devign, BigVul, and ReVeal under a 10% labeled protocol. Across five matched seeds, ANT-VAT increases the mean F1-score from 0.5779 ± 0.0255 to 0.6311 ± 0.0247 on Devign, from 0.7481 ± 0.0042 to 0.7931 ± 0.0178 on BigVul, and from 0.3159 ± 0.0298 to 0.4021 ± 0.0136 on ReVeal. All five paired F1 differences are positive on each dataset. On Devign, the matched comparison also reduces the mean false positive rate from 0.4963 ± 0.2533 to 0.3430 ± 0.1266. ANT-VAT also achieves lower observed attack success rates under MHM and ALERT identifier-renaming attacks. Ablation studies show better performance with aligned local priors and complementary precision–recall effects for the API-only and path-only variants. Overall, these findings indicate that lightweight taint-derived priors can improve VAT-based vulnerability detection under the evaluated low-resource and identifier-renaming settings.
Authors
- Xiaoya Li (ORCID: https://orcid.org/0000-0001-6844-6701)
- Na Yang
- Wen Chen
Institutions
- Sichuan University (CN)
Publication Details
- Journal
- Journal of Information Security and Applications
- Published
- 2026-09-17
- DOI
- https://doi.org/10.1016/j.jisa.2026.104639
- Primary Topic
- Adversarial Robustness in Machine Learning
- Type
- article
- Field-Weighted Citation Impact
- 0.00