paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Natural attack for pre-trained models of code

面向代码预训练模型的自然攻击
ICSE Proceedings of the 44th International Conference on Software Engineering2022匹配度 3/10 · 该论文研究代码预训练模型的自然对抗攻击,属于机器学习与程序语言交叉中的安全与鲁棒性方向,与用户关注的静态分析、形式化验证、浮点程序分析及 LLM 改进静态分析等核心问题无直接关联。引用 164 inbox
Zhou Yang, Jieke Shi, Junda He, David Lo
crossref: 2026-09-12

AI 速览

一句话:指出现有代码对抗攻击忽视自然性,并提出面向代码预训练模型的自然对抗攻击。

代码预训练模型已在许多重要软件工程任务中取得成功,但这些强大模型容易受到对抗攻击:对模型输入做微小扰动即可使受害模型产生错误输出。现有工作主要利用保持程序操作语义的样本攻击代码模型,却忽略了对抗样本生成的一项基本要求:扰动应对人类判断者而言是自然的,作者将其称为自然性要求。本文关注面向代码预训练模型的自然攻击,即对抗样本不仅应保持操作程序语义,还应满足人类感知上的自然性,从而提升攻击的隐蔽性与现实威胁。摘要未给出具体算法、评估基准和量化结果,因此方法细节与实验结论需参见全文。

问题
现有代码预训练模型易受对抗攻击,而当前攻击方法只强调保持操作程序语义,忽略了扰动对人类而言是否自然这一基本要求。
方法
提出“自然攻击”方向,在生成面向代码预训练模型的对抗样本时,同时考虑操作语义保持与人类自然性要求。
评估
摘要未描述具体评估方式与实验结果;仅能看出评估应涉及对抗攻击有效性与自然性要求,但细节未展开。
原文摘要(Abstract)

Pre-trained models of code have achieved success in many important software engineering tasks. However, these powerful models are vulnerable to adversarial attacks that slightly perturb model inputs to make a victim model produce wrong outputs. Current works mainly attack models of code with examples that preserve operational program semantics but ignore a fundamental requirement for adversarial example generation: perturbations should be natural to human judges, which we refer to as naturalness requirement.

链接与引用

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

BibTeX
@inproceedings{paperbot6933,
  title = {Natural attack for pre-trained models of code},
  author = {Zhou Yang and Jieke Shi and Junda He and David Lo},
  booktitle = {ICSE},
  year = {2022},
  doi = {10.1145/3510003.3510146}
}