The agent-proof shell quoting kit.
AI coding agents are great at code and terrible at shell quoting. Heredocs
that silently eat backslashes, $ variables that execute instead of
printing, ssh commands interpreted twice β every agent hits these, burns
multiple turns diagnosing them, and the failure modes are documented in
public issue trackers and an arXiv paper.
Nobody shipped the fix. So this is it.
| Piece | What it does |
|---|---|
| SKILL.md | The quoting decision tree, in the cross-agent skill format (Claude Code, Cursor, Codex, Windsurf, Antigravity) |
bashproof check |
Linter: 12 documented trap patterns, each with the evidence and the deterministic fix. --strict for CI gates |
bashproof wrap |
Converts any payload into a base64 pipeline nothing can corrupt |
bashproof test |
40-case byte-exact scorecard β verify your agent/harness preserves exact bytes |
Zero dependencies. Bash + Python 3. Works offline.
- claude-code#90630 β quoted heredocs get a hidden backslash-unescape pass
- claude-code#48317 β ssh + heredoc = multi-attempt failure loops
- claude-code#32879 β command reconstruction mangles
{}, heredoc markers,$ - QuoteBench (arXiv 2608.13547) β full taxonomy of agent quoting failures
The failures are silent: the command "works", the file gets written, and the corruption surfaces later β after the tokens are spent. bashproof turns each trap into an explicit error with a fix, before execution.
git clone https://github.com/Awaisdev01/bashproof.git ~/.claude/skills/bashproofFor Cursor/Codex/Windsurf: copy SKILL.md + scripts/ + references/ +
tests/ into your agent's rules directory.
Your agent picks it up automatically when composing risky shell commands. Drive it directly:
# Lint before running:
bashproof check deploy.sh
# CI gate:
bashproof check --strict cmd.sh
# Make any payload corruption-proof:
bashproof wrap payload.conf /etc/app.conf
printf %s NS2F... | base64 -d > /etc/app.conf
# Score your harness:
bashproof test --emit # 40 tasks; then create the files; then:
bashproof test # β 40/40 quote-proofThe 40-case suite covers backslashes, dollar signs, backticks, heredocs,
quotes-in-quotes, globs, and combined monsters. Run --emit, let your
agent do the tasks with whatever method it trusts, then get a byte-exact
scorecard:
bashproof scorecard: 40/40 exact
verdict: quote-proof
Most agents score well below that on the first run. That's the point.
New trap patterns with a reproducible case = the highest-value PR. The
cases.json format makes adding one a five-minute diff.
| Tool | |
|---|---|
| π‘ New | smsaria β open-source AI gateway for basic phones (SMS + USSD) |
| Design | nativetap β mobile design intelligence |
| Shell | bashproof β agent-proof quoting |
| Audit | diffconscience β pre-handoff diff audit |
| Launch | shipcheck β release-readiness |
| AI features | promptguard β prompt regression tests |
MIT β see LICENSE.
