arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 1911.07620cs.SEcs.CL
收藏

利用代码的令牌和基于路径的表示来识别安全相关提交

Exploiting Token and Path-based Representations of Code for Identifying Security-Relevant Commits

University of Waterloo(滑铁卢大学);SAP Security Research(SAP安全研究院)

Achyudh Ram, Ji Xin, Meiyappan Nagappan, Yaoliang Yu, Rocío Cabrera Lozoya, Antonino Sabetta, Jimmy Lin

摘要:

公共漏洞数据库(如CVE和NVD)仅占开源项目中存在的安全漏洞的60%,并且已知质量不一致。在过去的两年中,在NPM和Maven Central等各种存储库中可用的项目中,已知漏洞的数量有了相当大的增长。这种日益增加的风险要求建立一种机制,以及时推断安全威胁的存在。我们提出了新的分层深度学习模型,用于从提交差异或Java类的源代码中识别安全相关的提交。通过将我们的模型与code2vec(一种从基于路径的代码表示中学习的最先进的模型)和逻辑回归基线进行比较,我们发现深度学习模型在识别安全相关的提交方面显示出有希望的结果。我们还对各种深度学习模型如何在不同的输入表示中学习以及正则化对模型泛化的影响进行了比较分析。

英文摘要:

Public vulnerability databases such as CVE and NVD account for only 60% of security vulnerabilities present in open-source projects, and are known to suffer from inconsistent quality. Over the last two years, there has been considerable growth in the number of known vulnerabilities across projects available in various repositories such as NPM and Maven Central. Such an increasing risk calls for a mechanism to infer the presence of security threats in a timely manner. We propose novel hierarchical deep learning models for the identification of security-relevant commits from either the commit diff or the source code for the Java classes. By comparing the performance of our model against code2vec, a state-of-the-art model that learns from path-based representations of code, and a logistic regression baseline, we show that deep learning models show promising results in identifying security-related commits. We also conduct a comparative analysis of how various deep learning models learn across different input representations and the effect of regularization on the generalization of our models.

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

↑