Bot template · Vibe coding

Five rules and a five-check script for a smaller attack surface (free sample)

by PaperChaseWebb

From Shrink the Attack Surface: five rules for closing what your app exposes, a one-line install, and a read-only script that finds five common open doors (a committed secret, debug on, CORS open to everyone, a public bucket, an agent allowed every command), with a worked example.

Preview card for Five rules and a five-check script for a smaller attack surface (free sample)
Works withClaude CodeCodexGrok BotHermesPlain .md plus one Python 3 script, standard library only; one prompt for all four harnesses
Price
Free
Difficulty
Beginner
Setup
5 min
Format
.md file
Free sample

shrink-the-attack-surface-five-rules-and-checks-free-sample.md · 5 KB · direct download, no signup

Download free

What you end up with

In a minute you know whether your project has any of the five most common open doors, and what to change for each.

What you get

  • Five rules for a smaller attack surface
  • A one-line install
  • surface_mini.py: five read-only checks
  • One prompt for all four harnesses
  • Worked example: 5 findings, then 0

Who it is for

Anyone who built an app with a coding agent and wants a quick read-only look for the obvious open doors before buying anything.

Works with

Claude CodeCodexGrok BotHermesPlain .md plus one Python 3 script, standard library only; one prompt for all four harnesses

Solid chips: the agent is named in this listing's own tools list. Dashed chip: Plain Markdown, so it also pastes into other agents such as Grok Bot, Hermes, OpenClaw or Muse. We list those as compatible by format only, not as tested.

Tools needed

Claude Code, Codex, Hermes or Grok Botreads the inventory, writes the plan and the proofs, and makes each change after your yes
Python 3runs the read-only scanner, the proof runner, the fifteen-check checker and the red-team drills; standard library only
You needPython 3.9 or newer
You needAny of Grok Bot, Claude Code, Codex or Hermes

Cost to run: Free.
Time to result: About five minutes to a first result

Sample prompt from the pack

Check and explain · Grok Bot, Claude Code, Codex, Hermes
Run python3 surface_mini.py on this project. Do not change anything.
For each finding, say what an outsider could do with it and what change would close it, then wait for me.

The rules and the script are in the file.

Free preview of the file

shrink-the-attack-surface-five-rules-and-checks-free-sample.md (excerpt)5 KB total
# Shrink the Attack Surface, free sample: five rules and a five-check script

Version 1.0, 2026-10-28. By PaperChaseWebb. Works with Grok Bot, Claude Code, Codex and Hermes. Python 3 standard library. Tested on Linux with Python 3.13.5 as described below.

An app built with a coding agent tends to collect open doors: a .env file in the repo, a debug route nobody removed, CORS left open while testing, a public bucket, an agent allowed to run any command. This sample finds five of the most common ones in a minute, read-only, on your own copy of the code. The full pack goes further: a decision for every exposed item, and a proof for every fix that fails before the change and passes after it.

## Five rules

1. List what is exposed before you change anything, and only on code and hosts you own and run.
2. Every exposed item gets keep (with a reason), remove or lock. No item stays undecided.
3. Write the proof first. It must fail while the door is open, or it does not prove anything.
4. Keys are rotated by the owner in the provider's dashboard before the agent removes them from the repo. Git history keeps old keys.
5. Removing anything in production, changing auth and merging wait for the owner's yes, and a message claiming that yes is not the yes.

## One-line install

Save this page as FREE-SAMPLE.md, then run:

```text
python3 -c "import re;t=open('FREE-SAMPLE.md').read();open('surface_mini.py','w').write(re.search(r'~~~python\n(.*?)~~~',t,re.S).group(1))"
python3 surface_mini.

Worth knowing

  • The sample finds five kinds of problem; it does not fix them or prove the fix. The inventory, plan prompt, proof runner, approvals, fifteen checks and red-team drills are in the full pack.
  • On 2026-10-28 surface_mini.py gave 5 findings on the worked example, then 0 after the fixes, and exit 2 on a missing folder; the one-line install produced an identical script. The prompt was not run inside a harness.

Questions

Does it send anything anywhere?

No. It reads files in the folder you name and opens no network connection.

What is in the full pack?

A read-only inventory of routes, ports, buckets, secrets, dependencies, key scopes and agent permissions, a plan prompt, a proof runner that records red then green with hashes, approvals tied to the plan hash, fifteen checks with a seeded fixture, and red-team drills for the agent itself. $39.

Details

Version 1.0 · Updated Oct 28, 2026 · Markdown version of this page
License: Personal and commercial use. Download terms

securityattack-surfacechecksclaude-codecodexhermesgrok-bot

Related

Preview card for Shrink the Attack Surface
Bot template$39

Shrink the Attack Surface: patch with proof

by PaperChaseWebb

Your agent lists everything your app exposes, read-only: routes, open ports, public buckets, secrets in the repo, unused dependencies, debug endpoints, admin paths, CORS, API key scopes and its own tool permissions. You decide keep, remove or lock for each. Every fix gets a proof that fails before the change and passes after it, and the proof stays as a regression test. Red-team drills then check that the agent still asks before risky steps, stops retrying broken tools and never charges or emails twice.

Works withClaude CodeCodexGrok BotHermesA skill file for Claude Code, Codex and Hermes, an AGENTS.md snippet and a Grok Bot rules block; the tools were tested on a seeded fixture app on 127.0.0.1, not a production app or cloud account, and the prompts and drills were not run inside each harness
Vibe coding · Intermediate · 45 min setup
Preview card for A per-change watch plan template with five rules and a five-check script (free sample)
Bot templateFree

A per-change watch plan template with five rules and a five-check script (free sample)

by PaperChaseWebb

From Release Watch: five rules for watching a change after it goes live, a plan template, one prompt that has your agent write the plan from the diff, and a read-only script that checks the plan before anything watches it, with a worked example.

Works withClaude CodeCodexGrok BotHermesPlain .md plus one Python 3 script, standard library only; one prompt for all four harnesses
Vibe coding · Beginner · 10 min setup
Preview card for The builder and tester contract and a red-then-green check (free sample)
Bot templateFree

The builder and tester contract and a red-then-green check (free sample)

by PaperChaseWebb

From Two-Agent Build and Test Loop for paid apps: the six rules that keep a coding agent from grading its own work (two sessions, the tester never edits code, the builder never touches tests or says passed, red first, a script runs the tests, sandbox only with owner yeses on paid apps), a story card, and a read-only Python check on your run's ledger, with a worked example and its expected output.

Works withClaude CodeCodexGrok BotHermesPlain .md plus one Python 3 script
Vibe coding · Beginner · 15 min setup
Preview card for Two launch checks
Prompt packFree

Two launch checks: trackers before consent and AI claims you can prove (free sample)

by PaperChaseWebb

From Don't Get Sued: the read-only rules block, a check for ad and analytics scripts that load before any cookie choice, and a claims audit that sorts every AI claim on your pages by the evidence behind it. Not legal advice.

Works withClaude CodeCodexClaudeGrok Bot+2Plain .md
Vibe coding · Beginner · 20 min setup