DEV Community

chovy
chovy

Posted on Originally published at chovy.bl0ggers.com

Trust and verify with agentic plugins, skills and services

Today my agents built a malware filter for our hosting network, shipped it, tested it in production, and watched it work. An hour later it was blocking our own websites.

That is the best argument I have for the line I just added to our manifesto:

Trust and verify with agentic plugins, skills and services.

We already had "trust but verify." That one says check. The new one says who checks. Not me, squinting at a diff at 2am. Agents running tools that exist only to check, each one something other than the agent that made the claim.

What we built

c0mpute hosts websites on a peer-to-peer network, and anyone can publish a site through our free cloud node. Free hosting attracts phishing kits the way a porch light attracts moths, and the domain they show up on is ours.

So we wrote a design doc (DIP-0036) and built three pieces in one session:

  1. A labeler. ThreatCrush scans a site's files with its antivirus engine and hash reputation, and signs every verdict with a public key. The verdicts go into an append-only public log. Anyone can read them and anyone can check the signature.
  2. The cloud node refuses to publish a site whose files carry a label, and says why and where to appeal.
  3. The gateways refuse to serve a labelled file, even one published some other way.

Then the agents attacked it. The standard antivirus test file got refused. A mock phishing page that mails your password to a Telegram bot got refused the first time anyone fetched it. A clean site served normally.

It shipped. It worked. And it was wrong.

Then it blocked us

The labeler also checks the reputation of domains a page loads scripts from. Our network footer loads from pit.world. pit.world sits on a spam blocklist. Not a malware list, a spam list. My code treated "listed anywhere" as "malware."

So every fleet page carrying our footer got labelled as malware, and every gateway started answering 451.

I didn't find it. Another agent did. A different session, launching a new app for me, saw its own home page refused, traced the 451 to my labeler, and sent my session a message: the fix isn't pushed, pages are still blocked, and the appeals aren't sticking. That last part was a second bug. When a page got cleared by hand, the next rescan of the exact same file issued a fresh label, and the newer label won.

The fix shipped that afternoon (#488, #490):

  • A spam listing is not evidence that a file is dangerous. Only malware and phishing listings count, and our own domains never count.
  • A granted appeal sticks for those exact bytes. The label is keyed by the file's SHA-256, so a rescan can't overrule a human on a file that didn't change.
  • The bad labels were retracted with signed records, in the same public log. Nothing was deleted, because the log can't be edited.

Then the agents verified it live: our pages get no label, and the test virus on the same page still gets caught.

The verifiers caught more than that

That was the loud one. The quiet ones never reached anybody:

  • Unit tests caught that the gateway check would have skipped almost every HTML page in production, because the hosting layer strips the length header on pages it rewrites.
  • A live smoke test caught the labeler returning 503 right after deploy, because the database's API layer hadn't noticed the new table. (I asked how others handle that one.)
  • A live publish test caught that our free cloud node had been failing every push for two days, because it was still running a binary that auto-update had deleted out from under it.

None of those were found by me reading code. Each was found by a check run by something other than the thing that wrote the code.

How to do this yourself

Put a verifier on every claim, and make sure it isn't the claimant:

  • Every diff gets a review skill before it merges. In Claude Code that's a plugin or a slash command. Use one.
  • Every push gets a scanner. We run ThreatCrush on code and on hosted files, and vu1nz on CI workflows.
  • Every verdict is signed and logged in public, so it can be checked, appealed and reversed. If your filter can't be appealed, your users will appeal to Twitter instead.
  • Every deploy gets a smoke test from a box that didn't build it, hitting the real production URL with a fresh connection.
  • Verify the verifiers. Our filter was the thing that broke. The check that caught it was another agent doing its own job.

Trust the fleet to move fast. Let a different agent prove it.

The full line, and the rest of how we run things, is in the Fleet SysOps Manifesto. Disagree? Send a pull request. An agent will merge it in prod.


How this was written: drafted with an AI assistant from my own notes and today's session, then edited by me.

Top comments (2)

Collapse
 
rambozambo profile image
rambo •

The second bug is the tell in this story. A granted appeal lost to a rescan because the human's decision was not bound to the thing it decided about. Your fix is the commitment pattern, stated plainly: key the label by the file's SHA-256, let the appeal stick for those exact bytes, and retract bad labels as new signed records in an append-only log instead of edits. Decisions recorded against digests, never rewritten. That is the same shape as an AER-1 receipt (Brennan Zambo's draft-zambo-aer1-26, the standard Zambo's records are written in): the record proves the saved result was not changed, and the judgment lives in a separate line that can be checked against it.

The gap I would name is the one in your own narrative. The loud bug was found by a different session, and the finding reached you as a message: the fix isn't pushed, pages are still blocked, the appeals aren't sticking. Cross-session findings are where records usually die. That finding deserved the same treatment as your labels: a handover the fixing session picks up, carrying the evidence (the 451 trace, the blocklist entry, the rescan behavior) as checkable steps, so the session doing the fix works from the record instead of from a summary of the record.

One vocabulary note from the receipt side, because your labeler is now a checker of other agents' claims: keep the outcomes separate. Verified, verification failed, not checked, and absent are four different answers. Your spam-list false positive was a "not checked" wearing a verdict's clothes. A checker that refuses to convict work it never actually checked is the kind other agents can safely build on.

Collapse
 
sudokat_ profile image
Gordon Chase •

Shipping a malware filter that immediately 451s your own fleet is a rite of passage. Pinning appeals to file SHA-256 fixes the rescan fight for static bytes, though an HTML page can stay byte-identical while a remote <script> domain it loads turns hostile later. Do you re-evaluate appealed hashes on a TTL or pair them with Subresource Integrity?