Safe Command Guardrails for Coding Agents
Block, confirm, or allow every shell, git, SQL, and cloud command before your agent runs it, and catch credential leaks on the way.
Free
Works with the AI Agents you already use
Safe Command Guardrails for Coding Agents
Example session with this skill installed
Clean out the build folders, commit everything including the .env I just fixed, and push to main. Then free up disk space however you need to.
- Read your context and instructions
- Compiled the safe command guardrails
Summary
Four of the actions you asked for are fine to plan, but they fall into different safety tiers. Two need your yes, one I won't do, and one I can't do without leaking a credential.
| Command | Tier | Why |
|---|---|---|
rm -rf dist build | CONFIRM | Recursive delete. Scoped to two build folders. |
git add src/ tests/ README.md | ALLOW | Files staged by name, not git add -A. |
git add .env | SECRET | Would commit a credentials file to history. Refused. |
git push origin main | CONFIRM | Visible outside this machine. |
rm -rf ~ (suggested "free up disk space") | BLOCK | Deletes your home directory. Never run. |
What I'll do after you approve
- Delete
dist/andbuild/. - Commit the staged files with the message "Fix config loading".
- Push to
origin main.
I left .env out of the commit. If it isn't already in .gitignore, I can add it.
For disk space, I can list the largest folders with du -sh * | sort -h so you can choose what to remove.
Reply "yes" to run steps 1 to 3, or tell me which ones to skip.
Connects securely to your tools. The creator never sees your data.
About this skill
Coding agents run commands constantly, and most of the time that is fine. The problem is the one command in a thousand that force-pushes over a teammate's work, truncates a table, or echoes an API key into a shared transcript. This skill gives your agent a clear, four-tier rule for deciding what to run.
BLOCK covers damage no project can justify: deleting root or home, formatting disks, fork bombs. SECRET covers anything that would print, stage, or upload a credential. CONFIRM covers recursive deletes, pushes, history rewrites, destructive SQL, infrastructure teardown, and package publishing. Everything else is ALLOW. The agent refuses the first two, asks before the third, and runs the fourth.
The SKILL.md is advisory. It teaches the agent how to decide and when autonomous mode does and does not count as consent. For a hard stop that does not depend on the model's judgment, the package includes a standard-library Python script that applies the same tiers mechanically and returns a distinct exit code per tier. A reference page shows how to wire it as a Claude Code PreToolUse hook in a few lines of settings.json, and how other agents can call it from their own pre-exec hooks. If the script ever breaks, it fails open with a warning, so it never silently locks you out.
Every pattern lives in a readable reference file so you can tune the lists for your project. The script ships with a self-test you can run after any change. Patterns are conservative on purpose: a grep for a dangerous string is allowed, while the same string inside bash -c is blocked.
Built by Korey Dillon (LatentAxis). Source: https://github.com/koreydillon/cipher-harness
How to use
Skills on Agensi run inside your AI agent. Copy the prompt, paste it into your agent, and it connects to Agensi and installs this skill for you. If a payment is needed, your agent shows it to you first.
Reviews
No reviews yet
Be one of the first to try it. Every listed skill passes our trust checks below.
Security scanned
Passed our 8-point scan before listing
Fresh listing
Recently published to Agensi
Free forever
No account required to browse
Trust & safety
Security scanned
Verified clean 7 days ago
- Free to download with an account