agent-supply-chain-aud…
Audit the extensions AI coding agents load and trust (skills, plugins, marketplaces, hooks, settings, MCP servers, and…
Run a structured threat-modeling session for a new feature, system, or architecture — STRIDE, attack trees, data flow diagrams, abuse cases. Use when the user mentions 'threat model,' 'threat modeling,' 'STRIDE,' 'attack tree,' 'abuse case,' 'data flow diagram,' 'DFD,' 'security
Claude Code
$ npx -y skills add briiirussell/cybersecurity-skills --skill threat-modeling --agent claude-code
Codex
$ npx skills add briiirussell/cybersecurity-skills --skill threat-modeling -a codex -y
Cursor
$ npx skills add briiirussell/cybersecurity-skills --skill threat-modeling -a cursor -y
Gemini CLI
$ npx skills add briiirussell/cybersecurity-skills --skill threat-modeling -a gemini-cli -y
GitHub Copilot
$ npx skills add briiirussell/cybersecurity-skills --skill threat-modeling -a github-copilot -y
OpenCode
$ npx skills add briiirussell/cybersecurity-skills --skill threat-modeling -a opencode -y
Windsurf
$ npx skills add briiirussell/cybersecurity-skills --skill threat-modeling -a windsurf -y
name: threat-modeling description: "Run a structured threat-modeling session for a new feature, system, or architecture — STRIDE, attack trees, data flow diagrams, abuse cases. Use when the user mentions 'threat model,' 'threat modeling,' 'STRIDE,' 'attack tree,' 'abuse case,' 'data flow diagram,' 'DFD,' 'security architecture review,' 'design review,' 'pre-implementation security,' 'shift left,' 'what could go wrong,' or needs strategic security thinking before code is written." allowed-tools: Read, Grep, Glob, WebSearch
Run a structured threat-modeling session against a proposed feature, system, or architecture. This is the *design-time* security skill — different from audit (which inspects code that exists). Use this when there's a design doc, a feature spec, an architecture diagram — but not yet code.
When to use:
Cross-references: `owasp-audit` (code-level checklist that lines up with the threats this surfaces), `api-audit` (API-specific category mapping), `iam-audit` (identity decisions touch every threat model).
Model systems the user owns, builds or is authorized to assess, from designs, diagrams and code they provide. Threat modeling is design analysis; it doesn't test anything. Don't build an attack tree of someone else's product without their authorization.
Adam Shostack's framing — every threat model answers these four:
1. **What are we working on?** (Scope and model) 2. **What can go wrong?** (Threats) 3. **What are we going to do about it?** (Mitigations) 4. **Did we do a good job?** (Validation)
The rest of this skill walks through each in order.
Produce a Data Flow Diagram (DFD) at one of three levels:
A useful DFD has:
Trust boundaries are the most useful element. If you can draw exactly one diagram that shows every trust boundary in your feature, you've already done 60% of the work.
For text-only environments, render the DFD in Mermaid:
flowchart LR User[User] -- HTTPS --> WAF[WAF / CDN] WAF -- request --> API[API Gateway] API -- JWT --> Service[Service] Service -- SQL --> DB[(Postgres)] Service -- HTTPS --> Stripe[Stripe] classDef trust fill:#fff,stroke:#f00,stroke-dasharray:4 4 class API,Service trust
For each process, data store, and data flow, ask STRIDE — one threat category per letter. Not every category applies to every element, and that's fine.
| Letter | Threat | Property violated | Examples | |---|---|---|---| | **S** | **Spoofing** | Authentication | Stolen token, forged JWT, replay attack, impersonating a service | | **T** | **Tampering** | Integrity | Modifying a request mid-flight, parameter tampering, modifying stored data | | **R** | **Repudiation** | Non-repudiation | User denies an action; logs don't prove they did it | | **I** | **Information Disclosure** | Confidentiality | Leak via error messages, IDOR exposing other users' data, exposed S3 bucket | | **D** | **Denial of Service** | Availability | Resource exhaustion, expensive query bomb, billing exhaustion via paid downstream APIs | | **E** | **Elevation of Privilege** | Authorization | User → admin via mass assignment, BFLA, escape from sandbox |
A useful threat-modeling habit: for each element of the DFD, write a short table.
**Element:** API Gateway | STRIDE | Threat | Likelihood | Impact | |---|---|---|---| | S | Forged JWT — symmetric secret in env, leaks if .env exposed | M | H | | T | Request body modified between gateway and upstream service | L | M | | R | Gateway access logs deleted by attacker post-breach | L | H | | I | Verbose error responses expose internal hostnames | M | L | | D | No rate limit at the gateway → upstream services overwhelmed | H | H | | E | "X-Admin: true" header pass-through from external requests | L | C |
Likelihood and impact: L / M / H / C(ritical) — qualitative is fine; quantitative scoring is theater for most engagements.
For features with business-flow concerns, also walk abuse cases. The format is:
As a malicious actor, I want to [goal] so that I can [outcome].
Examples:
Abuse cases catch what STRID
A collection of cybersecurity skills for AI coding agents. The AI does the heavy lifting; you bring the context about your stack and your priorities.
Audit the extensions AI coding agents load and trust (skills, plugins, marketplaces, hooks, settings, MCP servers, and…
Apply the NIST AI Risk Management Framework (AI RMF 1.0) and adjacent guidance to AI / ML systems — model lifecycle governance,…
Audit REST, GraphQL, and RPC APIs against the OWASP API Security Top 10 (2023). Use when the user mentions 'API security,' 'API…
Learn from public breach disclosures — extract the audit question each one implies and check your own stack. Capital One IMDS…
Test an authorized web application for business-logic flaws and race conditions — the classes scanners cannot find. Model…
Audit CI/CD pipelines, GitHub Actions first and GitLab CI and CircleCI briefly, for the paths that give an outsider code…
Use for authorized security assessment of REST, GraphQL, WebSocket, or SOAP APIs, including discovery, authentication,…
Extract and decrypt Windows DPAPI-protected secrets (Credential Manager, browser logins/cookies, Wi-Fi credentials, KeePass keys)…
Clean and finalize authorized natural-language text intended for readers by auditing suspicious invisible Unicode and rewriting…