LLM Reasoning 相关度: 8/10

VulReaD: Knowledge-Graph-guided Software Vulnerability Reasoning and Detection

Samal Mukhtar, Yinghua Yao, Zhu Sun, Mustafa Mustafa, Yew Soon Ong, Youcheng Sun
arXiv: 2602.10787v1 发布: 2026-02-11 更新: 2026-02-11

AI 摘要

VulReaD利用知识图谱引导LLM进行软件漏洞推理和检测,提升CWE覆盖和可解释性。

主要贡献

  • 提出VulReaD框架,结合知识图谱和LLM进行漏洞检测
  • 使用teacher LLM生成CWE一致的对比推理监督
  • 使用ORPO优化学生模型,鼓励分类学对齐的推理

方法论

构建安全知识图谱,利用teacher LLM生成推理监督,通过ORPO微调学生模型,实现漏洞检测。

原文摘要

Software vulnerability detection (SVD) is a critical challenge in modern systems. Large language models (LLMs) offer natural-language explanations alongside predictions, but most work focuses on binary evaluation, and explanations often lack semantic consistency with Common Weakness Enumeration (CWE) categories. We propose VulReaD, a knowledge-graph-guided approach for vulnerability reasoning and detection that moves beyond binary classification toward CWE-level reasoning. VulReaD leverages a security knowledge graph (KG) as a semantic backbone and uses a strong teacher LLM to generate CWE-consistent contrastive reasoning supervision, enabling student model training without manual annotations. Students are fine-tuned with Odds Ratio Preference Optimization (ORPO) to encourage taxonomy-aligned reasoning while suppressing unsupported explanations. Across three real-world datasets, VulReaD improves binary F1 by 8-10% and multi-class classification by 30% Macro-F1 and 18% Micro-F1 compared to state-of-the-art baselines. Results show that LLMs outperform deep learning baselines in binary detection and that KG-guided reasoning enhances CWE coverage and interpretability.

标签

软件漏洞检测 知识图谱 大型语言模型 对比学习

arXiv 分类

cs.SE cs.AI cs.CR cs.IR