Research map / Adversarial robustness and security / Attacks on text and graphs
Vulnerable Code Search: Transferable Attack for Code Language Models
Kaicheng Wang, Liyan Huang, Jesse Thomason, Weihang Wang
University of Southern California
Read the paperPlace an idea next to itCheck your own paper ↗
AI-extracted. The measured effects below were read by AI from the paper's full text (no summary yet). Numbers and claims can be wrong or missing context, so check the paper before you cite or build on it.
Measured effects reported in the paper
| What was changed | Where | Measured | Effect |
|---|---|---|---|
| replace 10% of irrelevant candidates with adversarial snippets | CodeT5+ / OASIS / Nomic / Voyage-code-3 · CosQA | MRR: e.g. Nomic 83.03 -> 5.95; Voyage 87.06 -> 9.52 | Hurt |
| use transferred attack instead of DAMP (white-box) | OASIS · CosQA | Delta Sim: 10.45 -> 18.66, 81 mins -> 47 mins | Improved |
| use transferred attack instead of CodeAttack (black-box) | Voyage-code-3 · CosQA | Delta Sim: 5.18 -> 28.03; ~10.8M calls -> 1k calls | Improved |
| insert two adversarial candidate snippets | GPT-5.4-mini · RepoQA (Python) | accuracy: 96 -> 81 | Hurt |
| insert two adversarial candidate snippets | Gemini-3.1-Pro · RepoQA (C++) | accuracy: 92 -> 72 | Hurt |
| add gradient guidance (ablation) | attack · CosQA, eval CodeT5+ | Delta Sim: 30.91 -> 38.86 | Improved |
| add style preservation (ablation) | attack · CosQA, eval CodeT5+ | Delta Sim: 39.48 (w/o) vs 38.86 | No clear effect |
| add style preservation (ablation) | attack on LLMs · RepoQA (Python, GPT-5.4-mini) | accuracy: 93 -> 81 (accuracy lowered more with style) | Improved |
| add query token similarity (ablation) | attack · CosQA, eval Nomic-embed-code | Delta Sim: 22.68 -> 39.25 | Improved |
| add query token similarity (ablation) | attack on LLMs · RepoQA (Python, GPT-5.4-mini) | accuracy: 89 -> 81 (accuracy lowered more with QTS) | Improved |
| robust-only finetuning | CodeT5+ · CosQA retrieval | R@5: 88.0 -> 42.6 | Hurt |
| mixed finetuning | CodeT5+ · adaptive attack on finetuned checkpoint | Delta Sim: FT-CodeT5+ attack 34.70 (still vulnerable) | No clear effect |
Earlier methods this paper compares with
Named baselines from earlier accepted papers in this paper's results tables: better than 1 of 1 on most shared results.
- CodeAttack — CodeAttack: Code-Based Adversarial Attacks for Pre-trained Programming Language Models (AAAI 2023) · better on 1 of 1 shared result
Matched by method name in results tables read by AI. Authors' own tables tend to favour the newer method, and a comparison can be missed when a method is renamed.
Closest papers by meaning
- CodeAttack: Code-Based Adversarial Attacks for Pre-trained Programming Language Models (AAAI 2023 · similarity 0.91)
- On the Robustness of Code LLM Guardrails to Code-mixed and Transliterated Inputs (EMNLP 2026 · similarity 0.88)
- Adversarial Training for Code Retrieval with Question-Description Relevance Regularization (EMNLP 2020 · similarity 0.88)
- Black-Box Adversarial Attacks on LLM-Based Code Completion (ICML 2025 · similarity 0.86)
- CodeMimicry: Exploiting Safety Generalization Lag in Large Language Models via Structured Code Completion (NeurIPS 2026 · similarity 0.86)
- ProSec: Fortifying Code LLMs with Proactive Security Alignment (ICML 2025 · similarity 0.85)
Writing a paper in this area? scime draft is a free LaTeX editor with AI included, real-time co-authors and a check of your references and venue rules before you submit. It also imports OpenAI Prism projects.
