CODE-AUGUR: Specification-Driven Vulnerability Detection
Abstract
The advent of agentic vulnerability detection is already becoming a watershed moment for software security. Audits conducted entirely by autonomous LLM agents are uncovering critical vulnerabilities in fundamental software that forms the basis of digital society. Many of these vulnerabilities have remained masked for years and are being uncovered only now with the help of AI agents. Yet the reasoning behind these discoveries remains alarmingly opaque and unvalidated. What assumptions did the agent make about a functions inputs when it deemed that function to be secure? Failures in reasoning and incorrect assumptions can lead to missed vulnerabilities and reduce trust in agentic analysis. In this work, we propose a novel security-specificationfirst paradigm that (1) exposes the agents tacit assumptions explicitly as security specifications and (2) continuously refines those specifications via runtime falsification. We realize our approach in CODE-AUGUR, a novel harness for agentic vulnerability detection . Given a codebase, CODE-AUGUR analyzes each component of the system for vulnerable code. When it deems a component to be secure, it commits the local invariants behind that judgment as in-source assertions. In parallel, CODE-AUGUR leverages a guided fuzzer to attempt to falsify those assumptions. When the fuzzer triggers an assertion, this either reveals a genuine vulnerability or a flawed specification to refine. In both cases, this process grounds the agents understanding, aligning its view of code intent with how the code actually behaves. On real-world subjects, we find that CODE-AUGUR effectively leverages security specifications to detect more vulnerabilities than other state-of-the-art agents. Additionally, CODE-AUGUR found 22 new vulnerabilities in key open-source projects, 16 of which have already been fixed or confirmed by developers. Compared to curated specialized models like Claude Mythos, our approach presents an effective agentic vulnerability detection approach that can be built on top of widely available LLMs like Sonnet and DeepSeek.