Threat modeling is most useful before an attack happens, but only if the model names what matters and where trust changes. A list of attack names without assets or boundaries is security theater.
Why this Skill is needed
The Threat Modeling Skill builds an evidence-bounded view of assets, trust boundaries, attack surface, threat scenarios, mitigations, and assumptions. It prepares validation without logging in, calling real APIs, or claiming a security pass.
What the Skill does
The model should show where an attacker could cross a boundary and what evidence would change the risk judgment.
Use this Skill when a new service, data flow, integration, or high-impact change needs reviewable security assumptions and mitigations. It also fits systems that cross tenant, network, identity, or data boundaries, and designs that need security scenarios before implementation.
A good finding names the asset, boundary, actor, threat scenario, existing mitigation, evidence state, impact, owner, close condition, and isolated validation method.
What it does not do
The Threat Modeling Skill can organize material, evidence, and next actions for assets and trust boundaries. It does not replace:
- Confirmation of rules, scope, and risk by the accountable domain owner.
- A real environment, account, dataset, log, or run record; static analysis does not become runtime evidence by itself.
- Authorization for release, compliance, production actions, or residual-risk acceptance.
- A Human decision when supplied sources conflict.
What it checks
The value of this Skill is not another keyword list. It connects each focus area to an observable input, a judgment, and a way to close the loop. Start with a small matrix based on the source Skill’s output contract:
| Focus | Question before analysis | Handoff output |
|---|---|---|
| Asset / trust boundary | What is protected and where trust changes | Source and applicability |
| Threat scenario | Actor, path, precondition, impact, and mitigation | Evidence state |
| Assumption gap | What the model relies on but does not prove | Owner question |
| Validation action | Safe check for the highest-risk scenario | Isolation and stop condition |
If a row has only a conventional expectation and no source or validation method, keep it open instead of turning it into a pass.
Audit inputs before you start
Before modeling assets and trust boundaries, classify the input into six evidence states. A gap is not automatically a failure, but it must not disappear inside the conclusion.
| State | Meaning | How this Skill should handle it |
|---|---|---|
| known | Directly supported by the supplied material | Keep the source, version, and time with the judgment |
| missing | Needed for this pass but not supplied | Name the smallest evidence action and limit the conclusion |
| conflicting | Sources disagree | Show both sources and route the conflict to an owner |
| stale | Present but outside the relevant version or time window | Mark freshness; old evidence is not current proof |
| out_of_scope | Related but excluded from this pass | Keep the boundary explicit |
| assumptions | Temporarily adopted to continue analysis | State how and when the assumption will be checked |
Keep the input version, scope, environment, evidence locations, and accountable owner together. Without a run record, deliver analysis, design, or a validation plan—not an execution pass.
From problem to structured Finding
Connect the source, scope, evidence state, analysis, owner, action, close condition, and validation before writing the conclusion. The case below keeps this Skill’s identifier and domain context.
Keep the decision layers separate
For each asset or trust boundary, keep facts, evidence-backed inferences, recommendations, and Human decisions separate:
| Layer | How to write it | Application here |
|---|---|---|
| Fact | What the supplied material directly shows | Cite the source, version, input, or run record for the focus |
| Evidence-backed Inference | What several facts support together | Show the inference chain and retain uncertainty |
| Recommendation | The smallest next action | Name the evidence, review, execution, or regression path |
| Human Decision | What an accountable person must decide | Leave scope, risk acceptance, resources, and release meaning to the owner |
A complete case
This case follows Input, Analysis, Finding, Decision, and Validation. When material is incomplete, keep missing, conflicting, or assumptions visible instead of turning them into a pass.
Input
| Material | What to provide | What to do when it is missing |
|---|---|---|
| System scope | Components, data flows, actors, roles, integrations, and environments | Keep unsupplied paths open |
| Assets | Customer data, credentials, money, availability, and audit records | Do not assume value |
| Trust boundaries | Tenant, network, service, privilege, storage, and third-party boundaries | Mark boundary evidence |
| Mitigations and assumptions | Controls, dependencies, owners, and safe validation | Separate design from execution |
Use a request like this:
Use the threat-modeling Skill.
Task: Model threats for a multi-tenant invoice export service that sends files to object storage and a customer portal.
Inputs: [data-flow diagram, roles, storage policy, API contract, tenant rules, audit design]
Scope: [export creation, storage, download, deletion]
Constraints: [redacted data, no real credentials or API calls]
Cover assets, trust boundaries, attack surface, threat scenarios, mitigations, assumptions, evidence state, owner, close condition, and safe validation.
Analysis
Use the input, matrix, and evidence state to form the judgment before writing the Finding; keep missing material as a gap.
Finding
Focused example: Model tenant escape in an invoice download flow
The portal receives an export ID from the browser, but the design does not say whether the API verifies the export’s tenant against the session. The Skill should model a cross-tenant access scenario, connect it to the authorization control and audit evidence, and propose a synthetic-tenant validation. It should not perform the access attempt against production.
Record the scenario as a THM-01 threat card. This illustrative entry follows the design gap above; it does not claim that a real vulnerability was found or that validation ran.
| Field | Example record |
|---|---|
| Asset and path | Invoice export file; the browser submits an export ID, the portal API reads the file from object storage |
| Trigger and precondition | An authenticated user from tenant A submits an export ID belonging to tenant B; the applicable access rule must come from a supplied policy |
| Boundary and candidate threat | The portal API to object-storage read path; the design does not say how the API binds the session tenant to the file owner |
| Existing control and evidence | The authorization rule, object ownership field, and server-side audit record were not supplied; whether a control exists is still unknown |
| Impact and state | If ownership is not checked, cross-tenant invoice exposure is a possible impact; this is a missing design-evidence state, not a confirmed vulnerability. Priority remains open until a project risk rubric is supplied |
| Expected result and evidence | If the supplied policy requires tenant isolation, deny the request and retain the server decision and audit record; because the policy is not supplied here, treat this as a provisional expected result to confirm with the owner |
| Owner and close condition | The accountable security or service owner confirms the rule; close when its source, owner, and isolated validation result are reviewable |
| Candidate validation | After the owner confirms the rule, use two synthetic tenants in an isolated environment and retain request scope, server decision, and audit evidence |
| Stop condition | Stop if the check leaves the isolated environment, encounters real tenant data, or exceeds the approved scope; preserve the evidence and escalate to the owner |
If the materials do not show how tenant identity reaches the server, how file ownership is bound, or whether a denied request read or returned the object, record those gaps first. Do not draw assumed components or controls into the data-flow model.
The model organizes supplied security context and assumptions. It cannot prove vulnerability, exploit success, mitigation effectiveness, or release security.
Example finding: turn one problem into a handoff
The field example below shows the recording pattern; it is not an execution result.
If the supplied material does not support a conclusion about an asset or trust boundary, use this finding format. Keep the unknown rule visible; do not treat missing evidence as a failure.
| Field | Example wording |
|---|---|
| Source and scope | Record the requirement, version, environment, and the asset or trust boundary under review |
| Finding | The condition or result for the asset and trust-boundary review is not yet traceable to evidence |
| Evidence state | missing / assumptions; use conflicting when sources disagree |
| Impact and priority | Name the affected user, journey, or delivery decision without inflating severity |
| Owner and Human decision | Ask the product, engineering, security, or test owner to confirm the rule and trade-off |
| Action and close condition | Add the smallest missing evidence; close only when source, judgment, and owner can be reviewed |
| Validation | Name one repeatable check, query, or run and retain the raw artifact |
The point is to let the next person walk from the finding back to the source and run an action that can change the decision.
Decision
The accountable owner confirms the decision question and risk trade-off; the Skill does not make that choice.
Validation
Before closing the finding, run the stated validation and retain the raw artifact. Without an execution record, the status remains unverified.
How a Finding enters the next stage
Handoff output
| Output field | Why it exists | Example status |
|---|---|---|
| Asset / trust boundary | What is protected and where trust changes | Source and applicability |
| Threat scenario | Actor, path, precondition, impact, and mitigation | Evidence state |
| Assumption gap | What the model relies on but does not prove | Owner question |
| Validation action | Safe check for the highest-risk scenario | Isolation and stop condition |
Every conclusion should point to a source, evidence state, and next action. If evidence is missing, use pending, blocked, unassessed, or NOT_SCORED instead of filling the gap with confidence.
Next-stage route
At minimum, hand off the source, evidence state, owner, close condition, and validation action; the next-stage conclusion remains bounded by the evidence state.
How to prepare better input
Provide a current data-flow diagram, assets, actor and role matrix, trust boundaries, versions, integrations, mitigations, owners, and safe validation environment. Redact secrets and personal data.
A useful handoff includes input versions, scope, time window, evidence index, assumptions, Human decision boundary, and the smallest validation action.
Best practices
- Start with high-impact, hard-to-detect, permission-sensitive, or data-sensitive paths.
- Use redacted material and keep candidate validation least-privileged, isolated, and reversible.
- Trace each conclusion to its source and boundary; threat-category names alone do not establish an attack path.
Working with other Skills
- Security Requirement Review: https://inaodeng.com/en/qaskills/security-requirement-review/ — turns protection goals into testable conditions.
- Authorization Testing: https://inaodeng.com/en/qaskills/authorization-testing/ — validates access decisions in an approved environment.
- Secrets-Exposure Review: https://inaodeng.com/en/qaskills/secrets-exposure-review/ — examines credential and log exposure.
Common traps
- Listing STRIDE-like threats without mapping assets, boundaries, or evidence.
- Assuming a control exists because the design uses its name.
- Reading credentials or probing production to make the model feel complete.
Install and invoke
npx skills add https://github.com/naodeng/awesome-qa-skills/tree/main/skills/en --skill threat-modeling
Use the threat-modeling Skill.
Include objective, scope, versions, evidence paths, constraints, and decision boundary.
Audit inputs first, preserve evidence states, and finish with owner, close condition, and validation method.
FAQ
Does a threat model find vulnerabilities?
It identifies scenarios and evidence gaps; vulnerability validation is a separate authorized activity.
What if the data-flow diagram is incomplete?
Produce a bounded model, mark unknown boundaries, and ask for the smallest missing flow or owner decision.
The Skill is most useful when attached to one real project artifact and kept with its source evidence. Start narrow, validate the uncertain part, and expand only when evidence supports it.
References
Source Skill and execution contract
The complete execution contract lives in the Threat Modeling prompt: https://github.com/naodeng/awesome-qa-skills/tree/main/skills/en/testing-types/threat-modeling/prompts/threat-modeling.md. The source directory: https://github.com/naodeng/awesome-qa-skills/tree/main/skills/en/testing-types/threat-modeling may also contain evaluation cases and supporting material.
Static plans, file presence, and dry runs keep their evidence state. They do not become runtime proof, an all-passed claim, or release approval.
Further reading
- Threat Modeling details: https://inaodeng.com/en/qaskills/threat-modeling/
- Awesome QA Skills on GitHub: https://github.com/naodeng/awesome-qa-skills
More Resources
- Personal website: https://inaodeng.com/en/
- AI-generated test detection project: https://github.com/AI-Native-QA-Lab/ai-test-auditor
- DeepSeek QA Workbench: https://github.com/naodeng/dsh-qa
- More AI testing skills: https://inaodeng.com/en/qaskills/
- More testing wiki: https://inaodeng.com/en/wiki/
- More AI Wiki: https://inaodeng.com/en/AIWiki/