arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2308.04662cs.CR
收藏

VulLibGen:通过大型语言模型生成受漏洞影响的软件包名称

VulLibGen: Generating Names of Vulnerability-Affected Packages via a Large Language Model

Tianyu Chen, Lin Li, Liuchuan Zhu, Zongyang Li, Xueqing Liu, Guangtai Liang, Qianxiang Wang, Tao Xie

AI总结:

本文提出 VulLibGen,首次利用 LLM 直接生成受漏洞影响的软件包名称,并结合 SFT、RAG 与局部搜索后处理,在四大生态系统上将平均准确率提升至 0.806。

摘要:

安全从业者维护漏洞报告(例如 GitHub Advisory),以帮助开发者缓解安全风险。这些数据库的一项重要任务是自动提取报告中提到的结构化信息,例如受影响的软件包,从而加快漏洞生态系统的防御。然而,现有关于受影响软件包识别的工作很难达到较高准确率。原因之一是所有现有工作都聚焦于相对较小的模型,因此无法利用大型语言模型的知识和语义能力。为解决这一局限,我们提出 VulLibGen,这是首个使用 LLM 进行受影响软件包识别的方法。与现有工作不同,VulLibGen 提出了直接生成受影响软件包的新颖思路。为提高准确率,VulLibGen 采用了监督微调(SFT)、检索增强生成(RAG)和一种局部搜索算法。该局部搜索算法是我们引入的一种新颖后处理算法,用于减少所生成软件包的幻觉。我们的评估结果表明,在 GitHub Advisory 中四个最流行的生态系统(Java、JS、Python、Go)里,VulLibGen 识别易受攻击软件包的平均准确率为 0.806,而先前工作中的最佳平均准确率为 0.721。此外,VulLibGen 对安全实践具有很高价值:我们向 GitHub Advisory 提交了 60 个〈漏洞,受影响软件包〉对(覆盖四个生态系统)。其中 34 个已被接受并合并,20 个正在等待审批。我们的代码和数据集可在附件中找到。

英文摘要:

Security practitioners maintain vulnerability reports (e.g., GitHub Advisory) to help developers mitigate security risks. An important task for these databases is automatically extracting structured information mentioned in the report, e.g., the affected software packages, to accelerate the defense of the vulnerability ecosystem. However, it is challenging for existing work on affected package identification to achieve a high accuracy. One reason is that all existing work focuses on relatively smaller models, thus they cannot harness the knowledge and semantic capabilities of large language models. To address this limitation, we propose VulLibGen, the first method to use LLM for affected package identification. In contrast to existing work, VulLibGen proposes the novel idea to directly generate the affected package. To improve the accuracy, VulLibGen employs supervised fine-tuning (SFT), retrieval augmented generation (RAG) and a local search algorithm. The local search algorithm is a novel postprocessing algorithm we introduce for reducing the hallucination of the generated packages. Our evaluation results show that VulLibGen has an average accuracy of 0.806 for identifying vulnerable packages in the four most popular ecosystems in GitHub Advisory (Java, JS, Python, Go) while the best average accuracy in previous work is 0.721. Additionally, VulLibGen has high value to security practice: we submitted 60 <vulnerability, affected package> pairs to GitHub Advisory (covers four ecosystems). 34 of them have been accepted and merged and 20 are pending approval. Our code and dataset can be found in the attachments.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