Review code for security concerns only. Do not define scope (diff vs codebase) or perform language/framework/architecture analysis; those are separate atomic skills. Emit a findings list in the standard format for aggregation. Focus on injection (SQL, command, template), sensitive data and logging, authentication and authorization, dependencies and CVEs, configuration and secrets, and cryptography and hashing.
Core Objective
Primary goal: Produce a security-focused findings list covering injection, sensitive data, authentication/authorization, dependencies, configuration, and cryptography for the given code scope.
Success Criteria (ALL must be met):
✅ Security-only scope: Only security dimensions are reviewed; no scope selection, language/framework conventions, or architecture analysis performed
✅ All six categories covered: Injection, sensitive data/logging, authentication/authorization, dependencies/CVEs, configuration/secrets, and cryptography are assessed where relevant
✅ Findings format compliant: Each finding includes Location, Category (cognitive-security), Severity, Title, Description, and optional Suggestion
✅ Critical issues flagged: Clear vulnerabilities (e.g. hardcoded secrets, SQL injection) are marked as critical severity
✅ Actionable output: Each finding has a specific location reference and a concrete fix or improvement suggestion
Acceptance Test: Does the output contain a findings list in the standard format covering all relevant security dimensions, with critical vulnerabilities clearly marked and actionable suggestions provided?
Sensitive data exposure in logs, responses, or client-side storage
Authentication and authorization weaknesses (auth bypass, IDOR, CSRF, session handling)
Dependency vulnerabilities and CVE assessments
Configuration and secrets management issues
Cryptographic weaknesses and key management problems
This skill does NOT handle:
Scope selection (deciding which files/paths to analyze) — scope is provided by the caller
Language/framework convention analysis — use review-dotnet, review-java, review-go, etc.
Architecture analysis — use review-architecture
Performance analysis — use review-performance
SQL-specific deep review (use review-sql for comprehensive SQL analysis)
Full orchestrated review — use orchestrate-code-review
Handoff point: When all security findings are emitted, hand off to orchestrate-code-review orchestrator for aggregation with other cognitive findings, or deliver directly to the user for security-focused review sessions.
Use Cases
Orchestrated review: Used as a cognitive step when orchestrate-code-review runs scope → language → framework → library → cognitive.
Security-focused review: When the user wants only security dimensions checked (e.g. before release or audit).
Compliance or audit: As a repeatable security checklist output for documentation.
When to use: When the task includes security review. Scope and code scope are determined by the caller or user.
Behavior
Scope of this skill
Analyze: Security dimensions in the given code scope (files or diff provided by the caller). Do not decide scope; accept the code range as input.
Do not: Perform scope selection, language/framework conventions, or architecture review. Focus only on security.
Review checklist (security dimension only)
Injection: SQL injection (parameterization, raw queries); command injection (shell, exec); template injection (user-controlled templates); path traversal; LDAP/XML injection where relevant.
Sensitive data and logging: Secrets, tokens, or PII in logs or error messages; sensitive data in URLs or client-side storage; exposure in responses or caches.
Authentication and authorization: Missing or weak authentication; broken access control (IDOR, privilege escalation); session handling and CSRF; permission checks on every sensitive operation.
Dependencies and CVEs: Known vulnerable dependencies (versions, advisories); unpinned or overly broad version ranges; supply-chain and integrity.
Configuration and secrets: Hardcoded secrets; secrets in config files or environment; secure default configuration; feature flags and debug mode in production.
Cryptography and hashing: Weak or deprecated algorithms (e.g. MD5, SHA1 for security); inappropriate use of encryption; key management and storage; password hashing (e.g. bcrypt, Argon2).
Tone and references
Professional and technical: Reference specific locations (file:line). Emit findings with Location, Category, Severity, Title, Description, Suggestion. Use severity critical for clear vulnerabilities.
Input & Output
Input
Code scope: Files or directories (or diff) already selected by the user or scope skill. This skill does not decide scope; it reviews the provided code for security only.
Output
Emit zero or more findings in the format defined in specs/findings-list.md, with Categorycognitive-security.
Category for this skill is cognitive-security.
Restrictions
Hard Boundaries
Do not perform scope selection, language, framework, or architecture review. Stay within security dimensions.
Do not give conclusions without specific locations or actionable suggestions.
Do not assume deployment or network topology unless stated; focus on code and configuration in scope.
Skill Boundaries
Do NOT do these (other skills handle them):
Do NOT select or define the code scope (diff vs codebase) — scope is determined by the caller or orchestrate-code-review
Do NOT perform language/framework convention analysis — use review-dotnet, review-java, review-go, etc.
Do NOT perform architecture or performance review — use review-architecture or review-performance
Do NOT perform comprehensive SQL analysis — use review-sql
When to stop and hand off:
When all security findings are emitted, hand off to orchestrate-code-review for aggregation in an orchestrated review
When the user needs a full review (scope + language + cognitive), redirect to orchestrate-code-review
When SQL-specific security issues dominate, suggest also running review-sql for deeper SQL coverage
Self-Check
Core Success Criteria
Security-only scope: Only security dimensions are reviewed; no scope selection, language/framework conventions, or architecture analysis performed
All six categories covered: Injection, sensitive data/logging, authentication/authorization, dependencies/CVEs, configuration/secrets, and cryptography are assessed where relevant
Findings format compliant: Each finding includes Location, Category (cognitive-security), Severity, Title, Description, and optional Suggestion
Critical issues flagged: Clear vulnerabilities (e.g. hardcoded secrets, SQL injection) are marked as critical severity
Actionable output: Each finding has a specific location reference and a concrete fix or improvement suggestion
Process Quality Checks
Was only the security dimension reviewed (no scope/language/architecture)?
Are injection, sensitive data, authz, dependencies, config/secrets, and crypto covered where relevant?
Is each finding emitted with Location, Category=cognitive-security, Severity, Title, Description, and optional Suggestion?
Are critical issues clearly marked and actionable?
Acceptance Test
Does the output contain a findings list in the standard format covering all relevant security dimensions, with critical vulnerabilities clearly marked and actionable suggestions provided?
Examples
Example 1: Hardcoded secret
Input: API key or password in source code.
Expected: Emit a critical finding; suggest environment variable or secret manager; reference the line. Category = cognitive-security.
Example 2: SQL built from user input
Input: Query string built with concatenation of user-controlled input.
Expected: Emit a critical finding for SQL injection; suggest parameterized queries. Category = cognitive-security.
Edge case: False positive
Input: Placeholder like "changeme" or "TODO" in config, not used in production.
Expected: Emit a minor/suggestion finding to remove or replace before production; do not mark as critical if context indicates non-production. If unclear, ask user or emit as suggestion.
1---2name: review-security3description: Review code for security: injection, sensitive data, auth, dependencies, config, and crypto. Atomic skill; output is a findings list.4license: MIT5---67# Skill: Review Security89## Purpose1011Review code for **security** concerns only. Do not define scope (diff vs codebase) or perform language/framework/architecture analysis; those are separate atomic skills. Emit a **findings list** in the standard format for aggregation. Focus on injection (SQL, command, template), sensitive data and logging, authentication and authorization, dependencies and CVEs, configuration and secrets, and cryptography and hashing.1213---1415## Core Objective1617**Primary goal**: Produce a security-focused findings list covering injection, sensitive data, authentication/authorization, dependencies, configuration, and cryptography for the given code scope.1819**Success Criteria** (ALL must be met):20211. ✅ **Security-only scope**: Only security dimensions are reviewed; no scope selection, language/framework conventions, or architecture analysis performed222. ✅ **All six categories covered**: Injection, sensitive data/logging, authentication/authorization, dependencies/CVEs, configuration/secrets, and cryptography are assessed where relevant233. ✅ **Findings format compliant**: Each finding includes Location, Category (`cognitive-security`), Severity, Title, Description, and optional Suggestion244. ✅ **Critical issues flagged**: Clear vulnerabilities (e.g. hardcoded secrets, SQL injection) are marked as `critical` severity255. ✅ **Actionable output**: Each finding has a specific location reference and a concrete fix or improvement suggestion2627**Acceptance Test**: Does the output contain a findings list in the standard format covering all relevant security dimensions, with critical vulnerabilities clearly marked and actionable suggestions provided?2829---3031## Scope Boundaries3233**This skill handles**:3435- Injection vulnerabilities (SQL, command, template, path traversal)36- Sensitive data exposure in logs, responses, or client-side storage37- Authentication and authorization weaknesses (auth bypass, IDOR, CSRF, session handling)38- Dependency vulnerabilities and CVE assessments39- Configuration and secrets management issues40- Cryptographic weaknesses and key management problems4142**This skill does NOT handle**:4344- Scope selection (deciding which files/paths to analyze) — scope is provided by the caller45- Language/framework convention analysis — use `review-dotnet`, `review-java`, `review-go`, etc.46- Architecture analysis — use `review-architecture`47- Performance analysis — use `review-performance`48- SQL-specific deep review (use `review-sql` for comprehensive SQL analysis)49- Full orchestrated review — use `orchestrate-code-review`5051**Handoff point**: When all security findings are emitted, hand off to `orchestrate-code-review` orchestrator for aggregation with other cognitive findings, or deliver directly to the user for security-focused review sessions.5253---5455## Use Cases5657- **Orchestrated review**: Used as a cognitive step when [orchestrate-code-review](../orchestrate-code-review/SKILL.md) runs scope → language → framework → library → cognitive.58- **Security-focused review**: When the user wants only security dimensions checked (e.g. before release or audit).59- **Compliance or audit**: As a repeatable security checklist output for documentation.6061**When to use**: When the task includes security review. Scope and code scope are determined by the caller or user.6263---6465## Behavior6667### Scope of this skill6869- **Analyze**: Security dimensions in the **given code scope** (files or diff provided by the caller). Do not decide scope; accept the code range as input.70- **Do not**: Perform scope selection, language/framework conventions, or architecture review. Focus only on security.7172### Review checklist (security dimension only)73741. **Injection**: SQL injection (parameterization, raw queries); command injection (shell, exec); template injection (user-controlled templates); path traversal; LDAP/XML injection where relevant.752. **Sensitive data and logging**: Secrets, tokens, or PII in logs or error messages; sensitive data in URLs or client-side storage; exposure in responses or caches.763. **Authentication and authorization**: Missing or weak authentication; broken access control (IDOR, privilege escalation); session handling and CSRF; permission checks on every sensitive operation.774. **Dependencies and CVEs**: Known vulnerable dependencies (versions, advisories); unpinned or overly broad version ranges; supply-chain and integrity.785. **Configuration and secrets**: Hardcoded secrets; secrets in config files or environment; secure default configuration; feature flags and debug mode in production.796. **Cryptography and hashing**: Weak or deprecated algorithms (e.g. MD5, SHA1 for security); inappropriate use of encryption; key management and storage; password hashing (e.g. bcrypt, Argon2).8081### Tone and references8283- **Professional and technical**: Reference specific locations (file:line). Emit findings with Location, Category, Severity, Title, Description, Suggestion. Use severity critical for clear vulnerabilities.8485---8687## Input & Output8889### Input9091- **Code scope**: Files or directories (or diff) already selected by the user or scope skill. This skill does not decide scope; it reviews the provided code for security only.9293### Output9495- Emit zero or more **findings** in the format defined in [specs/findings-list.md](../../specs/findings-list.md), with **Category** `cognitive-security`.96- Category for this skill is **cognitive-security**.9798---99100## Restrictions101102### Hard Boundaries103104- **Do not** perform scope selection, language, framework, or architecture review. Stay within security dimensions.105- **Do not** give conclusions without specific locations or actionable suggestions.106- **Do not** assume deployment or network topology unless stated; focus on code and configuration in scope.107108### Skill Boundaries109110**Do NOT do these** (other skills handle them):111112- Do NOT select or define the code scope (diff vs codebase) — scope is determined by the caller or `orchestrate-code-review`113- Do NOT perform language/framework convention analysis — use `review-dotnet`, `review-java`, `review-go`, etc.114- Do NOT perform architecture or performance review — use `review-architecture` or `review-performance`115- Do NOT perform comprehensive SQL analysis — use `review-sql`116117**When to stop and hand off**:118119- When all security findings are emitted, hand off to `orchestrate-code-review` for aggregation in an orchestrated review120- When the user needs a full review (scope + language + cognitive), redirect to `orchestrate-code-review`121- When SQL-specific security issues dominate, suggest also running `review-sql` for deeper SQL coverage122123---124125## Self-Check126127### Core Success Criteria128129- [ ] **Security-only scope**: Only security dimensions are reviewed; no scope selection, language/framework conventions, or architecture analysis performed130- [ ] **All six categories covered**: Injection, sensitive data/logging, authentication/authorization, dependencies/CVEs, configuration/secrets, and cryptography are assessed where relevant131- [ ] **Findings format compliant**: Each finding includes Location, Category (`cognitive-security`), Severity, Title, Description, and optional Suggestion132- [ ] **Critical issues flagged**: Clear vulnerabilities (e.g. hardcoded secrets, SQL injection) are marked as `critical` severity133- [ ] **Actionable output**: Each finding has a specific location reference and a concrete fix or improvement suggestion134135### Process Quality Checks136137- [ ] Was only the security dimension reviewed (no scope/language/architecture)?138- [ ] Are injection, sensitive data, authz, dependencies, config/secrets, and crypto covered where relevant?139- [ ] Is each finding emitted with Location, Category=cognitive-security, Severity, Title, Description, and optional Suggestion?140- [ ] Are critical issues clearly marked and actionable?141142### Acceptance Test143144Does the output contain a findings list in the standard format covering all relevant security dimensions, with critical vulnerabilities clearly marked and actionable suggestions provided?145146---147148## Examples149150### Example 1: Hardcoded secret151152- **Input**: API key or password in source code.153- **Expected**: Emit a critical finding; suggest environment variable or secret manager; reference the line. Category = cognitive-security.154155### Example 2: SQL built from user input156157- **Input**: Query string built with concatenation of user-controlled input.158- **Expected**: Emit a critical finding for SQL injection; suggest parameterized queries. Category = cognitive-security.159160### Edge case: False positive161162- **Input**: Placeholder like "changeme" or "TODO" in config, not used in production.163- **Expected**: Emit a minor/suggestion finding to remove or replace before production; do not mark as critical if context indicates non-production. If unclear, ask user or emit as suggestion.
Run npx skillmds@latest add nesnilnehc/review-security in your terminal (requires Node.js), paste this page's agent-chat prompt into Claude, Cursor, or any MCP-connected agent, or download the SKILL.md file and copy it into your agent's skills directory.
Review code for security: injection, sensitive data, auth, dependencies, config, and crypto. Atomic skill; output is a findings list. It is listed under Security on SkillMD.
This skill has not completed SkillMD's automated safety review yet. SkillMD never runs a skill's scripts for you; review the SKILL.md before installing.
This skill is tagged as working with Claude Code, Claude.ai, OpenAI Codex. SKILL.md is an open format, so most agents that read a skills directory can load it too.
Yes. Installing skills from SkillMD is free. This skill is licensed under MIT.
nesnilnehc (@nesnilnehc) published this skill. Their other Agent Skills are listed on their SkillMD profile.