protect-agent-config
v0.0.1by open-coder-ai · author: chock-core
protect-agent-config is an Agent Plugin published by open-coder-ai that packages 1 skill and no MCP servers for ChatGPT, Codex, Cursor, GitHub Copilot, VS Code, and Kiro. Verified against the official Agent Plugins 1.0.0 schema on 2026-08-18; Apache-2.0 licensed; 1 stars on the host repository.
Guard against an agent hand-editing its own guardrails. Agent instruction files (AGENTS.md and the per-agent wrappers), permission files (.claude/settings.json, .mcp.json) and vendored enforcement (.chock/bin/, .chock/compiled/) define what the agent may do -- so a shell command that rewrites them is the agent modifying its own authority (MITRE ATLAS AML.T0081; the AIVSS self-modification factor). The guard refuses shell write-commands targeting those paths; reads pass, and regeneration through `chock sync` passes because the tool writes them itself rather than through shell editing. Best-effort and deliberately coarse: a compound command that both reads a protected file and writes elsewhere may be refused -- rewrite it in two steps. Escape for a human-approved change: include 'chock: approved-config-change' in the command.
- Skills
- 1
- MCP servers
- 0
- Stars
- 1
- License
- Apache-2.0
Links
Skills · 1
- protect-agent-config
Category
Security & Compliance — assigned by this directory, not declared in the manifest.
Keywords
chock · policy-as-code · rule · advise · {'control': 'asi03' · 'coverage': 'partial' · 'note': 'blocks shell self-modification of agent permission and instruction files; identity design and grant scoping remain advisory'}
Related plugins
Pre-commit gate for the mechanizable slice of excessive agency: committed agent permission grants that allow everything. A settings file whose shell grant or allow-list is a bare wildcard hands the agent unlimited tool authority for every future session, in a file reviewers rarely read as code. The agent-world twin of block-wildcard-iam: scope grants to what the task needs (e.g. Bash(git status:*)). Escape: 'pragma: allowlist broad-agency' on the same line.
Keep the development conversation out of git history. Agent-authored commits narrate by default -- who asked for what, which discussion decided it, what the plan was -- and on a public repo that narration is published forever. The guard refuses git commit commands whose message (inline -m/--message or the file behind -F/--file) contains process-leak markers; the rule tells the agent to describe the change, not the conversation, and to propose sensitive messages to the human before committing. Best-effort: markers are a narrow deny-list, and a message the human explicitly approves can say anything -- edit the marker list in the guard, the content is yours.
trigger: edits without reading, unverified completion claims, weakened tests, dead code. avoid: skipping verification, deleting assertions, leaving unused code.
Best-effort guard against destructive commands: rm -rf targeting absolute, home, or root-adjacent paths; git push --force (not --force-with-lease); git reset --hard; git clean -f; kubectl delete; terraform destroy. Known bypass classes include aliases, quoted arguments, non-standard clients, and scripts that invoke these commands indirectly. This is friction, not a security boundary.
Best-effort guard against bypassing git hooks via git commit/push --no-verify or -n. Known bypass classes include aliases, wrapper scripts, and non-standard clients. Fix the underlying hook failure instead of skipping validation.
Pre-commit gate for the mechanizable slice of ASI03: wildcard Action or Resource in IAM policy documents, AdministratorAccess attachment, GCP roles/owner or roles/editor, and Terraform wildcard action/resource lists. An agent's identity design stays with the advisory owasp-asi03 policy; this blocks the grants whose blast radius is everything. Escape: 'pragma: allowlist broad-privilege' on the same line.
Show the badge
protect-agent-config passed verification against the official 1.0.0 schema. Add the badge to your README to show it — it links readers to this verified listing.
[](https://agentpluginsdirectory.com/plugins/protect-agent-config)✓ Verified : manifest fetched from GitHub and checked against the official Agent Plugins 1.0.0 schema (agent-plugins.org).