Goal. By the end you can run a lightweight threat model for one feature in an agile team, facilitate a workshop, keep a model alive as the system changes, choose a tool (including threat-model-as-code) and spot the failure modes that sink threat-modelling efforts.
Why it matters#
Threat modelling usually fails for human reasons, not technical ones. The session is too long, the wrong people attend, the model lives in a slide deck nobody opens, and the threats never reach the backlog. A technique you cannot run on a Tuesday afternoon with a real team is a technique you will not use. The Manifesto puts it as valuing doing threat modelling over talking about it.
What you will learn#
Small and often: one feature at a time#
Rather than one giant model, model each change. Give a feature 30 to 60 minutes at design time when it brings a new kind of data, a new third party, a new entry point, a change to sign-in, authorisation or secrets, or a new way of deploying. Put those triggers in your refinement checklist, and when none apply, skip the session and say so. The Manifesto asks for modelling that follows design changes in iterations scoped to manageable portions.
Two ways to start small: Mozilla's Rapid Risk Assessment, which takes about 30 minutes for a service and says plainly that it is not a full threat model, and Shostack's free Fast, Cheap and Good whitepaper. Threats become backlog items with acceptance criteria, or tests.
Running a workshop#
Who (about five to eight people, as a rule of thumb): the developers who built it, a tech lead or architect, a product owner who can judge impact, someone from operations or platform, a tester, and a security person as facilitator or participant.
A 90-minute agenda:
| Minutes | Step |
|---|---|
| 10 | Agree scope and the diagram |
| 10 | Walk one data flow end to end |
| 40 | Find threats (STRIDE per element, or a card game) |
| 20 | Rate and choose responses |
| 10 | Actions, owners and the next review date |
Before: send a first-draft diagram. After: file the tickets within a day and store the model with the code. Keep the diagram on screen, keep a parking lot for side topics, never assign blame, and ask quiet people directly: the Manifesto's Varied Viewpoints pattern is about exactly this.
Templates and living documents#
One page is enough:
# Threat model: <feature> (owner, date, next review)
## Scope and assumptions
## Diagram
## Threats
| ID | Where | STRIDE | Threat | Rating | Response | Ticket |
## Open questionsOWASP says a model typically holds a description of the subject, assumptions, threats, mitigations and a way to validate them. Keep it next to the code, in a format that diffs well (Markdown, Mermaid, JSON, Python). Update it when a feature ships, an incident happens or the architecture changes, add "threat model updated?" to the pull-request template, and link each threat to a ticket.
Tools, as of 26 November 2026#
| Tool | What it is | State |
|---|---|---|
| OWASP Threat Dragon | Free app (web or desktop) for drawing DFDs and listing threats; supports STRIDE, LINDDUN, CIA, DIE and PLOT4ai | OWASP Production project, v2.6.2 (May 2026), Apache-2.0. The web app can store models in GitHub, GitLab or Bitbucket |
| pytm (OWASP) | Python library: describe the system in code, get a DFD, a sequence diagram and a threat report | v1.4.1 (1 November 2026). Needs Python 3.11+, Graphviz, Java and PlantUML; the README targets Linux and macOS |
| Microsoft Threat Modeling Tool | Free Windows desktop app with STRIDE-per-element guidance | Release 7.3.51110.1 (10 November 2025); Windows 10 or later, .NET 4.7.1+, internet for updates. Graphical only |
| Threagile | Open-source toolkit: describe the architecture in a YAML file and risk rules check it | Latest tagged release v0.9.1 (July 2024), MIT licence; the repository was still active in 2026. Pre-1.0 |
| AWS Threat Composer | Free, open-source (Apache-2.0) browser-based tool from AWS Labs for writing structured threat statements; exports JSON, Markdown, DOCX and PDF | v1.0.93 (November 2026) |
Commercial platforms exist too; this roadmap does not cover them.
Threat model as code means the model is a file, reviewed in pull requests, so CI can rebuild the diagram and report. Here is a minimal pytm model, to show the idea (check the pytm README for current options):
from pytm import TM, Actor, Boundary, Dataflow, Datastore, Server
tm = TM("Club sign-up")
tm.description = "Illustrative model for learning"
internet = Boundary("Internet")
hosting = Boundary("Hosting")
visitor = Actor("Visitor")
visitor.inBoundary = internet
web = Server("Web app")
web.inBoundary = hosting
db = Datastore("Sign-up database")
db.inBoundary = hosting
form = Dataflow(visitor, web, "Sign-up form")
form.protocol = "HTTPS"
record = Dataflow(web, db, "Member record")
record.protocol = "SQL"
tm.process()python tm.py --dfd | dot -Tpng -o dfd.png draws the diagram. pytm's --stale_days option even compares the
model's age with the code it describes. Limits: it needs developers to own it, its built-in rules are generic
so expect noise, and a generated report does not answer question four.
Review gates#
A gate is a point where work waits for evidence. Keep it light and tied to triggers. Ask: is there a model for this change, and is it current? Does every high-rated threat have an owner and a ticket? Does each mitigation have a test? Does each accepted risk have an approver and a review date? Use security champions or a rota rather than one bottleneck person, and gate on evidence, not meetings.
Common failure modes#
| Failure | Fix | Manifesto anti-pattern |
|---|---|---|
| One expert does everything | Train the team; rotate facilitators | Hero Threat Modeler |
| The diagram is never finished | Time-box it; draw a second view | Perfect Representation |
| Threats never become tickets | End every session with owners | Admiration for the Problem |
| Only one attacker or one method | Add a second lens | Tendency to Overfocus |
| Generic threats ("attacker steals data") | Name the flow, the actor and the effect | |
| Tool output nobody triages | Rate, then delete what does not apply, with a reason | |
| Modelled once, then forgotten | Triggers, tickets, review dates | |
| No builders, or no decision-maker, in the room | Fix the invitation |
The Manifesto group's Threat Modeling Capabilities document sorts programme-level practices into seven areas, from strategy and education to measurement, if you later need to grow beyond single sessions.
Do this#
- Model one feature (60–90 minutes). Use the 90-minute agenda scaled down, ideally with a friend. Output: one page and at least five tickets.
- Redo it in Threat Dragon (45 minutes). Export the file and keep it in a Git repository of your own.
- Redo it in pytm (90 minutes, needs Python). What did the tool find that you did not? What was noise?
- Write a "does this need a model?" checklist (20 minutes) for an imaginary team.
- Audit an old model (30 minutes). Compare one of your earlier models with the failure table and fix two entries.
Resources#
Free first
- Threat Modeling Capabilities - the Manifesto group's catalogue for building a programme.
- Fast, Cheap and Good - Shostack's whitepaper (PDF) on starting quickly.
- Rapid Risk Assessment - Mozilla's 30-minute service review, with templates.
- OWASP Threat Dragon - source, releases and install options.
- pytm - the library, examples and report templates.
- Microsoft Threat Modeling Tool - overview, and its release notes.
- Threagile and AWS Threat Composer - two more open-source options.
- OWASP Threat Modeling Cheat Sheet - see its section on development teams.
Paid or needs an account
- Threat Modeling: A Practical Guide for Development Teams (paid) - Izar Tarandach and Matthew Coles (O'Reilly, 2020), two Manifesto authors, on modelling inside development teams.
Checkpoint#
You are ready to move on when you can:
Go deeper (optional)#
- Read the "Acting on Threat Models" and "Measurement" capabilities and choose two measures a small team could actually track.
- Add a line about the model to a pull-request template and try it on a real repository.