Vul-RAG: Enhancing LLM-based Vulnerability Detection via Knowledge-level RAG

要約

LLMは脆弱性の検出において有望な可能性を示していますが、この研究は、脆弱性と類似のパッチされたコード(0.06-0.14の精度のみ)を区別する際の限界を明らかにしています。
LLMSは、脆弱性検出中の脆弱性の根本原因を捉えるのに苦労していることを示しています。
この課題に対処するために、歴史的脆弱性や修正から蒸留された多次元脆弱性の知識を持つLLMを強化することを提案します。
私たちは、新しい知識レベルの検索された生成フレームワークVUL-RAGを設計します。これにより、脆弱なコードとパッチ付きコードの識別が16%〜24%の精度が向上し、LLMSが改善されます。
さらに、VUL-RAGによって生成された脆弱性の知識はさらに(1)手動検出の精度を改善するための高品質の説明として機能し(60%から77%)、(2)6個の割り当てられたCVEで最近のLinuxカーネルリリースで以前に知られていないバグを検出できます。

要約(オリジナル)

Although LLMs have shown promising potential in vulnerability detection, this study reveals their limitations in distinguishing between vulnerable and similar-but-benign patched code (only 0.06 – 0.14 accuracy). It shows that LLMs struggle to capture the root causes of vulnerabilities during vulnerability detection. To address this challenge, we propose enhancing LLMs with multi-dimensional vulnerability knowledge distilled from historical vulnerabilities and fixes. We design a novel knowledge-level Retrieval-Augmented Generation framework Vul-RAG, which improves LLMs with an accuracy increase of 16% – 24% in identifying vulnerable and patched code. Additionally, vulnerability knowledge generated by Vul-RAG can further (1) serve as high-quality explanations to improve manual detection accuracy (from 60% to 77%), and (2) detect 10 previously-unknown bugs in the recent Linux kernel release with 6 assigned CVEs.

arxiv情報

著者 Xueying Du,Geng Zheng,Kaixin Wang,Yi Zou,Yujia Wang,Wentai Deng,Jiayi Feng,Mingwei Liu,Bihuan Chen,Xin Peng,Tao Ma,Yiling Lou
発行日 2025-06-17 15:07:17+00:00
arxivサイト arxiv_id(pdf)

提供元, 利用サービス

arxiv.jp, Google

カテゴリー: cs.AI, cs.SE パーマリンク