secure-code-review
Skill1 starsChanged 49 days agoMITView on GitHub
Review code, a diff, or a PR for exploitable security and correctness bugs, ranked by real attacker impact, not style. Use for code or security review requests and before merging anything that crosses a trust boundary (user input, auth, service calls, file or network I/O).
16 other projects use a version of this.
Adopted by
Most recently taken up by
- narlyseorg/superhackerstheir own version, first seen Nov 8, 2026
- jaskirat1616/grok-skillstheir own version, first seen Nov 1, 2026
- kaandgnsh/Claude-Bluetheir own version, first seen Nov 1, 2026
- Lethe044/agentskill-kittheir own version, first seen Nov 1, 2026
- zebbern/claude-code-guidetheir own version, first seen Oct 30, 2026
- Fahrnetic/engineering-agent-skill-workflowtheir own version, first seen Oct 15, 2026
Used with
Projects with it also use vulnerability-triage, threat-modeling and 2 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
superagent-aiSkillvulnerability-triage
Triage inbound vulnerability reports - GitHub Advisories (GHSA/CVE), bug bounty submissions, HackerOne/Bugcrowd/Intigriti exports, or a researcher's issue - to decide whether a finding is real, by-design, or noise. Reads the report offline, cross-references the project's documented intent and threat model (SECURITY.md, README, code, closed issues), statically audits any PoC without executing it, and emits a structured markdown triage report with a P0-P3 / By-Design severity and a recommended action. Use whenever the user asks to triage, assess, or score a vulnerability report, advisory, CVE, GHSA, or bug bounty submission, or asks "is this a real finding or by-design?".
Also in 3 projects that use this
msewellSkillthreat-modeling
Produces structured threat models for software systems using STRIDE on data flow diagrams. Generates DFDs with trust boundaries, identifies threats per element, scores risks, and defines concrete mitigations. Outputs a complete threat model Markdown document through phased, interactive delivery. Use when threat modeling a system, analyzing security threats, identifying attack surfaces, performing STRIDE analysis, assessing security risks in architecture, creating a threat model document, or when the user mentions threat model, attack surface, trust boundaries, STRIDE, or security risk analysis.
Also in 3 projects that use this
AnthropicSkillcompetitive-analysis
Framework for building competitive landscape decks — market positioning, competitor deep-dives, comparative analysis, strategic synthesis. Use when the user asks for a competitive landscape, competitor analysis, peer comparison, market positioning assessment, strategic review, or investment memo deck. Also triggers on "who are the competitors to X", "benchmark X against peers", "build a market map", or any request to systematically evaluate competitive dynamics across an industry.
Also in 3 projects that use this
AnthropicSkillincident-response
Run an incident response workflow — triage, communicate, and write postmortem. Trigger with "we have an incident", "production is down", an alert that needs severity assessment, a status update mid-incident, or when writing a blameless postmortem after resolution.
Also in 3 projects that use this
Other versions16 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 16
- zebbern/claude-code-guide★ 4.7ksame name
- nahid-sparktales/agent-dispatcher★ 59same name
- Lethe044/agentskill-kit★ 48same name
- jaskirat1616/grok-skills★ 22same name
- JayRHa/agent-skills★ 12same name
- JayRHa/AgentSkills★ 12same name
- narlyseorg/superhackers★ 8same name
- Fahrnetic/engineering-agent-skill-workflow★ 2same name
- xAmirHamza77/PenKit51★ 2same name
- Adarshukumar/skills★ 1same name
6 more not listed
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 repository32 other files it gives its agents.
- agent-system-designSkill
- api-contract-designSkill
- architecture-designSkill
- architecture-optimizationSkill
- ci-speedupSkill
- code-handoffSkill
- cross-ai-handoffSkill
- crypto-storage-auditSkill
- database-designSkill
- dataset-sourcingSkill
- distributed-debuggerSkill
- embedded-constrained-codingSkill
- freedom-to-operate-analysisSkill
- frontend-architectureSkill
- github-masterSkill
- idea-finderSkill
- ieee-paper-drafterSkill
- memory-leak-hunterSkill
- ml-model-selectionSkill
- ml-security-auditSkill
- mobile-platform-architectureSkill
- observability-designSkill
- patent-drafterSkill
- patent-novelty-evaluatorSkill
- performance-optimizationSkill
- project-scaffoldingSkill
- researcher-evaluatorSkill
- researcherSkill
- safety-compliance-scopingSkill
- scale-refactorSkill
- slow-query-optimizerSkill
- test-architectSkill
The file
We split this skill into the rules it gives an agent
4 rules. 0 are common, 4 are distinctive, and 0 are very specific to this project.
0
Common
Most of the 15 edited versions we read keep these.
4
Distinctive
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 25
Races and TOCTOU: Check-then-act on shared state, especially between a permission check and the action it guards, or a read-then-update of …
- Distinctive: line 34
Before reporting, check coverage: every checklist item you went through is either a finding or something you confirmed is handled.
- Distinctive: line 38
Use this format. Rank by exploitability, not by how easy the finding was to spot.
- Distinctive: line 54
If nothing is Critical, say so plainly.
“Common” is measured: kept by at least 6 in 10 of the 15 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Secure Code Review
A review that lists forty style nits and misses the one auth bypass is worse than no review. Find what an attacker can actually use, prove it with a concrete request, and stop.
1. Set scope and budget
- Review what was asked. For a diff or PR, review the changed lines plus the code they call into. For a file, that file plus the functions it calls. Don't read the whole repository unless asked to.
- Size the effort to the risk. Code handling auth, payments, crypto, file paths, or shell/SQL gets the full checklist. Internal utilities with no untrusted input get a quick pass of steps 2 and 3 only.
- Read everything you need in one step. Read the code together with the reference files that apply, in parallel. The references are in this skill's base directory:
references/auth-checklist.mdif the code handles login, sessions, tokens, password reset, or role checks;references/sinks.mdif it builds SQL, shell commands, file paths, templates, or outbound URLs. Skip any reference that doesn't apply. - Read the whole unit once before judging lines. A line that looks fine alone can break an invariant set elsewhere in the file.
2. Map trust boundaries
List every place untrusted data enters: request bodies, headers, query strings, cookies, file contents, environment, other services' responses, database values written by users. Then follow each one to where it is used. Most real bugs sit on these paths.
3. Check in priority order
- Authentication and authorization. Who is the caller, and how is that proven? Any identity taken from a client-controlled header, any "internal" caller trusted without proof, any check that fails open on an exception. Go through every item in
references/auth-checklist.mdthat applies. - Injection. Untrusted data reaching an interpreter: SQL, shell, templates, deserializers, file paths, URLs fetched server-side. Check the actual sink, not whether input "looks sanitized." Use the section of
references/sinks.mdfor the language in front of you. - Races and TOCTOU. Check-then-act on shared state, especially between a permission check and the action it guards, or a read-then-update of a single-use token.
- Swallowed failures. A caught exception that logs and continues past a failed check is a silent bypass.
- Secrets. Hardcoded keys, secrets in logs or error responses.
- Unsafe defaults. Fail-open behavior, debug modes, permissive CORS, missing rate limits on credential endpoints.
4. Prove each finding
For every finding, state the exact input or request that exploits it and what the attacker gets. If you can't construct one, it's Low or not a finding. Don't report theoretical issues as Critical.
Before reporting, check coverage: every checklist item you went through is either a finding or something you confirmed is handled. Minor items still go in Low, in one line each.
5. Report
Use this format. Rank by exploitability, not by how easy the finding was to spot.
## Critical | High | Medium | Low
- `file:line` **What's wrong.** Exploit: <the request or input> → <what the attacker gets>. Fix: <the specific change>.For example:
## Critical
- `routes/files.js:9` **SQL injection in rename.** Exploit: `{"id": "1 OR 1=1", "name": "x"}` → renames every file. Fix: `db.run("UPDATE files SET name = ? WHERE id = ? AND owner_id = ?", name, id, req.user.id)`.- One finding per root cause. Merge duplicates.
- End with one line naming what to fix first.
- If nothing is Critical, say so plainly. Don't pad the list to look thorough.
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.

