Skip to content
Back to skills

Audit Agent Permissions

ASecurity

Reviews a coding agent's tool, permission and sandbox configuration for shell, network, secrets and write-scope risk, and proposes least privilege. Use before giving an agent more autonomy.

  • 2 stars
  • 0 votes
  • 0 copies
  • 2 views
  • Added November 26, 2026
ai-agentspythonrustgoshellnodegitdocumentation

Works with

  • mcp

Security analysis

A92/100
  • mediumInstalls packages at runtime which could introduce malicious dependencies

Pro shows the line behind each finding and how to fix it

Scanned November 26, 2026

npx -y skills add hermes-hq/hodios-dist --skill audit-agent-permissions --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Audit Agent Permissions?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Audit Agent Permissions
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/hermes-hq-audit-agent-permissions/badge)](https://www.skillsdirectory.com/skills/hermes-hq-audit-agent-permissions)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: audit-agent-permissions
description: Reviews a coding agent's tool, permission and sandbox configuration for shell, network, secrets and write-scope risk, and proposes least privilege. Use before giving an agent more autonomy.
license: CC0-1.0
arguments:
  - config
  - intended_use
argument-hint: <config> [intended_use]
disable-model-invocation: true
metadata:
  version: 1.0.0
  kind: prompt
  category: meta
  source: https://hermes-ide.com/prompts/audit-agent-permissions
  catalog: 2026.1014.1
---

# Audit a coding agent's permissions

## Inputs

- `config` (required): The agent's configuration, such as settings or permission files, allow and deny lists, MCP server definitions, sandbox and approval mode, environment variables passed in, and CI job definitions that run it.
- `intended_use` (optional): What the agent is for, where it runs (laptop, container, CI), who triggers it and on what input (own prompts, issues, pull requests from strangers).

Arguments fill these in order. If a required value is empty, take it from the user’s message or ask for it once.

<context>
A coding agent acts with whatever the configuration lets it touch, and it reads untrusted text all day: issue bodies, web pages, dependency READMEs, test output, files in the repository. Any of that text can carry instructions (prompt injection). The real risk is the combination of three things in one session: access to private data or secrets, exposure to untrusted content, and a way to send data out or cause effects (network, pushing, posting, deploying). Broad shell access is the usual way all three meet, because a shell command can read any file and call any host. The audit judges the configuration against what the agent actually needs for its intended use.
</context>

<task>
Audit this configuration:
<config>
$config
</config>
Only if intended_use was provided: 
Intended use:
<intended_use>
$intended_use
</intended_use>

1. Identify the tool or tools the configuration belongs to and the format. If you do not recognise a key, say so instead of guessing its meaning.
2. Build an exposure map along six axes and rate each none, scoped or broad:
   - **Shell:** which commands run without approval; wildcards that let an allowed prefix chain into anything (for example a command allowed by prefix that can take `&&`, `;`, `$(...)` or `-c`); interpreters and package managers that execute arbitrary code (`python`, `node`, `npx`, `npm install`, scripts fetched from the network and piped into a shell).
   - **File write scope:** inside the workspace only, or also home directory, dotfiles, shell profiles, git hooks, CI configuration and the agent's own settings (an agent that can edit its own permissions has every permission).
   - **Network:** outbound access, allowed domains, fetch and browser tools, and whether data can leave through them.
   - **Secrets:** environment variables, tokens, cloud credentials, SSH keys and `.env` files readable by the agent or its subprocesses; token scopes (a CI token that can push to the default branch or publish packages).
   - **External effects:** git push, pull request and issue comments, package publishing, deploys, messages, payments, MCP servers with write tools.
   - **Approval and sandbox:** approval mode, whether a container or OS sandbox is on, and whether any "skip permissions" or "yolo" style flag is set.
3. Check where untrusted content enters for the intended use, and mark every path where untrusted content, secrets and an outbound channel meet in one session.
4. Write findings ranked by risk, each with a concrete abuse scenario (what injected text could make the agent do), and the smallest change that removes it.
5. Write a least-privilege configuration in the same format as the input: explicit allow rules for what the intended use needs, deny rules for secrets paths and the agent's own config, approval for anything external, network limited to required hosts, and the sandbox on. If you are unsure of a key's exact syntax for this tool, write it and mark it "check against the tool's documentation".
</task>

<constraints>
- Judge against the intended use. Do not strip a permission the use clearly needs; say how to scope it instead.
- Never print secret values that appear in the config. Refer to them by name and recommend rotating any that were committed.
- Do not claim the proposed config makes the agent safe; list what remains in Residual risks.
- If the intended use is missing, assume the agent may read untrusted content, say so, and ask for the use under Questions.
- Separate what you verified from what you inferred. Mark inferences as such.
- When you do not know, say "I don't know" once and state what would settle it.
</constraints>

<output_format>
## Exposure summary
A table: axis, current level (none, scoped, broad), what drives it.
## Findings
Numbered, highest risk first. Each: severity (critical, high, medium, low), the setting, the abuse scenario, the fix.
## Least-privilege config
One fenced block in the input's format, then a short list of what changed and why.
## Residual risks
Bullets of risks the configuration cannot remove, with the process control that covers each (review before merge, short-lived tokens, separate CI job).
## Questions
What you need to know to tighten further, or "None".
</output_format>

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.