agent-customs
v1.2.9
Published
Border control for the Open Agentic Web: inspect any agent network before it runs in your browser.
Maintainers
Readme
Add it to your site · Live desk · MCP server · Practice site · Test range · Contact
The problem in one minute. On Cognizant's Open Agentic Web, one website's AI assistant can call another website's assistant. That partner then runs in your browser, on your API key, reading your request. A dishonest site can hide orders in characters people cannot see, and the consent card only shows the partner's name and address, never its instructions.
Agent Customs is passport control for those partners. Fixed rules read the partner's files before they run, at no AI cost, and stamp them Cleared, Held for review or Entry denied. It remembers the version you approved, so a silent change gets caught, and it keeps runtime locks on that no clever wording can talk out of a verdict.
Watch it work
https://github.com/user-attachments/assets/856eb212-3735-4a19-86da-0168c0ab7a2b
Add it to your site
Pick one of four ways. Each works with any site made with Cognizant's agentify-website kit, and each code block below has a copy button.
<script type="module"
src="https://cdn.jsdelivr.net/gh/montbaga/[email protected]/dist/agent-customs.js"
integrity="sha384-z0EBL/rCVvBiF/5araPfKQPKMdlnmItsaIrpRUQzauW36EcPmhOlm+dglRo7Ceur"
crossorigin="anonymous"></script>// At the top of site.js
import { installCustomsGuard }
from "https://cdn.jsdelivr.net/gh/montbaga/[email protected]/site/customs/guard.js";
// Right after boot()
installCustomsGuard(booted.engine, { strict: true });npm install agent-customsimport { installCustomsGuard } from "agent-customs";
installCustomsGuard(booted.engine);// After copying site/customs/ next to your runtime/ folder, in site.js:
import { installCustomsGuard } from "./customs/guard.js";
installCustomsGuard(booted.engine);See it live: Main Street Guide is an ordinary site with the guard added the fourth way. Before you publish: npx agent-customs check <url> or the GitHub Action checks your own network. Inside your AI editor: use the MCP server. As a visitor: the browser extension checks agents on any site. Every setting and detail: Install details.
Think of airport customs
"Most people will never visit this website. The website is the showroom; the guard is what site owners take home."
| At the airport | On the Open Agentic Web | | :--- | :--- | | A traveller arriving from abroad | Another website's AI assistant | | The country they want to enter | Your browser, your AI key and your conversation | | The customs officer and the X-ray belt | Agent Customs | | The passport stamp | Cleared, Held for review or Entry denied |
| Who | Why |
| :--- | :--- |
| Sites that link to partners | If a partner's assistant tricks people, your visitors get hurt and your site gets the blame. Check partners before you link to them, the way you would check references. |
| Sites that need a guard all the time | A check before launch is not enough if a partner changes next week. The guard checks the partner's files on every load. |
| Publishers, before they ship | Like a spell-check: it finds spec mistakes, missing CORS headers, keys left in files and sly_data permissions that are wider than needed. |
| Directories and reviewers | Check whole lists of agent sites from the command line or in CI, and verify signed stamps. |
| Visitors | Protected on any guarded site, without installing anything. |
Install details
Each way to add the guard, step by step. All of them work with any site built with Cognizant's agentify-website kit, with no server, no build step and the runtime unchanged.
1. One line (easiest). Paste this into your page, above your other <script> tags. The guard switches itself on when your assistant starts.
<script type="module" src="https://cdn.jsdelivr.net/gh/montbaga/[email protected]/dist/agent-customs.js" integrity="sha384-z0EBL/rCVvBiF/5araPfKQPKMdlnmItsaIrpRUQzauW36EcPmhOlm+dglRo7Ceur" crossorigin="anonymous"></script>integrity is the file's fingerprint. If the file were ever changed, on the CDN or on the way, the browser would refuse to run it. The whole guard is in this one file (dist/agent-customs.js, built by npm run bundle), so the fingerprint covers all of it. @v1.2.9 is a fixed version; to update, take the new line from the next release. Above the other tags, the browser runs it before your page starts the assistant, and chats wait until the guard is on. If your page has a Content-Security-Policy with script-src, add https://cdn.jsdelivr.net to it.
2. Two lines, with your own settings. Load the guard from the same release and pass any of the Guard options below. A browser cannot check a fingerprint on an import, so for that use option 3 or 4.
// At the top of site.js
import { installCustomsGuard } from "https://cdn.jsdelivr.net/gh/montbaga/[email protected]/site/customs/guard.js";
// Right after the boot(...) call
installCustomsGuard(booted.engine, { strict: true });3. npm. For projects with a build step: npm install agent-customs, then import { installCustomsGuard } from "agent-customs";. The same package has the command line tool: npx agent-customs check <url>.
4. Copy the folder. To load nothing from outside, copy site/customs/ next to your runtime/ folder and use import { installCustomsGuard } from "./customs/guard.js";. The practice site does this.
- Notices in the chat. Under every partner consent card, visitors see the stamp, the problems found and a See the full report link. The notice uses Agent Customs' own wording only, so a partner's hidden text never reaches the model through it.
- It checks what will actually run. The guard inspects the network objects the runtime has just compiled, after the visitor agrees and before anything runs. A server cannot show one file to the scanner and run another. A weekly check runs every test against Cognizant's latest kit, and all 62 of its files are used unchanged.
New to the design? How it works explains every step with diagrams.
installCustomsGuard(engine) works with no options. These change its behaviour:
| Option | Default | What it does |
| :--- | :--- | :--- |
| strict | false | Asks before every partner, never pins on its own, ignores trustedActions and blocks personal details going out |
| semanticJudge | false | The AI double-check. The site's own AI also reads partners the rules cleared, their MCP tool lists and their replies, and it can only make a verdict stricter. true turns it on; a function () => boolean lets a switch on your page turn it on and off, as the desk does. Off means no tokens are used |
| locks | true | false turns off the three runtime locks and MCP tool pinning |
| canary | true | Plants a canary word in your assistant's instructions and withdraws a partner's approval if it leaks |
| trustedActions | [] | Harmless page actions that do not need an extra click after a partner reply |
| store | localStorage | Where approved fingerprints and MCP tool-list pins are kept |
| policy | Deny bad, ask on held | Which stamps block on their own and which ask the visitor |
| confirmEntry | Built-in dialog | async (report) => boolean, called for Held for review and for changed versions |
| notice | Chat notice | false hides it, or pass a function to draw your own |
| reportPage | The public desk | The page See the full report opens |
| openReport | None | (url) => void to open reports inside your own page |
| onReport | None | Called after every partner inspection |
| onLock | None | Called with { lock, kind, where, reason } when a lock stops something |
| onCanaryTrip | None | Called with { encoding, where, partners, revoked } when the canary leaks |
Try it yourself
Three ways in, fastest first:
The practice site: Main Street Guide
An ordinary town-guide site built with Cognizant's kit, in its own colours (practice/). The only change is the two-line guard install:
practice/customs/andpractice/runtime/are exact copies ofsite/.practice/site.jsdiffers only by the two guard lines.- The network passes Cognizant's
build_network.mjs --check. - Run for real, it clears Sunny Bakery, refuses Shady Pizza and holds Loop Maze.
Inside the inspection desk
| Stamp | Meaning | What the guard does | | :--- | :--- | :--- | | Cleared | No known problem found | Lets the partner in and remembers this version | | Cleared with conditions | Only notes, nothing serious | Lets it in, shows the notes, remembers this version | | Held for review | Something a person should look at, a language it cannot check, or a change since approval | Pauses and asks the visitor | | Entry denied | Hidden orders, phishing or leak links | Blocks it and explains why | | Papers not in order | Broken Open Agentic Web, A2A or MCP files | Refuses it before it runs | | Could not inspect | The host cannot be reached or does not allow cross-site reads | Nothing loads |
Screens
How well it works
Rules catch known tricks. The runtime locks limit the damage when a new trick gets past the rules. Both are measured here, and the paper has the method behind each number.
1 · The runtime locks
| Lock | What it stops | How | | :--- | :--- | :--- | | Lock 1 · Secrets stay home | Card numbers, IBANs, keys and typed-out logins leaving in partner requests, tool calls, actions, forms or links | It checks number formats and check digits (Luhn for cards, ISO 7064 for IBANs), also in other digit scripts and in Base64 | | Lock 2 · Replies and actions | "Quietly place an order", and data hidden in reply fields | It keeps only the expected reply fields, drops remote images and unknown links, pins MCP tool lists, and makes page actions wait for the visitor's click | | Lock 3 · The canary | Instructions leaking out, even encoded | It plants a canary word in your assistant's instructions and stops the call if the word shows up in anything going out, in any of ten encodings, then withdraws the partner's approval |
2 · Attack sentences (tests/attacks.test.mjs)
| What was tested | Sentences | Result | | --- | --- | --- | | A second review's sentences, written to get past the rules | 23 | All get the right verdict now | | Scam sentences in English and the 12 checked languages | 34 | All blocked | | Scam sentences in 9 other languages | 9 | All held for a person | | Honest English sentences, many close to a scam's wording | 27 | None flagged | | Honest sentences in other languages | 23 | None blocked |
The 12 checked languages are Spanish, French, German, Portuguese, Italian, Russian, Chinese, Japanese, Hindi, Arabic, Dutch and Indonesian. Text in any other language is held for a person to read, including short three-word requests in Turkish, Swedish, Norwegian, Danish, Zulu and Somali (tests/round3.test.mjs).
3 · Real MCP servers and A2A cards (tests/realworld.test.mjs)
Five batches of public tools, fetched read-only and saved, each one from hosts no earlier batch had used. A false alarm is a Held or Denied stamp on a tool a person judged harmless.
| Batch | Tools | First look (never seen before) | After fixing | | :--- | ---: | :--- | :--- | | 1 · well-known and Registry MCP servers, A2A cards | 135 | 43 (32%) | 0, with all 10 risky tools still held | | 2 · Registry MCP and A2A | 124 | 23 (18.5%) | 5 | | 3 · Registry MCP | 138 | 9 (6.5%) | 0 | | 4 · Registry MCP and A2A | 236 | 26 (11%) | 3 | | 5 · Registry MCP and A2A | 237 | 13 (5.5%) | 12, not tuned for it |
Five more batches were fetched the same way on 20 and 21 November 2026 (159, 185, 205, 160 and 92 tools; the snapshots are not in the repo). Batches 6 to 8 were used to find and fix general mistakes in the rules. Batch 8 was first measured once: 20 held without a good reason (9.8%) with the old rules, 14 (6.8%) with the 1.1.1 rules. Batches 9 and 10 were measured once for 1.1.2, before and after: 24 of 252 held without a good reason with 1.1.1, 23 (9.1%) with 1.1.2. The remaining ones are mostly wording rules reading honest text as hiding something ("without asking them again", "hide a work log entry") and look-alike letters in non-Latin text.
The attack sets that target the rules' own exceptions are now all held: probe6 22 of 22, probe7 19 of 19, probe8 27 of 27 (with 12 of 12 honest look-alikes cleared). The probe9 set, written after that round's changes, held 11 of 18 new attack wordings on its first run. probe12, written before the 1.1.1 rule changes: the old rules held 8 of its 20 tricks and the new ones hold 19, with none of its 15 honest lines held. The newest set, probe13, was written before the 1.1.2 changes and is about tool combinations, key wording, example addresses and quoted attacks: 1.1.1 held 7 of its 12 tricks and 2 of its 12 ordinary tools, 1.1.2 holds all 12 tricks and none of the ordinary tools. That is the honest measure of how the rules handle wording they were never written for.
4 · The benchmark (npm run bench)
Measured on a desktop with Node.js v24.18.0 and no AI model. The baseline is a plain word list run after the same Unicode cleaning, so the comparison is about the rules, not the decoding.
| Set | Cases | Agent Customs | Word-list baseline | Avg time | | :--- | ---: | :--- | ---: | ---: | | Round 1 · Unicode tricks | 12 | 12/12 blocked or held | 58.3% | 13.92 ms | | Round 1 · injection and phishing | 24 | 24/24 | 16.7% | 3.15 ms | | Round 1 · A2A and MCP | 6 | 4/6 (6/6 flagged with notes) | 33.3% | 5.02 ms | | Round 2 · red team (3/24 before fixes) | 24 | 23/24 (24/24 flagged) | 20.8% | 3.05 ms | | Round 3 · fresh wordings (0/15 before fixes) | 15 | 15/15 | 0.0% | 1.80 ms | | Held-out, never tuned | 10 | 6/10 | 0.0% | 1.54 ms | | Outside wordings, quoted (0/7 before format rules) | 7 | 3/7 | 14.3% | 1.57 ms | | Honest controls | 61 | 0 blocked (57 cleared, 4 with notes) | 8.2% blocked | 3.92 ms | | All detection | 159 | 87/98 blocked or held, 90/98 flagged | 19/98 | 1.81 ms median | | Lock and tamper self-tests | 25 | 25/25 pass | not applicable | about 1 ms |
5 · Signed stamps (ES256)
Agent Customs publishes signed inspection stamps (receipts/index.json) for the public networks listed in tools/receipt-sites.json. Each stamp is signed with an ECDSA P-256 key, lasts 35 days, and records the network's fingerprint, so anyone can check it is genuine and still matches the live network. A GitHub workflow signs fresh ones every month, and again after each publish for any network that changed, so the stamps on these networks never go out of date.
npm run receipts -- verify https://montbaga.github.io/agent-customs/receipts/agent-customs-range.github.io/shady_pizza/shady_pizza.json --live- The public key (
-DC99sDa-qJjBp2N):crv: "P-256",kty: "EC",x: "Wzq2yNI2mFX6Iz-GBeV7LKacVokiI396oifQRocfzxo",y: "qdaCQ4K-07HN5yiq8CfFVUgRVtJm5uszNMsjuBqWQic", also atsite/.well-known/agent-customs-key.json. - Joining the list: site owners can open a pull request that adds their public address to
tools/receipt-sites.json. A network that is not on the list gets an unsigned browser snapshot instead, whose fingerprint can still be checked on the Verify tab.
6 · What else it reads
- Three protocols (
protocols.js): Open Agentic Web networks, Google A2A cards (agent.json,agent-card.json, including other interfaces they list) and MCP (mcp.json,mcpServers, Streamable HTTP, Registryserver.json). It reads every field a model sees, including output schemas, tool titles, prompt messages and A2A skill names. - Data paths (
capabilities.js): it splitscamelCaseandsnake_casenames, sogetUserFilesandget_user_filesread the same, and it follows tools, schemas, REST toolboxes and outside addresses. A server's own hints can raise the risk, never lower it. - Partners of partners: it follows same-site partner links up to two levels deep, six targets at most, and can follow other sites too if you ask (
--transitiveon the command line). - Certificates (
certificate.js): export an SVG, a printable page or a PNG, or drop one on the Verify tab to check it. - Attack lab (
arena.js): replays hidden-text theft, an MCP data leak, the canary trap and a rug pull, without an API key.
The test range
A second site, https://agent-customs-range.github.io/, hosts sample networks, some honest and some deliberately unsafe. The unsafe ones point at .invalid addresses that do not exist.
| Network | What it shows | Stamp |
| :--- | :--- | :--- |
| sunny_bakery | An honest reference network | Cleared |
| shady_pizza | Hidden Unicode text, card theft, a remote image leak, a note aimed at reviewers | Entry denied |
| bank_helper | A look-alike bank name (Marrow Point Sаvings with a Russian "а"), a request for a one-time code, unpinned code | Entry denied |
| loop_maze | Agents calling each other in a loop, a 500-step budget, invisible and right-to-left text | Held for review |
| rugpull/sunny_bakery | A later version of the bakery that asks for contact details and adds a new partner | Held for review |
Run it anywhere: command line, MCP server, GitHub Action, browser extension
Needs Node 22 or newer and no npm packages.
git clone https://github.com/montbaga/agent-customs.git
cd agent-customs
npm test # 238 tests
npm run bench -- --verbose # the benchmark, with every flagged case
npm run check && npm run check:practice # both networks pass Cognizant's build check
node bin/agent-customs.mjs check site/samples/mcp-poisoned --sarif
node bin/agent-customs.mjs verify site/receipts/agent-customs-range.github.io/sunny_bakery/sunny_bakery.json --liveUse it as an MCP server
{
"mcpServers": {
"agent-customs": {
"command": "npx",
"args": ["-y", "agent-customs", "mcp"]
}
}
}# Claude Code (one command)
claude mcp add agent-customs -- npx -y agent-customs mcp
# Or run from a local clone (optional: set AGENT_CUSTOMS_AI_KEY for AI double-check)
node bin/agent-customs.mjs mcp| What the website does | MCP tool | Notes |
| :--- | :--- | :--- |
| Inspect URL, folder, sample ID, or pasted config | inspect_agent | Supports Open Agentic Web, Google A2A, MCP, deep checks, drift & signed stamps |
| Read finding evidence & decoded hidden text | get_inspection_details | Reveals invisible Unicode/tag text quoted as untrusted data |
| Compare two versions (or against saved pin) | compare_networks | Pass before: "pinned" to diff any target against its stored approval |
| Save or forget version pins (~/.agent-customs/pins.json) | approve_network, forget_approval | Persistent across restarts; refuses DENIED, INVALID, and UNREADABLE |
| Read desk state, examples, log & AI double-check toggle | get_desk_state, configure_ai_check | Uses optional AGENT_CUSTOMS_AI_KEY when enabled |
| Generate or check SVG/HTML/JSON/PDF certificates | issue_certificate, verify_certificate | Checks ES256 signatures offline and optionally live |
| Replay Attack Lab & run runtime Locks 1–3 | run_attack_lab, sanitize_exchange | Live scenarios plus PII/canary redaction & reply beacon sanitization |
In a GitHub workflow (keep if: always() so the SARIF file uploads even when a check holds or denies):
- uses: montbaga/agent-customs@main
with:
target: site/agent_customs
strict: "true"
sarif-file: agent-customs.sarif
- if: always()
uses: github/codeql-action/upload-sarif@v3
with:
sarif_file: agent-customs.sarifTry a rug pull on your own machine
# Two terminals
npm run serve # the desk on port 8080
npm run serve:range # the test range on port 8081 (request headers logged to range-requests.jsonl)node tools/set-origins.mjs --range http://localhost:8081
# 1. Inspect Sunny Bakery, or ask the Officer about it (this pins the clean version)
node tools/rugpull.mjs on
# 2. Click "Check for changes", or ask the Officer again: it is held, with the changes listed
node tools/rugpull.mjs off
node tools/set-origins.mjs --range https://agent-customs-range.github.ionpm run smoke drives Edge or Chrome headlessly against the local servers and fails on any page error. It starts the key vault on port 8090 if it is not running (npm run serve:vault), since a page on this computer looks for the vault there.
npm run vault:check checks the key vault end to end in a headless browser, with a stand-in AI service on this computer: a Groq or Otari key picks its own card, the page never holds the key, every AI request comes from the vault with the key, Remember key stores it only encrypted, a new visit starts locked, a wrong password does not open it, and Forget removes it. It also runs Connect with Otari against a stand-in for otari.ai: a blocked window, a closed window, a cancel and two forged replies save nothing, and an approval saves the new key for the visit and chats with it. A key left in the page's own storage by the practice site is pointed out with the settings folded, and removed with one click.
What is new in this version
This round fixed a weakness in how the rules handled their own exceptions, and it was measured on 237 real tools the rules had never seen.
- An exception can only soften a warning, never remove it. Some honest tools sound like attacks: "we email you a 6-digit code", "the tracking link". Before, the rules removed the warning for such wording, and copied scams passed silently. Now the wording only turns a finding into a note, so the stamp becomes Cleared with conditions and the visitor still sees it.
- Signatures and data are recognised by what they are. Standard signatures on agent cards and Base64-encoded JSON are decoded and checked, wherever they appear, instead of being matched by field name.
- Two more languages. Dutch and Indonesian requests for passwords and card numbers are now read word by word. Takeover, chat-leak and "download and run" orders are caught in 14 languages.
- Honest numbers. False alarms on tools never seen before dropped from about 1 in 10 to about 1 in 18. New attack sets written after the changes were measured once before they were used. The details are in How well it works and the paper.
Two security fixes (1.2.9). The MCP server and the command line tool read some addresses from local folders, and an address with an encoded ..%2f could read files outside them. The file reader now refuses any path that leaves its folder. A long run such as a-a-a-… in a file could also keep the checks busy for minutes, in the browser tab or in the MCP server, because the pattern that skips addresses and e-mails tried every split of it: 100 KB took 45 seconds, and the time grew with the square of the size. That pattern now has the length limits real addresses have, and the same file is checked in under a second.
Advice that fits MCP servers and A2A cards (1.2.8). Reports on MCP server files and A2A Agent Cards gave advice meant for websites built with the agentify-website kit, such as adding servers to allowed_peers or naming tools in a network file. Those files have neither, so the advice was wrong for their publishers. Now an MCP server that sends requests to its own online servers gets "Nothing to change in this file. A site that uses it should switch on only the tools it needs.", the allowed_peers check is left out, and no server is marked as refused by its own policy. Ask the officer about it asks what a site that uses it should know, and what the publisher should fix, if anything. Verdicts are unchanged on all 870 real-world files.
Connect with Otari from the AI double-check. The card that appears when you turn the AI double-check on without a key now offers Connect with Otari next to Set up a free key. It opens the model settings with Otari ready, and once the key is approved you go straight back to your inspection. On a held report, the AI double-check's round seal no longer covers the first word of the summary.
A neater home page. The two options under the address box are matching switches, side by side. The code box keeps all seven tabs in view and continues long lines indented under themselves, the benchmark numbers under the attack lab are in plain words, and the hidden-sentence section sits in the middle of the screen.
The inspection desk shows more at a glance. The five tabs are now lanes that say what each one holds: the last verdict, whether the officer has a model, and your latest approval. The report puts Approve, Ask the officer and the certificate right under the verdict, and a small bar keeps them at the bottom of the screen while you read further down. Findings can be filtered by severity, and the facts read like the data page of a passport. On the Officer tab the chat comes first, with the model settings beside it, and approvals show as stamps.
CORS advice fits the file (1.2.7). For an A2A Agent Card or an MCP file, the CORS check now says to send Access-Control-Allow-Origin: * on that file. It used to name agent-manifest.json, the network file and links.json, which only Open Agentic Web sites have.
The terminal command gets its own window, and failed checks name their protocol (1.2.6). When a site answers but the browser can't read it, the report now shows the command in a small terminal window with a Copy button, under the message instead of inside it. Paste it into PowerShell on Windows or Terminal on a Mac (it needs Node.js). In the report's JSON, the command is verdict.command. A failed check on an A2A Agent Card or an MCP file now shows Google A2A or MCP Catalog as its protocol, not Open Agentic Web, and an address where nothing was found shows no protocol.
"Could not inspect" now says why, and the command line runs everywhere (1.2.5). When the page could not read an address, it listed three possible reasons. It now finds the real one and says what to do:
- The site answered, but it sends no CORS header, so the browser kept the answer from the page. The message gives the command that checks it from a terminal instead:
npx -y agent-customs check <address>. - The address is a live MCP server (it ends in
/mcpor/sse), which only MCP apps can talk to. The message asks for the server'sserver.json, which Agent Customs can read. - Nothing answered, or the site was too slow. The message says which.
The command line printed nothing when it was started through a link. That is how npx and global installs start it on macOS and Linux, and how npx starts it inside this repository on Windows. It now compares the real file paths, so check, verify and mcp run however they are started. A failed check also prints its reason under the result line.
Private data sent to another site is caught in any wording (1.2.4). A QA tester found that a hotel tool asking for the guest's passport number and sending it to an outside address was only Held for review, without the leak finding (C-EXFIL). The leak check matched a short list of phrases, such as "send it to". It now looks for the private data and an address on another site together, with any verb that moves data, in any order: "share it with …", "log it at …", "it is forwarded to …", "send … the passport number", "make a request to … with it". Private data here means identity documents, card and bank details, passwords, one-time codes and the conversation. Of 30 wordings written before the change, 10 were denied before and 29 are now (the 30th, "verify it via …", is still held). The 870 real-world MCP servers and A2A cards in tests/fixtures/realworld get exactly the same findings as before, and the benchmark results are unchanged.
Connect with Otari, without copying a key. On the Other card, the key vault now has a Connect with Otari button. It opens otari.ai in a small window. You sign in there and approve a key for Agent Customs with a spending limit you choose (otari.ai suggests $5 for 30 days). The key goes straight back to the key vault, and Agent Customs starts with it. The page never sees the key or the sign-in: the vault itself asks otari.ai for the key, and the one-time code is useless without a secret the vault keeps (OAuth with PKCE). Pasting a key still works for every service. See how it works.
Old keys are easier to spot. The practice site, and versions from before the key vault, keep keys in the browser's storage for montbaga.github.io, outside the vault. When such a key is still there, the AI model settings now show a banner even while they are folded, and Delete old key removes it.
The desk also has a new switch under the address box: AI double-check. When it is on, your own AI reads every network the rules clear, and every partner the Officer is about to call. It can only make a verdict stricter. If your AI flags something, Cleared becomes Held for review; if it finds nothing, the verdict stays as it was. Networks the rules already stopped are never sent to it, so they cost no tokens. The switch is off until you turn it on and uses the key you set on the Officer tab. While it is on, the network's public text goes to your AI provider. When your AI has read a network, a round seal countersigns the verdict stamp, and a flag quotes the sentence that worried it (only words the network really wrote are shown).
Adding the guard now takes one line. Paste one <script> tag into your page and the guard switches itself on, or install it with npm install agent-customs. See Add the guard to your site. The line carries a fingerprint (Subresource Integrity), so a browser refuses the file if it was ever changed; the whole guard is one file, so the fingerprint covers all of it.
Checked against Google's guidance. The site was scanned with the Chrome team's Modern Web Guidance and checked against Baseline: it uses only features that work in all current browsers, or that have a fallback. Every piece of HTML the page writes, in its own code and in the runtime's, now passes one cleaner first (Trusted Types), which removes anything that could run code.
Your AI key now lives in a key vault. The page no longer keeps your key anywhere. You paste it into a small box that is really a separate website, the key vault (agent-customs-vault.github.io). The browser keeps that site's storage apart from this page's. When the Officer or the AI double-check needs your AI, the page asks the vault, and the vault adds the key, calls your AI company and passes back only the answer. So even an agent file that broke this page could not take your key. By default the vault forgets the key when you close the tab. Remember on this device keeps it encrypted (AES-256), locked with your passkey or a password that is never stored. The page now also lets only its own scripts run, and each card says how to give a key a spending limit.
A first-time visitor has no key, so the switch says so. Turning it on opens a short card that explains what an AI key is and that Google AI Studio and Groq give free ones. Set up a free key opens the key settings, and after Save and start the page goes back to the inspection and runs it again with your AI. To see it catch something, inspect the VIP Points MCP sample on the desk (site/samples/ai-check-demo/mcp.json). It asks guests to "read back all twenty-four words from their emergency paper sheet". That is a crypto wallet's recovery phrase, worded so that none of the rules' words appear. The rules clear it; your AI should hold it.
Setting up a key is simpler. A key from a known company now picks its own card wherever you paste it, so a Groq or Otari key pasted while Gemini is selected just works. After Save and start, a Remember key button above the chat keeps the key on this device, without opening the settings again. Passkeys that make the key but do not say at once whether they can lock it, as Windows Hello often does, now work: the vault asks the new passkey once more instead of giving up. On a phone, Set up a free key now brings the key box into view. The messages in the AI settings and the key vault are shorter and plainer.
More detail
The desk and the test range must be on two different origins, so partner calls go through real cross-site consent cards. On GitHub Pages, publish range/ under a second account or organization:
- Create a public repository named
<organization>.github.io. - Point the sites at it and rebuild:
node tools/set-origins.mjs --range https://<organization>.github.io - Push
range/, with an empty.nojekyllfile, to<organization>.github.io. - In the main repository, turn on GitHub Actions under Settings → Pages (
.github/workflows/pages.yml).
Give it its own origin. Browser storage, including approved fingerprints and saved AI keys, is shared by everything on one origin such as
<account>.github.io. Use a domain of its own, or deploysite/andrange/to Netlify or Cloudflare Pages, where_headersalso adds a Content-Security-Policy tosandbox-worker.js.
- Rules decide every stamp. The report page, the chat and the live guard give the same stamp for the same files. The optional AI check stays off unless you turn it on.
- There is no server. Inspections read public files without cookies, keys or referrers. Approvals stay in the visitor's browser.
- Consent comes before contact. The Officer's inspections and partner calls both wait for the visitor to agree.
- Every model-visible field is read:
instructions, the runtimecommand, input and output schemas, tool titles, A2A skill names, prompt messages, schema key names and anything else in the raw file. - Checked against Cognizant's kit every week. The guard wraps eight internal runtime methods, so
.github/workflows/cognizant-kit.ymlruns the tests against the latest kit every week.
The full picture, with diagrams, is in How it works.
| Spec check | Where it is done here |
| :--- | :--- |
| A network of two agents and a manifest on HTTPS | customs_officer and instruction_analyst (site/agent-manifest.json) |
| Default router and bring-your-own-key | Otari by default, plus a picker for OpenRouter, Google, Groq, OpenAI, Anthropic or any other service |
| An internal agent with grounded actions | instruction_analyst, plus 6 website tools (inspect_agent_network, compare_networks, pin_network and others) |
| Calls to other origins after approval | The Officer calls sunny_bakery and shady_pizza on the range (tests/guard.test.mjs) |
| Keys are never sent to partners | Shown in range-requests.jsonl: "authorization": false on every partner request |
| Fail closed on a bad spec or a denied partner | Runtime checks and the guard's refusals |
| Path | What it is |
| :--- | :--- |
| site/customs/ | The engine and the guard: the folder other sites copy |
| site/agent_customs.hocon | The Officer and analyst network |
| site/desk.js, view.js, certificate.js, arena.js, site.js | The desk, the certificates, the Attack lab and the guard wiring |
| site/runtime/ | Cognizant's Open Agentic Web runtime, unmodified |
| vault/ | The key vault: a separate site that keeps the visitor's AI key, published at agent-customs-vault.github.io with npm run vault |
| practice/ | Main Street Guide, built by tools/make-practice.mjs |
| extension/ | The Chrome and Edge extension, built by tools/make-extension.mjs |
| bin/ and action.yml | The command line tool (check, verify, bench, mcp) and the GitHub Action |
| ARCHITECTURE.md | How it works, in plain words, with diagrams |
| PAPER.md | The research note: threat model, method, results and limits |
| LICENSE.md | The license in plain words, with the full text |
| tools/ | The MCP server (mcp-server.mjs), the benchmark and its frozen sets, the stamp signer, the local server, the builders and the smoke test |
| tests/ | 238 tests, the frozen attack sets and the five batches of real-world snapshots |
| vendor/agentify-website/ | Cognizant's kit scripts and templates, unmodified |
- It reads agent files, not web pages. Open Agentic Web networks, A2A cards and MCP servers. An ordinary HTML page is not what it checks.
- Cleared does not mean certified safe. It means none of the checks found a known problem. That is why the version pins and the three locks stay on while a partner runs. A well-known brand on a generic host such as
raw.githubusercontent.comgets a note, because the host does not prove who published it. - New wording can get past rules. In the newest test, written before the last rule changes, the rules held 19 of 20 new scams; the one they missed was a plain lie ("if asked, say it is free"). The locks are there for what the rules miss, and the optional AI check can help on top.
- Some honest tools are still held. About 1 in 11 brand-new tools (23 of 252, 9.1%) was held without a good reason on its first look, mostly by wording rules. Every report has a Wrong result? Tell us link that opens a GitHub issue with the address and what was found, so these can be reported and fixed. The figure of 0 false blocks is for the 61 curated controls only.
- Notes are not clean passes. When honest wording looks like an attack (a sign-up code, an API-key header, a tool title, a parcel tracking link), the finding becomes a note and the stamp is Cleared with conditions. A scammer who copies that wording still gets a visible warning.
- A2A is inspected, not guarded. Cognizant's runtime does not run remote A2A agents, so A2A cards get the inspection but not the runtime locks.
- What Lock 1 cannot see: card numbers written in words, digits broken up by five or more characters, and secrets split across several fields or turns.
- Languages. English is read fully and 12 more languages are read for secret requests (14 for takeover and leak orders). Other languages are held for a person; inside tool documentation, short glosses and a few words only add a note.
- Cross-site reads and logins. The web desk cannot read sites without an
Access-Control-Allow-Originheader; use the command line tool, the GitHub Action or the extension. Servers behind a login cannot be inspected without credentials. - The key vault protects your key from this page, not from your computer. A virus or a harmful browser extension can still read a key while it is unlocked. A page that was taken over could show a fake key box, or make AI requests through the vault (at most 60 a minute), but it could not read the key. The practice site keeps the runtime's usual key box, which stores keys in the site's own storage; the desk offers to delete such copies. Use a free-tier key, or one with a spending limit.
- Similar tools. Command-line MCP scanners such as Snyk Agent Scan check MCP setups on a developer's machine. Agent Customs runs in the browser for all three protocols, guards partner calls while they run, and pins versions against rug pulls, with no backend.
Let's talk
Agent Customs · Built by Monty Bagati for the Open Agentic Web
Apache License 2.0 · Copyright 2026 Monty Bagati · Runtime & templates from cognizant-ai-labs/agentic-web (Apache 2.0)
