paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Fine-grained Commit-level Vulnerability Type Prediction by CWE Tree Structure

基于 CWE 树结构的细粒度提交级漏洞类型预测
ICSE 2023 IEEE/ACM 45th International Conference on Software Engineering (ICSE)2023匹配度 2/10 · 该论文聚焦于基于 CWE 树结构对安全补丁提交进行细粒度漏洞类型预测,属于机器学习在软件安全/漏洞分类中的应用;它与用户核心关注的“PL→AI 静态分析/Agentic 程序”“AI→PL 改进静态分析与形式化验证”“浮点程序分析”“贝叶斯程序分析”均无直接交集,也没有涉及 LLM/Agent 与程序分析的结合。引用 53 inbox
Shengyi Pan, Lingfeng Bao, Xin Xia, David Lo, Shanping Li
crossref: 2026-09-12dblp: 2026-09-12

AI 速览

一句话:提出 TreeVul,利用 CWE 树结构对安全补丁提交进行细粒度漏洞类型分层多标签分类。

现有安全补丁检测方法多只判断提交是否含补丁(二分类),无法定位漏洞类型。本文首次将安全补丁分类到细粒度漏洞类型,以 CWE 第三层为标签,形式化为分层多标签分类(HMC):推断从 CWE 树根到目标深度节点的路径。作者提出 TreeVul,采用分层链式架构,将 CWE 树结构作为先验知识,并用树结构感知的 beam search 推断最高合并概率路径。从 NVD 收集 6,541 个提交、覆盖 1,560 个 GitHub OSS 仓库。实验表明 TreeVul 优于最佳基线,weighted F1、macro F1、MCC 分别提升 5.9%、25.0%、7.7%;用户研究与案例研究验证其实际价值。

问题
现有安全补丁检测只能二分类判断提交是否含补丁,无法给出具体漏洞类型,难以为 OSS 提供细粒度早期预警与修复支持。
方法
将任务建模为基于 CWE 树的分层多标签分类,提出 TreeVul:分层链式架构利用 CWE 树结构先验,并用树结构感知的 beam search 推断最优 CWE 路径。
评估
在从 NVD 收集的 6,541 个提交、1,560 个 GitHub OSS 仓库数据集上,与最佳基线比较 weighted F1、macro F1、MCC,并进行用户研究和案例研究。
原文摘要(Abstract)

Identifying security patches via code commits to allow early warnings and timely fixes for Open Source Software (OSS) has received increasing attention. However, the existing detection methods can only identify the presence of a patch (i.e., a binary classification) but fail to pinpoint the vulnerability type. In this work, we take the first step to categorize the security patches into fine-grained vulnerability types. Specifically, we use the Common Weakness Enumeration (CWE) as the label and perform fine-grained classification using categories at the third level of the CWE tree. We first formulate the task as a Hierarchical Multi-label Classification (HMC) problem, i.e., inferring a path (a sequence of CWE nodes) from the root of the CWE tree to the node at the target depth. We then propose an approach named TreeVul with a hierarchical and chained architecture, which manages to utilize the structure information of the CWE tree as prior knowledge of the classification task. We further propose a tree structure aware and beam search based inference algorithm for retrieving the optimal path with the highest merged probability. We collect a large security patch dataset from NVD, consisting of 6,541 commits from 1,560 GitHub OSS repositories. Experimental results show that Tree-vulsignificantly outperforms the best performing baselines, with improvements of 5.9%, 25.0%, and 7.7% in terms of weighted F1-score, macro F1-score, and MCC, respectively. We further conduct a user study and a case study to verify the practical value of TreeVul in enriching the binary patch detection results and improving the data quality of NVD, respectively.

链接与引用

DOI 原文 · PDF(开放获取) · DBLP

BibTeX
@inproceedings{PanBXLL23,
  title = {Fine-grained Commit-level Vulnerability Type Prediction by CWE Tree Structure},
  author = {Shengyi Pan and Lingfeng Bao and Xin Xia and David Lo and Shanping Li},
  booktitle = {ICSE},
  year = {2023},
  doi = {10.1109/icse48619.2023.00088}
}