security-audit
OWASP-guided security code review for a specific domain or issue
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
OWASP-guided security code review for a specific domain or issue
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
Automatically implement all sub-issues of an epic in dependency order
Implement a GitHub issue with automated PR creation
End-of-session retrospective. Captures knowledge from any working session (debug, implementation, config, deployment) as reusable scripts, CLAUDE.md procedures, or skill proposals. Run before ending a session to prevent knowledge loss.
Decompose a large GitHub issue into sub-issues and create a tracking draft PR
Project kickoff checklist based on lessons learned from previous projects. Generates a tailored checklist and optionally creates GitHub issues.
Generate a professional architecture diagram from codebase analysis
| name | security-audit |
| description | OWASP-guided security code review for a specific domain or issue |
| argument-hint | <issue-number|domain> |
| user-invocable | true |
Perform a structured, OWASP-guided security code review for a specific security domain. Designed to work with security epic sub-issues — reads the issue to understand what domain to audit, then systematically scans the codebase and produces a structured report.
$ARGUMENTS — either a GitHub issue number (e.g., 631) or a security domain keyword.
Supported domains:
dependencies — Dependency vulnerability audit (npm + pip)auth — Authentication & authorization reviewinput-validation — OWASP Top 10 input validation (SQLi, XSS, SSRF, etc.)file-uploads — File upload security reviewheaders — HTTP security headers auditrate-limiting — Rate limiting reviewdatabase — Database security reviewinfrastructure — Infrastructure, secrets, Docker, session securitypentest — OWASP ZAP baseline scanci-cd — CI/CD pipeline and GitHub Actions security reviewIf a number is provided, fetch the issue and infer the domain from its title/body.
$ARGUMENTS is a number:~/.claude/bin/gh-save.sh /tmp/security-audit-$ARGUMENTS.json issue view $ARGUMENTS --json title,body,labels
Read the file and determine which domain to audit from the issue content.
$ARGUMENTS is a domain keyword:Use it directly.
Each domain has a specific audit procedure. Follow the relevant one below.
dependencies~/.claude/bin/deps-audit.sh
Report sections: Findings table, remediation steps, accepted risks (if any).
authSystematic code review of authentication and authorization:
**/auth/**, **/security.*, **/middleware.*, **/dependencies.*WHERE user_id = current_user.idReport sections: Auth mechanism summary, findings, risk assessment.
input-validationOWASP Top 10 focused review. Verify defense-in-depth: input should be validated at multiple independent layers, so removing one layer does not compromise security.
Layer check (verify each layer is present):
.., null bytes, injection patterns)Specific vulnerability checks:
Grep for text(, execute(, raw_connection, .raw(, f"SELECT, f"INSERT, f"UPDATE, f"DELETEdangerouslySetInnerHTML, innerHTML, document.writesubprocess, os.system, os.popen, exec(, eval(../ sanitization, os.path.join with user inputrequests.get, httpx, fetch, urllib)Report sections: Per-category findings with file:line references, severity, remediation.
file-uploads**/upload*, **/photo*, **/file*, **/media*~/.claude/bin/secret-scan.sh
Report sections: Upload flow diagram, validation checks present, gaps found.
headers~/.claude/bin/security-headers-check.sh <url>
Report sections: Current header status, missing headers with recommended values, implementation location.
rate-limitingrate_limit, throttle, slowapi, RateLimiter, limitermain.py and middleware configurationsReport sections: Current rate limiting map, unprotected critical endpoints, implementation recommendation.
database**request.dict() to ORM model without schema validationReport sections: Query safety assessment, schema review, data exposure check.
infrastructure~/.claude/bin/secret-scan.sh
~/.claude/bin/env-audit.sh
~/.claude/bin/docker-audit.sh
Report sections: Automated scan results, manual findings, remediation steps.
ci-cdCI/CD pipeline security review focused on GitHub Actions supply chain attacks.
Find all workflows:
.github/workflows/*.yml and .github/workflows/*.yamlPwn Request (CRITICAL): For each workflow, check the trigger event:
pull_request_target with access to secrets = CRITICAL in public repos (allows external PRs to steal secrets)pull_request_target that checks out PR head (ref: ${{ github.event.pull_request.head.sha }}) and runs untrusted code = CRITICALpull_request is safe (forks don't get secret access)push, workflow_run, workflow_dispatch, schedule are safe (no external trigger)Script injection: Search all workflow files for untrusted input in run: blocks:
${{ github.event.pull_request.title }} — attacker-controlled PR title injected into shell${{ github.event.pull_request.body }} — attacker-controlled PR body${{ github.event.issue.title }} — attacker-controlled issue title${{ github.event.issue.body }} — attacker-controlled issue body${{ github.event.comment.body }} — attacker-controlled comment${{ github.head_ref }} — attacker-controlled branch nameenv:) or actions/github-script instead of shell interpolationThird-party Actions pinning: Check all uses: references:
uses: actions/checkout@v4 (mutable tag) = MEDIUM — could be replaced by compromised taguses: actions/checkout@<full-sha> (pinned hash) = secureuses: owner/action@main (branch ref) = HIGH — tracks mutable branchactions/*) with version tags = acceptable riskPermissions audit: For each workflow:
permissions: = MEDIUM (defaults to broad read/write)permissions: write-all or contents: write where not needed = MEDIUMid-token: write should only be present for OIDC deployments (e.g., GitHub Pages, cloud providers)Secret exposure patterns:
env: at workflow level instead of step level (broader exposure)echo or debug outputif: always() stepsRepository visibility context:
Report sections: Workflow inventory table (name, triggers, permissions, secrets used), findings by severity, third-party action inventory, remediation steps.
pentest~/.claude/bin/owasp-zap-scan.sh <url>
/tmp/zap-results/)Report sections: ZAP scan summary, triaged findings, remediation priorities.
Produce a structured report with:
## Security Audit Report: <domain>
**Issue:** #<number> (if applicable)
**Date:** <today>
**Auditor:** Claude Code (automated)
### Executive Summary
<1-3 sentences: overall assessment and critical findings count>
### Findings
| # | Severity | Finding | File | Remediation |
|---|----------|---------|------|-------------|
| 1 | CRITICAL | ... | path:line | ... |
| 2 | HIGH | ... | path:line | ... |
| 3 | MEDIUM | ... | path:line | ... |
### Detailed Findings
<per finding: description, evidence, remediation steps>
### Verified Controls
<what was checked and found to be secure — important for audit trail>
### Recommendation
<PASS / PASS WITH WARNINGS / FAIL — and next steps>
If $ARGUMENTS was an issue number:
/tmp/security-audit-report-$ARGUMENTS.md using the Write toolgh issue comment $ARGUMENTS --body-file /tmp/security-audit-report-$ARGUMENTS.md
If $ARGUMENTS was a domain keyword: