Cover photo

My audit agent can't submit. That's the feature.

I let language models hunt for bugs with me every day. None of them can decide that a bug is real, choose its severity or send a report. Here is how that boundary is built, and the one place it still failed.

I use LLM agents heavily in my security work. They read code faster than I do, run fuzz campaigns overnight, draft hypotheses, write proof-of-concept plans and argue with each other about whether a finding holds up.

And there is a list of things none of them can do, enforced by code rather than by asking nicely:

  • mark a finding as real;

  • set its severity;

  • execute a proof of concept without my approval of that exact plan;

  • write to the original checkout of a target;

  • raise its own budget;

  • submit anything to anyone.

This is not distrust of the models. It comes from doing the arithmetic on what a wrong submission costs, and from a few months of watching what happens to an agent's judgment when its context fills up.


The arithmetic that shaped everything

On the platform where I do most of my work, reputation moves roughly like this:

Outcome

Reputation

To recover it

Finding held in my notes

0

nothing to recover

Informative report that holds up

+2

—

Out-of-scope report at Critical

−5

about 3 good Informatives

SPAM (impact that isn't real)

−20

about 10 good Informatives

Read the last row twice. One fabricated-impact submission erases ten honest ones. It also costs something the table does not show: the next time a triager sees my name, they read the report a little more sceptically.

The asymmetry dictates the design. A system that finds ten real bugs and submits one hallucinated one is worse than a system that finds five and submits five. So the goal was never "an agent that finds more". It was an agent that can find as much as it likes, inside a structure where nothing it says becomes a claim to a third party until deterministic checks and a human have both agreed.

A session that finds nothing and submits nothing is a good session. I wrote that rule down before writing any of the code.


The boundary: advice on one side, authority on the other

The architecture has one hard line through the middle.

        ADVISORY (models)                     AUTHORITATIVE (deterministic)
  ─────────────────────────────         ──────────────────────────────────────
  read code, rank surfaces               audit state + version history
  propose hypotheses          ──────▶    open hypothesis  (if it validates)
  draft PoC plans             ──────▶    approval checkpoint (exact plan hash)
  argue for / against                    gates: scope, exclusions, duplicates,
  draft report text                      realism, deployed state, evidence
                                         terminal state: one of three words
                                                       │
                                                       ▼
                                                 human submits

On the left, models do what they are good at: breadth, speed, tirelessness, a decent first guess. On the right is a single state authority, a database with a CLI in front of it, that owns everything that counts: audit state, gates, findings, severity, reports and readiness.

Model output crosses the line in exactly one form: an open hypothesis, created only after the suggestion passes deterministic validation. The file it cites has to exist in the pinned commit. The function has to exist in that file. The claim has to be specific enough to test. A hypothesis is a question, not an answer. Nothing a model writes ever becomes a finding directly.

Every change to authoritative state increments a version and appends a replayable before/after record. The state can be rebuilt into a scratch database from that log and its hash compared with the live one, so nobody, human or model, can quietly edit history.


Three words to end an audit

Every audit ends in exactly one of three terminal states:

  • ZERO_FINDINGS: nothing survived. Only reachable after a devil's-advocate close-out, where for each critical function I write what would have to be true for a bug I missed, and then check it.

  • HELD: something real was found that is not payable or not proven. Held, not deleted. A held finding can be re-proved later. A submitted false one cannot be retracted.

  • READY_FOR_HUMAN_REVIEW: every gate has passed. A human reads it, and only a human submits.

There is no fourth word. "Basically done", "ready to submit", "looks good" and "should be fine" are not states. That sounds pedantic until you read a model's summary at the end of a long session. Language models are fluent at confident closure, and a closed vocabulary leaves no room for fluent closure that isn't backed by a state transition.


Approvals bound to a hash

Running a proof of concept is the step where advice turns into action. So it has its own checkpoint.

An agent proposes a PoC plan: which commit, which test, which commands, which network access (normally none). The plan is serialised and hashed. My approval is recorded against that hash. If the plan changes by one byte afterwards (a different test file, an extra command, a fork URL), the hash changes and the approval no longer applies.

Approval by hash rather than by intent closes a quiet failure mode. "Yes, run the PoC" is an approval of an idea. An agent that later edits the plan, for good reasons, would still be carrying my "yes" from before the edit. Binding it to bytes means I approved exactly what runs.

The same thinking applies elsewhere:

  • Target checkouts are immutable. Work happens on a re-clone at the pinned commit. git status --porcelain on the original must be empty before any spend, so an agent "fixing" a harness can never quietly modify the code under audit.

  • Budget caps are not negotiable. The daily model budget is host-wide. An agent can wait for budget, but it cannot raise a cap, switch provider or route around a lock. "Nobody" is the only entry in the approval table for cap changes.

  • Target activation traces to one human approval. No agent picks the next target by itself, however good the ranking looks.


The gates are the reviewer that never gets tired

Between "open hypothesis" and "ready for human review" sits a long list of deterministic checks. Each one exists because a specific mistake of mine got through without it:

  • Pre-hunt gates: severity floor, exclusion transcription, scope tree, prior-audit sweep and a grep of the protocol's own tests for "by design / intended / expected". All run before anyone reads contract code.

  • Duplicate and known-issue screening: before any harness or PoC work.

  • A payable-bar prediction: a stored triage prediction made under the current calibration, including an explicit "below floor" flag for the finding that is real but pays nothing on this program.

  • Realism records: the attacker model, a PoC privilege audit, impact reachability, realistic configuration, a scanner for concessions the report makes against itself, and the program's own rules, quoted.

  • Deployed state: the component the finding depends on is live on chain, shown by a pinned-block read with the file hashed.

  • Public evidence: an archived, timestamped copy of the program page.

The agents can see all of this. They can argue with it, and they can produce the records the gates ask for. They cannot mark a gate passed. A gate either computes "pass" from the records or it does not.


Where it failed anyway

This architecture let three bad findings through, and the reason is the most useful thing in this article.

All three were marked payable. An independent review found each one unpayable for a single, different reason: one needed the victim's own transaction to carry the attacker's step, one measured its profit at a configuration nobody deploys, and one had no attacker at all, because the only person who could trigger it was the user.

Every gate had passed. The post-mortem found why in one sentence:

The gates verified the quality of the evidence for the mechanism. None asked whether an attacker could reach the impact.

A PoC ran, a hash matched, a source line resolved, a severity word was present. The deterministic authority did exactly what it had been told, and it had been told to check the wrong thing.

There was a second, quieter lesson. The system already had a flag that required a fresh-context adversarial review before submission. It was off for every audit in the database. The control existed. Nothing turned it on.

So the boundary between advice and authority is necessary, and it is nowhere near sufficient. A deterministic gate is exactly as good as the question you encode in it. Moving judgment from a model into code does not make the judgment right. It makes it consistent: consistently right, or consistently wrong at scale. Those three findings went through a new set of realism gates, and they are held, not submitted.


Context loss is where the SPAM comes from

One more design rule exists purely because of how LLM agents work.

Long sessions get compacted: older context is summarised to make room. After compaction, an agent still remembers what it was doing and often forgets why certain things are forbidden. The rule-breaking I caught tended to come after a context summary rather than after a fresh start. I have not measured that rigorously; it is an observation from reading a lot of session logs, and I acted on it anyway because acting on it is cheap.

So the operating rules come with a ten-line digest that every agent must re-read at session start, after every compaction and before any decision that touches submission. The first line is the arithmetic from the table above. The digest is short so that re-reading it is cheap enough to actually happen.

SPAM happens when context is lost. The fix is not a smarter model. It is making the important context impossible to lose.


What this does not settle

  • It is slower. Every gate costs time, and some cost money. I accept that because a held finding costs nothing and a SPAM costs ten good reports.

  • It does not make the models better at finding bugs. It makes their mistakes cheap. Those are different goals, and this design only serves the second.

  • The human is still the last gate, and humans get tired. The design moves my attention to the moment it matters. It does not replace it.

  • The rules are mine. The thresholds and the gate list fit how I work and which programs I hunt. Copy the shape, not the numbers.


What I would do with this if I were you

If you use agents for security work, write down two lists before you write any code: what the agent may do, and what only you may do. Then make the second list impossible rather than discouraged. A rule in a prompt is a suggestion. A missing permission is a rule.

And write the cost table for your own platform. Once you see that one bad report costs ten good ones, most of the design decisions make themselves.

Let the model be fast. Let something else be right.