Security-Focused LLM Agent Harness for Automated Vulnerability Discovery

cloudflare · Tech · 2026 · source Agentic: yes · promotional bias: low · source-backed · extracted with prompt 0.5.6 (schema v2)

Generated from extraction.json — do not edit by hand. Every claim cites verbatim source evidence; stated means the quote directly asserts the claim, implied means it supports it indirectly.

Problem

Domain: AI-assisted vulnerability discovery

Cloudflare found that generic coding agents were poorly shaped for broad vulnerability research across large codebases, even when specialized security-focused models could reason about exploit chains and proofs.

Constraints:

Architecture

Cloudflare built a vulnerability-discovery harness around Mythos Preview and other frontier/security models. The harness first builds repository architecture context and a task queue, then runs many narrow hunter agents in parallel with scratch environments, sends findings to an independent adversarial reviewer, traces confirmed shared-library bugs across consumer repositories, generates new hunt tasks for reachable traces, and writes schema-validated reports into an ingest API.

Diagram confidence: explicit (topology described by the source).

flowchart LR
  A["Repository corpus"] --> B["Architecture scout agent"]
  B --> C["Task queue"]
  C --> D["Hunter agents"]
  D --> E["Exploration subagents"]
  D --> F["Scratch proof environment"]
  D --> G["Adversarial reviewer"]
  G --> H["Reachability tracer agents"]
  H --> C
  H --> I["Structured report writer"]
  I --> J["Vulnerability management process"]
Drag to pan · scroll or use +/− to zoom · reconstructed from the source's described component topology

Components

Component Role Interacts with
Repository corpus Cloudflare runtime, edge data path, protocol stack, control plane, and dependency code under analysis. Architecture scout agent
Architecture scout agent Reads the repository, produces architecture context, and creates the initial task queue. Repository corpus, Task queue
Task queue Pairs attack classes with scope hints for downstream vulnerability hunters. Architecture scout agent, Hunter agents, Reachability tracer agents
Hunter agents Run many narrow vulnerability-search tasks in parallel and fan out to exploration subagents. Task queue, Exploration subagents, Scratch proof environment, Adversarial reviewer
Exploration subagents Investigate specific subsystems or hypotheses under each hunter. Hunter agents
Scratch proof environment Per-task environment where agents compile and run proof-of-concept code. Hunter agents
Adversarial reviewer Independent agent that re-reads code and attempts to disprove findings without generating new ones. Hunter agents, Reachability tracer agents
Reachability tracer agents Fan out across consumer repositories to decide whether attacker-controlled input reaches confirmed bugs. Adversarial reviewer, Task queue, Structured report writer
Structured report writer Writes schema-validated reports and submits them to an ingest API. Reachability tracer agents, Vulnerability management process
Vulnerability management process Formal triage, validation, remediation, and action decisions for surfaced findings. Structured report writer

Data flow

An architecture agent reads a repository and emits trust-boundary context plus initial tasks; concurrent hunter agents investigate one attack class and scope at a time, using tools to compile and run proof-of-concept code in scratch directories; an independent reviewer tries to disprove each finding; tracer agents fan out across consumer repositories with a symbol index to test reachability; confirmed reachable findings become reports written to a predefined schema and submitted to Cloudflare's vulnerability process.

3 supporting quotes
“An agent reads the repository from the top down, fans out to subagents responsible for each subsystem, and produces an architecture document”article, stated
“Hunters (the agents that actually look for bugs) run concurrently, typically around fifty at once”article, stated
“An agent writes a structured report against a predefined schema, fixes any validation errors against that schema itself, and submits the report to an ingest API.”article, stated

Why this architecture

Cloudflare built a harness because vulnerability research needs parallel, narrow, hypothesis-driven work, proof generation, adversarial filtering, and reachability tracing; a generic single-stream coding agent produced findings but not meaningful coverage or reliable value at scale.

3 supporting quotes
“A single agent session (even with subagents) against a hundred-thousand-line repository can cover maybe a tenth of a percent of the surface”article, stated
“Parallel narrow tasks beat one exhaustive agent - Coverage improves when many agents work on tightly scoped questions”article, stated
“It's a harness that helps you achieve the final outcomes.”article, stated

Models used: Mythos Preview · frontier models · security-focused LLMs

Scale

Alternatives considered (roads not taken)

Point a generic coding agent at a repository

Rejected because: It can produce findings but cannot provide meaningful coverage of real codebases or valuable vulnerability triage at scale.

“point a generic coding agent at an arbitrary repository and ask it to discover vulnerabilities.”article, stated
“it doesn't work in producing meaningful coverage of a real codebase and identifying findings of value.”article, stated

Let the initial finder check its own work

Rejected because: Cloudflare found adversarial review with a separate prompt/model reduced noise.

“Adding a second agent between the initial finding and the queue - one with a different prompt, a different model”article, stated
“way more effective than just telling one agent to be careful.”article, stated

Ask one agent to judge bug existence and exploit reachability together

Rejected because: The model reasoned better when bug existence and attacker reachability were split into narrower questions.

“Asking "Is this code buggy?" and "Can an attacker actually reach this bug from outside the system?" are two different questions”article, stated

Patterns

multi-agent-orchestration (agent-architecture)

Cloudflare decomposed vulnerability research into architecture, hunter, reviewer, tracer, and report-writing agents that each answer narrower questions.

“Splitting the chain across agents produces better reasoning”article, stated
“each question is narrower than the combined version.”article, stated

tool-use-orchestration (agent-execution)

