VulKey: Automated Vulnerability Repair Guided by Domain-Specific Repair Patterns
Proceedings of the ACM on Software Engineering · 30.06.2026 · 3 (FSE) · 2465-2487
DOI: 10.1145/3808117 ↗Kurz gefasst
Fachartikel in der Zeitschrift Proceedings of the ACM on Software Engineering, online erschienen am 30.06.2026. Verfasst von Jia Li und 3 weiteren Autor:innen. Die Arbeit nennt 55 Literaturangaben. Der Volltext ist frei zugänglich (Open Access, CC BY 4.0).
Abstract (Originalsprache)
The increasing prevalence of software vulnerabilities highlights the need for effective Automatic Vulnerability Repair (AVR) tools. While LLM-based approaches are promising, they struggle to incorporate structured security knowledge from sources like CWE and NVD. Current methods either use this information superficially by concatenating the CWE-ID into the input prompt, yielding negligible benefits, or rely on few-shot learning with rigid, non-generalizable examples, which limits their effectiveness in real-world scenarios. To address this gap, we propose VulKey, an LLM-based AVR framework that leverages a hierarchical abstraction of expert knowledge to guide patch generation. Our novel three-level abstraction formulates repair strategies in terms of CWE type, syntactic actions, and semantic key elements. This approach captures the essence of a security fix with greater generality than concrete examples and more semantic richness than traditional syntax-based templates, overcoming the coverage limitations of prior methods. VulKey is implemented as a two-stage pipeline: first, expert knowledge matching predicts an appropriate repair pattern for the vulnerability; second, repair code generation uses a pattern-guided, fine-tuned LLM to produce secure patches. On the real-world C/C++ dataset PrimeVul, VulKey achieves 31.5% repair accuracy, surpassing the best baseline by 7.6% and outperforming leading tools such as VulMaster and GPT-5. Moreover, VulKey demonstrates cross-language and cross-model generalizability, with state-of-the-art performance on the Java benchmark Vul4J. These results underscore the importance of structured expert knowledge in advancing AVR effectiveness. Our work demonstrates that explicitly modeling and integrating expert security knowledge through hierarchical patterns is a crucial step toward building more effective and reliable AVR tools.
Zitieren
APA
Li, J., Chen, Z., Su, Y., & Lyu, M. R. (2026). VulKey: Automated Vulnerability Repair Guided by Domain-Specific Repair Patterns. Proceedings of the ACM on Software Engineering, 3(FSE), 2465-2487. https://doi.org/10.1145/3808117
Vancouver
Li J, Chen Z, Su Y, Lyu MR. VulKey: Automated Vulnerability Repair Guided by Domain-Specific Repair Patterns. Proceedings of the ACM on Software Engineering. 2026;3(FSE):2465-2487. doi:10.1145/3808117
BibTeX
@article{Li2026,
author = {Li, Jia and Chen, Zhuangbin and Su, Yuxin and Lyu, Michael R.},
title = {VulKey: Automated Vulnerability Repair Guided by Domain-Specific Repair Patterns},
journal = {Proceedings of the ACM on Software Engineering},
year = {2026},
volume = {3},
number = {FSE},
pages = {2465--2487},
doi = {10.1145/3808117}
}
EUVIMED