All skills
jeffallan avatar

/security-reviewer

@efebc44
by jeffallanjeffallan/claude-skills12k stars
1,124

Identifies security vulnerabilities, generates structured audit reports with severity ratings, and provides actionable remediation guidance. Use when conducting security audits, reviewing code for vulnerabilities, or analyzing infrastructure security. Invoke for SAST scans, penetration testing, DevSecOps practices, cloud security reviews, dependency audits, secrets scanning, or compliance checks. Produces vulnerability reports, prioritized recommendations, and compliance checklists.

Use this Skill: https://skilld.dev/gh/jeffallan/claude-skills/security-reviewer

This session only. Nothing lands on disk.

referencesvulnerability-patterns.md

≈980 tokens on demand. Your agent reads this file only when SKILL.md points to it.

Vulnerability Patterns

SQL Injection

// VULNERABLE
const query = `SELECT * FROM users WHERE id = ${userId}`;
const query = `SELECT * FROM users WHERE name = '${name}'`;

// SECURE - Parameterized queries
const query = 'SELECT * FROM users WHERE id = $1';
db.query(query, [userId]);

// SECURE - ORM
const user = await User.findOne({ where: { id: userId } });

XSS (Cross-Site Scripting)

// VULNERABLE - Direct HTML injection
element.innerHTML = userInput;
document.write(userInput);

// SECURE - Text content
element.textContent = userInput;

// SECURE - Sanitization
import DOMPurify from 'dompurify';
element.innerHTML = DOMPurify.sanitize(userInput);

// SECURE - React (auto-escaped)
return <div>{userInput}</div>;

// VULNERABLE - React dangerouslySetInnerHTML
return <div dangerouslySetInnerHTML={{ __html: userInput }} />;

Path Traversal

// VULNERABLE
const file = path.join(uploadDir, req.query.filename);
res.sendFile(file);

// SECURE - Validate and normalize
const filename = path.basename(req.query.filename);
const file = path.resolve(uploadDir, filename);

if (!file.startsWith(path.resolve(uploadDir))) {
  throw new Error('Invalid path');
}
res.sendFile(file);

Command Injection

// VULNERABLE
exec(`ls ${userInput}`);
exec('git clone ' + repoUrl);

// SECURE - Use arrays, avoid shell
execFile('ls', [userInput]);
spawn('git', ['clone', repoUrl]);

// SECURE - Validation
const allowedCommands = ['status', 'log'];
if (!allowedCommands.includes(cmd)) throw new Error('Invalid');

IDOR (Insecure Direct Object Reference)

// VULNERABLE - No authorization check
app.get('/documents/:id', async (req, res) => {
  const doc = await Document.findById(req.params.id);
  res.json(doc);
});

// SECURE - Verify ownership
app.get('/documents/:id', async (req, res) => {
  const doc = await Document.findOne({
    _id: req.params.id,
    userId: req.user.id  // Ensure user owns document
  });
  if (!doc) return res.status(404).json({ error: 'Not found' });
  res.json(doc);
});

Insecure Deserialization

// VULNERABLE - Python pickle
import pickle
data = pickle.loads(user_input)

// SECURE - Use JSON
import json
data = json.loads(user_input)

// VULNERABLE - Node.js
const obj = eval('(' + userInput + ')');

// SECURE
const obj = JSON.parse(userInput);

Sensitive Data Exposure

// VULNERABLE - Logging sensitive data
logger.info('User login', { email, password });
console.log('Token:', authToken);

// SECURE - Redact sensitive fields
logger.info('User login', { email, password: '[REDACTED]' });

// VULNERABLE - Error response exposes internals
res.status(500).json({ error: err.stack });

// SECURE - Generic error
res.status(500).json({ error: 'Internal server error' });

Quick Reference

Vulnerability Input Vector Prevention
SQL Injection Query params Parameterized queries
XSS User content Output encoding
Path Traversal File paths path.basename + validation
Command Injection Shell args execFile, no shell
IDOR Resource IDs Authorization checks
Deserialization Serialized data JSON only
Data Exposure Logs, errors Redaction, generic errors

OWASP Top 10 Mapping

OWASP Vulnerabilities
A01 Broken Access Control IDOR, path traversal
A02 Cryptographic Failures Weak encryption, plaintext
A03 Injection SQL, XSS, command
A04 Insecure Design Missing auth, IDOR
A05 Security Misconfiguration Debug mode, default creds
A06 Vulnerable Components Outdated dependencies
A07 Auth Failures Weak passwords, session issues
A08 Data Integrity Insecure deserialization
A09 Logging Failures Missing logs, exposed data
A10 SSRF Unvalidated URLs

Source: SKILL.md on GitHub

2 alerts16d5 checks · Risk CRITICAL
  • Gen Agent Trust Hub16d

    This skill provides a comprehensive framework for security auditing and penetration testing. It includes instructions for identifying vulnerabilities, scanning for secrets, and evaluating privilege escalation paths. While it contains commands for sensitive actions such as credential harvesting and local enumeration, these are documented within a professional audit context requiring explicit authorization and rules of engagement.

  • Socket16d

    1 alert: gptAnomaly

  • Snyk16d

    Risk: LOW · No issues

  • Runlayer6mo

    5/7 files flagged

  • ZeroLeaks5mo

    Score: 93/100 · 2 sections analyzed

Signed by skilld at efebc44. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 2 months ago.

Steadyupdated 5 months ago
What it can do
Reads files Runs commands
All 4 allowed tools
ReadGrepGlobBash
Other metadata
metadata
{
  "author": "https://github.com/Jeffallan",
  "version": "1.1.1",
  "domain": "security",
  "triggers": "security review, vulnerability scan, SAST, security audit, penetration test, code audit, security analysis, infrastructure security, DevSecOps, cloud security, compliance audit",
  "role": "specialist",
  "scope": "review",
  "output-format": "report",
  "related-skills": "secure-code-guardian, code-reviewer, devops-engineer, cloud-architect, kubernetes-specialist, api-designer, mcp-developer"
}
  • Security
  • DevOps
  • vulnerability-scanning
  • sast
  • code-audit
  • penetration-testing
  • secrets-scanning
  • compliance
  • infrastructure-security
  • cvss

README badge

README badge for jeffallan/claude-skills/security-reviewer

Identifies code, infrastructure, and dependency vulnerabilities through SAST scanning, manual review, and penetration testing, then produces severity-rated audit reports with remediation guidance. Covers secrets scanning, cloud security, compliance checks, and DevSecOps workflows using tools like Semgrep, Bandit, Gitleaks, and Trivy.

Generated from the current SKILL.md.

Does this skill perform active penetration testing or only static analysis?
It does both. The skill includes SAST scanning (semgrep, bandit), dependency audits, and secrets scanning, but also supports active penetration testing and reconnaissance. However, it requires written authorization and scope confirmation before any active testing.
What automated scanning tools does this skill use?
The skill runs semgrep, bandit, gitleaks, npm audit, and trivy. It treats automated tools as a starting point and requires manual review of auth, input handling, and crypto, since tools miss context-dependent vulnerabilities.
Does this skill generate compliance reports for SOC2 or ISO27001?
The skill produces structured vulnerability reports with severity ratings, findings with remediation guidance, and checklists. It references CIS benchmarks, SOC2, and ISO27001 in its knowledge base, but is designed primarily for vulnerability identification and audit support rather than compliance certification.
Can I use this skill to test production systems?
No. The skill explicitly requires written authorization and scope confirmation before active testing, and prohibits testing on production systems without explicit permission or causing service disruption or data loss.

Generated from the current SKILL.md. These answers refresh after source changes.