Hunter agents compile and run proof-of-concept code in per-task scratch directories instead of stopping at textual vulnerability descriptions.

“Each hunter has access to tools that compile and run proof-of-concept code in a per-task scratch directory.”article, stated

eval-driven-development (quality-control)

The harness deliberately over-reports for recall, then uses adversarial review and schema validation to reduce noise before findings hit the queue.

“Our harnesses are deliberately tuned to over-report, so we see more (and miss less), which comes with a lot more noise.”article, stated
“An agent writes a structured report against a predefined schema, fixes any validation errors against that schema itself”article, stated

Tradeoffs

Tune harnesses to over-report.

Chose higher recall with more noise over low-noise filtering that might miss bugs.

Rationale: Cloudflare preferred seeing more findings and reducing them later through review and triage.

“Our harnesses are deliberately tuned to over-report, so we see more (and miss less), which comes with a lot more noise.”article, stated

Use many narrow agents in parallel.

Chose attack-class/scope-specific hunters over one exhaustive coding agent.

Rationale: Coverage improved when many agents worked on tightly scoped questions and results were deduplicated.

“* Parallel narrow tasks beat one exhaustive agent - Coverage improves when many agents work on tightly scoped questions and we deduplicate the results afterward, rather than asking one agent to be exhaustive.”article, stated

Separate adversarial review from finding generation.

Chose a reviewer agent with no ability to generate new findings over letting the finder self-review.

Rationale: Deliberate disagreement catches noise the initial finding agent would miss.

“one with a different prompt, a different model, and no ability to generate its own findings - catches a lot of the noise”article, stated

Gotchas (what bit them)

Generic agents produce shallow coverage on large repos.

Root cause: They hold one hypothesis at a time, fill context, and compact away useful state before covering enough attack surface.

Resolution: Use many narrow parallel hunters plus task queues and deduplication.

“* Context - Coding agents are tuned for one focused stream of work: building a feature, fixing a bug, writing a refactor. They ingest a lot of source code, hold a single hypothesis at a time, and iterate against it.”article, stated
“* Throughput - A single-stream agent does one thing at a time, but real codebases need many hypotheses against many components at once, with the ability to fan out further when something interesting turns up.”article, stated

Model findings can flood triage with speculation.

Root cause: Models tend to find possible bugs whether or not solid evidence exists, and hedged findings compound human attention cost.

Resolution: Tune for recall, but add adversarial review and proof generation before queueing.

“Findings come back hedged with "possibly," "potentially," "could in theory," and the hedged findings vastly outnumber the solid ones.”article, stated
“Our harnesses are deliberately tuned to over-report, so we see more (and miss less), which comes with a lot more noise. But at triage time, Mythos Preview's output has noticeably higher quality: fewer hedged findings, clearer reproduction steps, and less work to reach a fix-or-dismiss decision.”article, stated

A bug description is not enough for security prioritization.

Root cause: Security impact depends on exploitability and whether attacker-controlled input reaches the flaw.

Resolution: Generate proof code and use tracer agents to test reachability across consumer repositories.

“* Proof generation - Finding a bug and proving it's exploitable are two different things, and Mythos Preview can do both. It writes code that would trigger the suspected bug, compiles that code in a scratch environment, and runs it.”article, stated
“Turns "there is a flaw" into "there is a reachable vulnerability." This is the stage that matters most.”article, stated

Model refusals were inconsistent for legitimate security work.

Root cause: The same task could produce different model behavior depending on framing, context, or run randomness.

Resolution: Treat refusals as an operational constraint of the harness rather than assuming a model will respond consistently.

“the same task, framed differently or presented in a different context, could produce completely different outcomes”article, stated
“Semantically equivalent tasks can produce opposite outcomes depending on how and when they’re presented to the model.”article, stated

Evaluation

Cloudflare evaluated models and the harness on its own infrastructure and repositories, emphasizing exploit-chain construction, proof generation, triage quality, hedged finding reduction, reachability, and formal vulnerability management outcomes.

Metrics: number of repositories scanned · parallel hunter count · hedged finding reduction · reproduction/proof quality · fix-or-dismiss triage effort · reachability from attacker-controlled input

3 supporting quotes
“For the last few months, we've been testing a range of security-focused LLMs on our own infrastructure. These LLMs help identify potential vulnerabilities in our own systems, so we can fix them – and they also show us what attackers are going to be able to do with the latest models.”article, stated
“Our harnesses are deliberately tuned to over-report, so we see more (and miss less), which comes with a lot more noise. But at triage time, Mythos Preview's output has noticeably higher quality: fewer hedged findings, clearer reproduction steps, and less work to reach a fix-or-dismiss decision.”article, stated
“Our research with Mythos Preview was conducted in a controlled environment against our own code; every vulnerability surfaced through this work was triaged, validated, and remediated where action was needed under Cloudflare's formal vulnerability management process.”article, stated

Outcomes

The harness typically ran around 50 hunters concurrently and treated vulnerability research as many narrow tasks across large repositories rather than one long agent session.

3 supporting quotes
“a model can now take those low-severity bugs (which would traditionally sit invisible in a backlog) and chain them into a single, more severe exploit.”article, stated
“It was used to scan live code across our runtime, edge data path, protocol stack, control plane, and the open-source projects we depend on.”article, stated
“Our research with Mythos Preview was conducted in a controlled environment against our own code; every vulnerability surfaced through this work was triaged, validated, and remediated where action was needed under Cloudflare's formal vulnerability management process.”article, stated