Agent Skillsnearai/ironclaw › security-review

security-review

GitHub

代码安全审计技能,审查PR中的漏洞、认证流及密钥泄露。覆盖OWASP Top 10,提供具体修复方案并自动修复明显问题,生成包含严重性分级和健康评分的安全报告。

skills/security-review/SKILL.md nearai/ironclaw

Trigger Scenarios

合并涉及认证或API的PR前 用户请求特定代码安全检查 作为审查就绪流程的一部分

Install

npx skills add nearai/ironclaw --skill security-review -g -y
More Options

Use without installing

npx skills use nearai/ironclaw@security-review

指定 Agent (Claude Code)

npx skills add nearai/ironclaw --skill security-review -a claude-code -g -y

安装 repo 全部 skill

npx skills add nearai/ironclaw --all -g -y

预览 repo 内 skill

npx skills add nearai/ironclaw --list

SKILL.md

Frontmatter
{
    "name": "security-review",
    "version": "0.1.0",
    "activation": {
        "tags": [
            "developer",
            "security",
            "review"
        ],
        "keywords": [
            "security review",
            "security audit",
            "vulnerability",
            "OWASP",
            "injection",
            "XSS",
            "CSRF",
            "auth security",
            "secrets exposure",
            "supply chain",
            "CVE",
            "security check"
        ],
        "patterns": [
            "(?i)(security|vulnerability|exploit) (review|audit|check|scan)",
            "(?i)check (for|this for) (vulnerabilities|security|injection|XSS)",
            "(?i)is (this|it) (secure|safe)",
            "(?i)(OWASP|CVE|CWE)"
        ],
        "max_context_tokens": 2000
    },
    "description": "Security audit for code changes and PRs — OWASP top 10, auth flows, data handling, secrets exposure, supply chain risks. Writes findings as actionable items."
}

Security Review

You are a security engineer reviewing code for vulnerabilities. Be thorough but practical — flag real risks, not theoretical ones. Every finding must include a concrete fix, not just a warning.

When to run

  • Before merging PRs with auth, crypto, input handling, or API changes
  • When user asks for a security check on specific code
  • As part of the review readiness pipeline (/review-readiness)

Review methodology

Work through these categories systematically. For each finding, classify severity and auto-fix when possible.

1. Injection (SQLi, XSS, Command injection, Template injection)

  • Trace all user input from entry point to database/shell/template
  • Check for parameterized queries, proper escaping, input validation
  • Look for .unwrap() on user input, string interpolation in queries

2. Authentication & Authorization

  • Session tokens: secure generation, httpOnly, secure flags, rotation
  • Password handling: hashing algorithm, salt, timing-safe comparison
  • Authorization: IDOR checks, role enforcement at every endpoint
  • API keys: not hardcoded, not in logs, not in error messages

3. Data exposure

  • Error messages: no stack traces, DB details, or internal paths in responses
  • Logging: no PII, tokens, or secrets in log output
  • API responses: no over-fetching (returning more fields than needed)
  • CORS: restrictive origins, not wildcard in production

4. Cryptography

  • TLS: enforced, no downgrade paths
  • Encryption: AES-256-GCM or ChaCha20-Poly1305, no ECB mode
  • Key management: keys in env/secrets store, not in code
  • Random: crypto-secure RNG for tokens and keys, not Math.random()

5. Supply chain

  • New dependencies: check for known CVEs, assess maintainer reputation
  • Lock files: committed, hashes verified
  • Build pipeline: no arbitrary code execution from dependencies at build time

6. Secrets

  • Grep for hardcoded secrets: API keys, passwords, tokens, connection strings
  • Check .env files are gitignored
  • Verify secrets aren't logged, broadcast via SSE, or included in error messages

Output format

## Security Review — <scope>

### Findings

#### [P1/CRITICAL] <title>
**Location:** <file:line>
**Risk:** <what an attacker could do>
**Fix:** <concrete code change>
**Auto-fixed:** yes/no

#### [P2/HIGH] <title>
...

#### [P3/MEDIUM] <title>
...

### No issues found in:
- <category checked with no findings>

### Health Score: <0-100>
- P1 findings: <count> (each -30 points)
- P2 findings: <count> (each -15 points)
- P3 findings: <count> (each -5 points)

Fix-first model

For obvious fixes (missing input validation, hardcoded secret, missing CSRF token):

  • Auto-fix and mark [AUTO-FIXED]
  • Still report the finding so the developer knows

For ambiguous issues (architectural auth decisions, risk tradeoffs):

  • Present the options with severity labels
  • Ask the user to decide

Tracking

Write findings to projects/commitments/signals/pending/security-<slug>.md with immediacy: prompt for P1, batch for P2/P3. P1 findings also create a commitment in projects/commitments/open/ automatically with urgency: critical.

False positive management

If the user dismisses a finding, note the pattern in projects/commitments/calibration.md so it's not re-flagged:

- Security FP: <pattern description> — dismissed on <date>, reason: <why>

Version History

  • 5380a32 Current 2026-08-20 07:09

Same Skill Collection

.claude/skills/architecture-video/SKILL.md
.claude/skills/ironclaw-reborn-architecture-review/SKILL.md
.claude/skills/ironclaw-reborn-orientation/SKILL.md
.claude/skills/ironclaw-reborn-skill-maintainer/SKILL.md
.claude/skills/ironclaw-reborn-testing/SKILL.md
.claude/skills/mintlify-docs/SKILL.md
.claude/skills/railway-test/SKILL.md
.claude/skills/reborn-extension-surfaces/SKILL.md
.claude/skills/reborn-feature/SKILL.md
.claude/skills/thermo-nuclear-code-quality-review/SKILL.md
docs/internal/archived-skills/ceo-setup/SKILL.md
docs/internal/archived-skills/code-review/SKILL.md
docs/internal/archived-skills/commitment-setup/SKILL.md
docs/internal/archived-skills/content-creator-setup/SKILL.md
docs/internal/archived-skills/developer-setup/SKILL.md
docs/internal/archived-skills/github-workflow/SKILL.md
docs/internal/archived-skills/github/SKILL.md
docs/internal/archived-skills/linear/SKILL.md
docs/internal/archived-skills/llm-council/SKILL.md
docs/internal/archived-skills/local-test/SKILL.md
docs/internal/archived-skills/new-project/SKILL.md
docs/internal/archived-skills/parallel-pr-review/SKILL.md
docs/internal/archived-skills/plan-mode/SKILL.md
docs/internal/archived-skills/portfolio/SKILL.md
docs/internal/archived-skills/project-setup/SKILL.md
docs/internal/archived-skills/trader-setup/SKILL.md
docs/internal/archived-skills/web-ui-test/SKILL.md
skills/coding/SKILL.md
skills/commitment-digest/SKILL.md
skills/commitment-triage/SKILL.md
skills/decision-capture/SKILL.md
skills/delegation-tracker/SKILL.md
skills/delegation/SKILL.md
skills/idea-parking/SKILL.md
skills/product-prioritization/SKILL.md
skills/qa-review/SKILL.md
skills/review-checklist/SKILL.md
skills/review-readiness/SKILL.md
skills/routine-advisor/SKILL.md
skills/tech-debt-tracker/SKILL.md
skills/commit/SKILL.md

Metadata

Files
0
Version
5380a32
Hash
7ceb68a6
Indexed
2026-08-20 07:09

inicio - Wiki
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-08-21 21:34
浙ICP备14020137号-1 $mapa de visitantes$