ALIBI: Adaptive Agentic Attacks on LLM-Based Vulnerability Detectors via Adversarial Code Comments
On the map: LLM agents and tool use → Agent threats, guardrails and governance
Abstract (arXiv)
Large language models are increasingly deployed for security-sensitive tasks such as vulnerability detection and code review. Their reliance on natural-language context embedded in source code exposes a previously underexplored attack surface: adversarial comments that can influence a detector's reasoning without changing program behavior. We study LLM-based vulnerability detectors against a new adversary: a coding agent that implements new functionality, deliberately introduces vulnerabilities, and strategically inserts adversarial source-code comments to evade detection. We present ALIBI, an automated adaptive black-box attack framework that generates and iteratively refines adversarial comments using detector reasoning and feedback. We transform real-world vulnerability-fixing commits into coding tasks and evaluate four representative LLM-based vulnerability detectors, ranging from specialized open-weight reasoning models to frontier multi-agent systems. All evaluated detectors are highly vulnerable: attack success rates exceed 90% across 125 real-world null-pointer dereference vulnerabilities, reaching 100% on one system. The framework also generalizes beyond this vulnerability class. Adversarial comments steering detector reasoning or fabricating external tool results prove most effective, while iterative refinement based on detector feedback further increases attack success. Finally, prompt-level defenses provide limited robustness against adaptive attacks, whereas architectural isolation and pre-detector comment sanitization substantially improve resilience. Our findings expose a fundamental attack surface in current LLM-based vulnerability detectors and motivate security-aware designs that carefully calibrate trust between natural-language context and program evidence.
Key facts. No citing papers in the map yet (data through 7 Oct 2026). Placed in Agent threats, guardrails and governance, one of 16 directions in LLM agents and tool use. Builds on 35 of its 99 references that are in the map. First posted on arXiv 27 Jul 2026.
Builds on
35 of 99 references.
Closest ancestors · 7
Same direction, newest first
- 2026Supply-Chain Poisoning Attacks Against LLM Coding Agent Skill Ecosystems3 Apr
- 2026"Do Not Mention This to the User": Detecting and Understanding Malicious Agent Skills in the Wild6 Feb
- 2026Sifting the Noise: A Comparative Study of LLM Agents in Vulnerability False Positive Filtering30 Jan
- 2026Prompt Injection Attacks on Agentic Coding Assistants: A Systematic Analysis of Vulnerabilities in Skills, Tools, and Protocol Ecosystems24 Jan
- 2025CoTDeceptor:Adversarial Code Obfuscation Against CoT-Enhanced LLM Code Agents24 Dec
- 2025Let the Trial Begin: A Mock-Court Approach to Vulnerability Detection using LLM-Based Agents16 May
- 2025Adaptive Attacks Break Defenses Against Indirect Prompt Injection Attacks on LLM Agents27 Feb
Other references · 28
- 2024The Instruction Hierarchy: Training LLMs to Prioritize Privileged Instructionscited by 441
- 2024Defending Against Indirect Prompt Injection Attacks With Spotlightingcited by 233
- 2020You Autocomplete Me: Poisoning Vulnerabilities in Neural Code Completioncited by 112
- 2024IRIS: LLM-Assisted Static Analysis for Detecting Security Vulnerabilitiescited by 100
- 2022Natural Attack for Pre-trained Models of Codecited by 72
- 2024Vul-RAG: Enhancing LLM-based Vulnerability Detection via Knowledge-level RAGcited by 67
- 2025RepoAudit: An Autonomous LLM-Agent for Repository-Level Code Auditingcited by 47
- 2025LLMs in Software Security: A Survey of Vulnerability Detection Techniques and Insightscited by 44
- 2026Agentic Much? Adoption of Coding Agents on GitHubcited by 31
- 2025Defending Against Prompt Injection with DataFiltercited by 30
- 2020Backdoors in Neural Models of Source Codecited by 27
- 2024MegaVul: A C/C++ Vulnerability Dataset with Comprehensive Code Representationcited by 27
16 more
- 2024LLMDFA: Analyzing Dataflow in Code with Large Language Modelscited by 22
- 2025LLM Can be a Dangerous Persuader: Empirical Study of Persuasion Safety in Large Language Modelscited by 21
- 2024SCALE: Constructing Structured Natural Language Comment Trees for Software Vulnerability Detectioncited by 17
- 2025CodeCrash: Exposing LLM Fragility to Misleading Natural Language in Code Reasoningcited by 14
- 2025PISanitizer: Preventing Prompt Injection to Long-Context LLMs via Prompt Sanitizationcited by 10
- 2026Reducing False Positives in Static Bug Detection with LLMs: An Empirical Study in Industrycited by 5
- 2025Minimizing False Positives in Static Bug Detection via LLM-Enhanced Path Feasibility Analysiscited by 4
- 2025When Names Disappear: Revealing What LLMs Actually Understand About Codecited by 4
- 2026From SFT to RL: Demystifying the Post-Training Pipeline for LLM-based Vulnerability Detectioncited by 4
- 2025Secret Breach Detection in Source Code with Large Language Modelscited by 3
- 2026LLM-based Vulnerability Detection at Project Scale: An Empirical Studycited by 3
- 2026Measuring and Exploiting Contextual Bias in LLM-Assisted Security Code Reviewcited by 3
- 2026Reasoning Hijacking: The Fragility of Reasoning Alignment in Large Language Modelscited by 1
- 2026Syntax- and Compilation-Preserving Evasion of LLM Vulnerability Detectorscited by 1
- 2026Measuring LLM Trust Allocation Across Conflicting Software Artifactscited by 1
- 2026VulWeaver: Weaving Broken Semantics for Grounded Vulnerability Detectioncited by 1
Built on by
Not cited yet.
Similar, not cited
Close in wording, no citation either way
- 2026CIBER: A Comprehensive Benchmark for Security Evaluation of Code Interpreter Agents
- 2026MulVul: Retrieval-augmented Multi-Agent Code Vulnerability Detection via Cross-Model Prompt Evolution
- 2026On Understanding, Identifying, and Mitigating Vulnerabilities in Agentic Large Language Models
- 2023Survey of Vulnerabilities in Large Language Models Revealed by Adversarial Attacks
- 2026Universal Defenses for Tool-Integrated LLM Agents Against Adversarial Attacks
- 2026OpenAnt: LLM-Powered Vulnerability Discovery Through Code Decomposition, Adversarial Verification, and Dynamic Testing
- 2025A Systematic Study of Code Obfuscation Against LLM-based Vulnerability Detection
- 2024Targeting the Core: A Simple and Effective Method to Attack RAG-based Agents via Direct LLM Manipulation