| name | agent-config-security-audit |
| description | Use when modifying agent config files, committing configuration changes, onboarding a repository with existing agent configs, or running a periodic config hygiene check. |
Agent Config Security Audit
Systematic security review of agent configuration files. Run before committing config changes or onboarding a new repository.
When to Use
- After modifying any agent config file (
.claude/settings.json, .claude/mcp.json, AGENTS.md, hooks)
- Before committing configuration changes to version control
- When onboarding a project with existing agent configs
- Periodic hygiene check (monthly or after a major dependency update)
Scope
Audit every config file present:
| File | Agent |
|---|
.claude/settings.json | Claude Code |
.claude/mcp.json (or project-root mcp.json) | Claude Code |
.codex/config.toml | Codex |
docs/AGENTS.md (project root) | Generic/Codex |
docs/CLAUDE.md (project root) | Claude Code |
hooks/ | Any |
plugins/*/plugin.json | Agent Powerups |
.apx/relay/*.json | apx relay |
Audit Checklist
Secrets and Credentials
P0 (block immediately): Hardcoded secret in any committed file.
Permissions and Allow Lists
P0: Bash(*) or equivalent wildcard in allow list.
P1: No deniedTools list when Bash is in scope.
Hooks
P0: Command injection via interpolation in any hook.
P1: Silent error suppression on a security or quality hook.
MCP Servers
P1: Unpinned npx -y auto-install in MCP server config.
AGENTS.md / CLAUDE.md
P1: Auto-run instruction with shell exec; unconditional safety override.
Plugin Manifests
Relay Config (if present)
Classification
| Severity | Definition | Response |
|---|
| P0 | Can directly compromise security or leak secrets | Fix before any commit; do not push |
| P1 | Increases attack surface or weakens safety controls | Fix before merging; document exception if deferred |
| Note | Best practice not followed, no direct risk | Fix in follow-up; log as tech debt |
Report Format
Agent Config Security Audit — <project>/<date>
P0 findings:
[P0] <file>:<line> — <description>
Fix: <what to change>
P1 findings:
[P1] <file>:<line> — <description>
Fix: <what to change>
Notes:
[Note] <file> — <description>
Summary: <N> P0, <N> P1, <N> Notes
If no findings: state "No findings." explicitly.
Verification