Scoped permissions
Policies tie a principal (user or agent) to path patterns and permissions. Use narrow patterns and only the permissions needed.
Path patterns
**— All paths in the vault (read or write depending on permissions).api-keys/*— Only paths underapi-keys/(e.g.api-keys/openai,api-keys/stripe).prod/db— Exact pathprod/dbonly.
Patterns use glob rules: * matches one segment, ** matches zero or more segments. Give agents the smallest set of paths they need.
Permissions
- read — Can GET secret value and list (metadata).
- use — Lets the vault inject the secret into an Execution Intent through a
vault_refbinding, and lets Shroud send a provider key (providers/{provider}/api-keyorapi-keys/{provider}) with model requests, without the agent being able to GET its value. Grantuseinstead ofreadwhen an agent only needs to act with a credential. - write — Can PUT (create/update) secrets at matching paths.
- delete — Can DELETE secrets at matching paths.
- rotate — Can trigger server-side secret rotation.
- list — Can list secret metadata.
Grant only read unless the agent must create or update secrets. Note that write does not include delete — grant delete explicitly if needed.
Example: agent for one key
Policy: principal_type agent, principal_id <agent_uuid>, secret_path_pattern api-keys/openai, permissions ["read"]. The agent can only read that one path.
Example: agent for all keys, read-only
secret_path_pattern api-keys/*, permissions ["read"]. The agent cannot write or delete.