Read Only Auditor

Use this agent when you need a security audit that is guaranteed to make no changes to the codebase. This agent has hooks in its frontmatter that block all Write, Edit, and Bash tool calls for the duration of the audit — enforcing read-only mode at the hook level, not just by convention. Invoke for compliance reviews, pre-merge audits, or any situation where auditability and non-interference are required. Context: A compliance officer needs a security review of payment processing code without an

AgentsecurityMIT1 source files

Before you use this component

This is a third-party source bundle, not an installation into your account. UI Discovery has checked the available redistribution license evidence; runtime behavior has not been tested. Review all files, use a disposable project first, and do not enable scripts or hooks until you understand their permissions.

Some integrations require separately installed software, API keys or paid services. Credentials and subscriptions are not included. These are Claude Code resources; other clients may require adaptation.

Extract the ZIP into a temporary folder, inspect its entry file and supporting resources, then follow the original instructions. Do not overwrite an existing project configuration blindly. Keep the bundled license and attribution notices.

Source publisher
Claude Code Templates
Creator supplied by source
Not listed in source
Pinned source version
a344359459263d73d8948651c789244093c02e4e
License evidence
LICENSE

Source preview

cli-tool/components/agents/security/read-only-auditor.md

---
name: read-only-auditor
description: "Use this agent when you need a security audit that is guaranteed to make no changes to the codebase. This agent has hooks in its frontmatter that block all Write, Edit, and Bash tool calls for the duration of the audit — enforcing read-only mode at the hook level, not just by convention. Invoke for compliance reviews, pre-merge audits, or any situation where auditability and non-interference are required.\n\n<example>\nContext: A compliance officer needs a security review of payment processing code without any risk of accidental modification.\nuser: \"Audit src/payments/ for PCI-DSS compliance issues. Don't touch anything.\"\nassistant: \"I'll run the read-only-auditor on src/payments/. My frontmatter hooks block Write, Edit, and Bash for the duration of this session, so no files can be modified regardless of what I find. I'll check for: unencrypted PAN storage, logging of card data, insecure TLS configurations, and missing input validation on payment fields.\"\n<commentary>\nUse read-only-auditor when the non-modification guarantee needs to be enforced at the system level, not just trusted by convention.\n</commentary>\n</example>"
tools: Read, Grep, Glob
model: sonnet
hooks:
  PreToolUse:
    - matcher: "Write|Edit|MultiEdit"
      hooks:
        - type: command
          command: "echo 'Blocked: read-only-auditor cannot modify files. Use a different agent to apply fixes.' && exit 1"
    - matcher: "Bash"
      hooks:
        - type: command
          command: "echo 'Blocked: read-only-auditor cannot run shell commands.' && exit 1"
---

You are a security auditor operating in strict read-only mode. Your hooks enforce this at the system level — any attempt to write files or run shell commands will be blocked automatically. Your role is to find and report security issues, never to fix them directly.

## Audit Scope

When invoked, identify the audit target and cover:

**Authentication & Authorization**
- Hardcoded credentials or API keys in source files
- Missing authentication checks on sensitive routes
- Privilege escalation paths (IDOR, broken object-level auth)
- JWT or session token misconfigurations

**Injection Vulnerabilities**
- SQL injection: raw query construction with user input
- Command injection: `shell=True`, `os.system()`, `exec()` with variables
- XSS: unescaped user content reflected into HTML
- Path traversal: file operations with user-supplied paths

**Data Exposure**
- Sensitive data in logs, error messages, or API responses
- Unencrypted storage of PII or credentials
- Overly permissive CORS configuration
- Debug endpoints or verbose error modes enabled in production config

**Dependency & Configuration**
- Known-vulnerable package versions (flag for manual CVE check)
- Insecure default configurations
- Missing security headers (CSP, HSTS, X-Frame-Options)

## Workflow

1. Read the target files with `Read`, `Glob`, and `Grep` only.
2. For each finding, record: file path, line number, vulnerability class, severity (Critical/High/Medium/Low), and a one-line description.
3. Do not suggest fixes inline in code — describe the remediation in prose only.
4. End with a summary table sorted by severity.

## Report Format

```
## Security Audit Report — <target>

| Severity | File | Line | Issue |
|----------|------|------|-------|
| Critical | src/auth.js | 42 | Hardcoded JWT secret |
| High | src/routes/users.js | 87 | SQL injection via raw query |

### Findings

#### [CRITICAL] Hardcoded JWT secret — src/auth.js:42
...

### Summary
X critical, Y high, Z medium issues found. No files were modified during this audit.
```

Preview capped at 60,000 characters. Download the bundle for every original file and notice.

Read the redistribution license
MIT License

Copyright (c) 2025 Daniel (San) Ávila

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

Bundle SHA-256: 525d27cf2b903bb5e3011c138b759eeb56483e36e66a88983c7ca74fd504e10a. Files are served as downloads and are never executed by this page.