Generating Adversarial Computer Programs using Optimized Obfuscations
Shashank Srikant, Sijia Liu, Tamara Mitrovska, Shiyu Chang, Quanfu Fan, Gaoyuan Zhang, Una-May O'Reilly
摘要
Machine learning (ML) models that learn and predict properties of computer programs are increasingly being adopted and deployed. These models have demonstrated success in applications such as auto-completing code, summarizing large programs, and detecting bugs and malware in programs. In this work, we investigate principled ways to adversarially perturb a computer program to fool such learned models, and thus determine their adversarial robustness. We use program obfuscations, which have conventionally been used to avoid attempts at reverse engineering programs, as adversarial perturbations. These perturbations modify programs in ways that do not alter their functionality but can be crafted to deceive an ML model when making a decision. We provide a general formulation for an adversarial program that allows applying multiple obfuscation transformations to a program in any language. We develop first-order optimization algorithms to efficiently determine two key aspects -- which parts of the program to transform, and what transformations to use. We show that it is important to optimize both these aspects to generate the best adversarially perturbed program. Due to the discrete nature of this problem, we also propose using randomized smoothing to improve the attack loss landscape to ease optimization. We evaluate our work on Python and Java programs on the problem of program summarization. We show that our best attack proposal achieves a improvement over a state-of-the-art attack generation approach for programs trained on a seq2seq model. We further show that our formulation is better at training models that are robust to adversarial attacks.
问 Lune
几分钟读透这篇 Paper,不用再花一下午。
Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。
已有 19 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。
脉络
- ContraBERT: Enhancing Code Pre-trained Models via Contrastive Learning 引用了 Adversarial examples for models of code
- ContraBERT: Enhancing Code Pre-trained Models via Contrastive Learning 引用了 Generating Adversarial Examples for Holding Robustness of Source Code Processing Models
- ContraBERT: Enhancing Code Pre-trained Models via Contrastive Learning 引用了 Natural Attack for Pre-trained Models of Code
- Generating Adversarial Examples for Holding Robustness of Source Code Processing Models 引用了 Towards Evaluating the Robustness of Neural Networks
- RoPGen: Towards Robust Code Authorship Attribution via Automatic Coding Style Transformation 引用了 Adversarial examples for models of code
- RoPGen: Towards Robust Code Authorship Attribution via Automatic Coding Style Transformation 引用了 Generating Adversarial Examples for Holding Robustness of Source Code Processing Models
- RoPGen: Towards Robust Code Authorship Attribution via Automatic Coding Style Transformation 引用了 Misleading Authorship Attribution of Source Code using Adversarial Learning
- Natural Attack for Pre-trained Models of Code 引用了 Adversarial examples for models of code
- Natural Attack for Pre-trained Models of Code 引用了 Generating Adversarial Examples for Holding Robustness of Source Code Processing Models
- Intriguing Properties of Adversarial ML Attacks in the Problem Space 引用了 Towards Evaluating the Robustness of Neural Networks
- Intriguing Properties of Adversarial ML Attacks in the Problem Space 引用了 Misleading Authorship Attribution of Source Code using Adversarial Learning
- An extensive study on pre-trained models for program understanding and generation 引用了 Adversarial examples for models of code
- Uncovering the Limits of Machine Learning for Automatic Vulnerability Detection 引用了 Adversarial examples for models of code
- Uncovering the Limits of Machine Learning for Automatic Vulnerability Detection 引用了 Generating Adversarial Examples for Holding Robustness of Source Code Processing Models
- Uncovering the Limits of Machine Learning for Automatic Vulnerability Detection 引用了 Natural Attack for Pre-trained Models of Code
- Misleading Authorship Attribution of Source Code using Adversarial Learning 引用了 Towards Evaluating the Robustness of Neural Networks
引用它的顶会 Paper19
- Natural Attack for Pre-trained Models of CodeZhou Yang, Jieke Shi, Junda He, David LoICSE 2022 · 150 次引用
- An extensive study on pre-trained models for program understanding and generationZhengran Zeng, Hanzhuo Tan, Haotian Zhang, Jing Li 等ISSTA 2022 · 142 次引用
- Uncovering the Limits of Machine Learning for Automatic Vulnerability DetectionNiklas Risse, Marcel BöhmeUSENIX Security 2024 · 63 次引用
- ContraBERT: Enhancing Code Pre-trained Models via Contrastive LearningShangqing Liu, Bozhi Wu, Xiaofei Xie, Guozhu Meng 等ICSE 2023 · 56 次引用
- RoPGen: Towards Robust Code Authorship Attribution via Automatic Coding Style TransformationZhen Li, Qian (Guenevere) Chen, Chen Chen, Yayi Zou 等ICSE 2022 · 39 次引用
它引用的 Paper6
- Towards Evaluating the Robustness of Neural NetworksNicholas Carlini, David A. WagnerS&P 2017 · 9,786 次引用
- Intriguing Properties of Adversarial ML Attacks in the Problem SpaceFabio Pierazzi, Feargus Pendlebury, Jacopo Cortellazzi, Lorenzo CavallaroS&P 2020 · 334 次引用
- Adversarial examples for models of codeNoam Yefet, Uri Alon, Eran YahavOOPSLA 2020 · 162 次引用
- Generating Adversarial Examples for Holding Robustness of Source Code Processing ModelsHuangzhao Zhang, Zhuo Li, Ge Li, Lei Ma 等AAAI 2020 · 148 次引用
- Misleading Authorship Attribution of Source Code using Adversarial LearningErwin Quiring, Alwin Maier, Konrad RieckUSENIX Security 2019 · 123 次引用
相关 Paper
- Adversarial Robustness for CodePavol Bielik, Martin T. VechevICML 2020 · 101 次引用
- ObscuraCoder: Powering Efficient Code LM Pre-Training Via Obfuscation GroundingIndraneil Paul, Haoyi Yang, Goran Glavas, Kristian Kersting 等ICLR 2025
- Attacks against Abstractive Text Summarization Models through Lead Bias and Influence FunctionsPoojitha Thota, Shirin NilizadehEMNLP Findings 2024 · 7 次引用
- Discrete Adversarial Attack to Models of CodeFengjuan Gao, Yu Wang, Ke WangPLDI 2023 · 23 次引用
- Trust Me, I Know This Function: Hijacking LLM Static Analysis using BiasShir Bernstein, David Beste, Daniel Ayzenshteyn, Lea Schönherr 等NDSS 2026 · 7 次引用
