source-code-review
Skill2 starsChanged 47 days agoMITView on GitHub
Use when reviewing source code for security vulnerabilities (white-box / gray-box) — tracing untrusted input from source to dangerous sink, auditing authentication/authorization logic, finding injection, deserialization, SSRF, path traversal, secrets, and unsafe crypto, triaging SAST output, and performing variant analysis to find every instance of a bug class. Produces findings with the vulnerable code path and a fix. Authorized review of code you own or are cleared to audit.
1 other project uses a version of this.
Adopted by
Most recently taken up by
- blacklanternsecurity/red-runtheir own version, first seen Oct 25, 2026
Other versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 1
- blacklanternsecurity/red-run★ 296same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository25 other files it gives its agents.
- active-directory-pentestSkill
- agentic-ai-securitySkill
- api-secure-designSkill
- api-security-auditSkill
- cicd-supplychain-securitySkill
- cloud-pentestSkill
- container-k8s-pentestSkill
- detection-engineeringSkill
- entra-cloud-pentestSkill
- iot-embedded-pentestSkill
- llm-app-defenseSkill
- llm-redteamSkill
- mobile-pentestSkill
- network-device-pentestSkill
- network-pentestSkill
- post-exploitationSkill
- privilege-escalationSkill
- recon-osintSkill
- red-team-opsSkill
- report-writingSkill
- social-engineeringSkill
- threat-modelSkill
- vuln-chainingSkill
- web-app-pentestSkill
- wireless-pentestSkill
The file
We split this skill into the rules it gives an agent
1 rule. About 0 are common, 1 is distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 40
Treat scanner findings as leads, not verdicts: confirm reachability (is the sink actually attacker-reachable?), rule out compensating …
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Secure Source Code Review
White-box security review: read the code, follow the data, and find the flaw at its root — then fix the whole class, not just the one instance. Complements the black/gray-box runtime skills (web-app-pentest, api-security-audit) with the view an attacker doesn't have but a defender does.
0. Authorization gate
- You own the code or are authorized to audit it (repo access granted).
- Scope: which services/languages/branches; handling of any secrets found.
1. Orient before reading line-by-line
- Map the app: entry points (routes, handlers, consumers, CLI, deserializers), trust boundaries, authn/authz model, data stores, and outbound calls.
- Identify the sources (where untrusted input enters) and the dangerous sinks (DB, OS/exec, file path, template, serializer, HTTP client, HTML response).
- Note the tech stack's footguns (framework-specific unsafe APIs).
2. Source → sink tracing (taint analysis by hand)
For each sink, walk backwards: does attacker-controlled data reach it without adequate validation/encoding? Record the full path (file:line → file:line).
| Sink | Bug class if tainted | What a safe path looks like |
| SQL/ORM raw query | SQL/NoSQL injection | parameterized queries / bound params |
exec/shell/system | command injection | no shell; arg arrays; strict allow-list |
| file path join | path traversal / LFI | canonicalize + confine to base dir |
| template render | SSTI / XSS | context-aware autoescaping, no raw eval |
| deserializer | insecure deserialization | safe formats, type allow-lists, no gadget-prone libs |
| HTTP client w/ user URL | SSRF | destination allow-list, block internal ranges |
| response/DOM write | XSS | contextual output encoding |
3. Logic & design review (what SAST misses)
- Authorization: is every sensitive operation checked server-side against the authenticated principal and the specific object (BOLA/IDOR at the code level)? Deny-by-default?
- Authentication/session: token validation, expiry, fixation, password handling.
- Business logic: state-machine assumptions, race conditions/TOCTOU, limit/price/quantity trust.
- Crypto: hardcoded keys, weak algorithms, custom crypto, predictable randomness for security use.
- Secrets: credentials/keys in source, config, or history.
4. Triaging SAST output
- Treat scanner findings as leads, not verdicts: confirm reachability (is the sink actually attacker-reachable?), rule out compensating controls, and discard false positives.
- Prioritize by exploitability × impact; feed confirmed items to
vuln-chaining.
5. Variant analysis (high leverage)
Once you confirm one bug, grep the codebase for the same pattern — the unsafe API, the missing check, the dangerous sink. Root-cause mistakes repeat. Fixing the class (e.g., a safe wrapper + a lint rule) beats fixing one line.
6. Tooling
Language SAST (semgrep rules, CodeQL queries), secret scanners (gitleaks/trufflehog), dependency SCA, and plain grep/IDE for taint tracing. Prefer precise semgrep/CodeQL queries you can read over opaque scanners.
7. Reporting
Per finding: file:line source → sink path, bug class (CWE), exploitability, impact, and a concrete code-level fix (plus a lint/query to prevent regressions). Use report-writing. Checklist: references/review-checklist.md.
<sub>© 2026 noahfranklin · Part of the Gideon security suite · MIT License · Original work.</sub>
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

