Threat Modeling

Topics Covered

What Threat Modeling Is For

Four questions

Why design time

What a threat model produces

Who takes part

Scope and size

What it is not

Modeling the System

Data flow diagrams

Trust boundaries

Level of detail

Classifying the data

Assumptions and dependencies

Keeping the model current

Enumerating Threats

STRIDE

STRIDE per element

Attack trees

Abuse cases

Privacy threats

Using known failures

Deciding What to Do

Four responses

Prioritising

Mitigations as tickets

Mitigations as tests

Accepting risk properly

Security requirements

Making It a Practice

When to threat model

Running a session

Templates and tools

Did we do a good job

Measuring the programme

Spreading the skill

Most security failures in shipped software are not exotic. They are design decisions that nobody examined from the point of view of someone trying to misuse the system: an internal endpoint that assumed only trusted callers, a support tool that could issue refunds without approval, a file upload that trusted the file name. Threat modeling is the practice of examining a design for those failures before it is built, while changing it is cheap. This lesson treats it as an engineering method with inputs, outputs and a cadence, not as a ceremony performed for auditors.

Four questions

The most widely used framing reduces threat modeling to four questions. What are we working on? What can go wrong? What are we going to do about it? Did we do a good job? The first produces a model of the system, usually a diagram. The second produces a list of threats. The third produces decisions: mitigations, design changes, accepted risks. The fourth checks the result, both whether the model was good enough and whether the mitigations were actually built. Every technique in this lesson is a way of answering one of these four questions more reliably.

The four questions are deliberately plain. They can be asked by anyone, they do not require a security background to understand, and they map onto ordinary engineering work: draw the design, review it, plan the changes, verify the result. An organisation that adopts them gets a shared vocabulary, so a product manager can ask whether a feature has been through what can go wrong, and an engineer can answer with a link to the threat table rather than a reassurance. The questions also make clear that a threat model is never finished in one sitting. Each answer can be revisited when the design changes or when a later finding shows the earlier answer was incomplete.

Why design time

A design flaw found in a whiteboard discussion costs an hour of conversation and a changed diagram. The same flaw found in code review costs a rewrite of the affected component. Found by a penetration test before launch, it costs a delayed release. Found after launch by a researcher or an attacker, it costs an incident, a fix under pressure, possibly customer notification and lasting reputational damage. Tools such as static analysis and dependency scanning find implementation bugs well, but they cannot find a missing authorization check on a workflow that was never designed to have one. Threat modeling is the activity that targets the class of problems tools cannot see.

The same missing approval step cost one hour to fix in design, two days in review, a week after a pre launch test and three weeks once exploited in production.

The economics are lopsided for another reason. A design flaw is usually not one bug but a missing assumption that many pieces of code rely on. When the refund workflow lacks an approval step, every client that calls it, every report built on it and every operational runbook assumes refunds happen immediately. Adding the step after launch means changing all of them and migrating refunds already in flight. Adding it before any code exists means changing a box on a diagram. This is why the most effective security teams spend their scarcest hours in design reviews rather than in scanning output, which machines can triage well enough on their own.

What a threat model produces

The output of a useful threat model is concrete. It includes a diagram of the system showing components, data flows and trust boundaries. It includes a list of threats, each tied to a part of the diagram. It includes a decision for each threat, with mitigations written as tickets that engineers will build and tests that will prove they work. It records accepted risks with a named owner and a reason. It is short enough that people read it, and it lives next to the design document so it changes when the design changes. A threat model that produces only a slide deck has not finished its job.

A useful test of the output is whether an engineer who joins the team six months later can read it in fifteen minutes and understand which risks the design addresses, which it deliberately accepts and why. If the answer requires finding the people who were in the room, the model did not record enough. If the reader has to wade through thirty pages of generic threats that apply to every web application, it recorded too much of the wrong thing. Specific threats tied to specific parts of this design, with specific decisions, are what make the document worth keeping and worth updating.

Who takes part

Threat modeling works best as a conversation among the people who know the system: the engineers building it, someone who knows how it will be operated, a product owner who understands what users and the business need, and someone with security experience to guide the discussion. The security person is not there to produce the threat model alone, because they do not know the system as well as its builders. Their role is to ask questions the builders would not think to ask and to bring knowledge of how similar systems have failed. Over time, engineers internalise these questions and run the sessions themselves.

Getting the right people in the room is often the hardest logistical part. Operations staff know which components are reachable from where in practice, which is frequently different from the design. Product owners know which users are trusted and which are anonymous, and what business harm each failure would cause, which drives prioritisation later. Support and fraud teams know how the existing system is already abused. Inviting one person from each of these groups for a single ninety minute session costs little and routinely surfaces threats that the engineers alone would not have thought of, especially business logic abuse that leaves no technical trace.

Scope and size

Threat models fail when they try to cover too much. A two day workshop on an entire platform produces a long document that is out of date before it is finished. A ninety minute session on one feature, one new service or one significant change produces a small model that is accurate and acted on. Scoping to a change also means the model is done when the decisions are being made. Organisations that run many small threat models find more design problems than those that run occasional large ones, and the habit spreads because the cost of each session is low.

One two day platform workshop found 11 issues and fixed 4. Fourteen 90 minute feature sessions found 37 and fixed 31 before launch.

Small models also compose. A platform with forty services, each with its own up to date model of a page or two, has a better overall picture than one with a single large model from last year. When a new feature crosses several services, the session can start from the existing diagrams, draw only the new flows and boundaries, and focus its time on what has changed. Over time the collection of models becomes the most accurate map of how data moves through the organisation, often more accurate than architecture diagrams maintained for other purposes, because the threat models are tied to the changes that alter that movement.

What it is not

Threat modeling is not a compliance form, a vulnerability scan or a guarantee. It does not replace secure coding, testing, code review or monitoring, and it will miss things. Its value comes from systematically asking how a design could be misused and making deliberate decisions about the answers, which catches a class of problems that nothing else catches as cheaply. Treating it as one input into a broader set of practices, rather than a gate that certifies a system as secure, keeps expectations realistic and keeps the effort proportional.

A design review with an adversary in mind

Threat modeling answers what are we building, what can go wrong, what will we do about it and did we do a good job. Do it at design time, scoped to one feature or change, with the builders in the room, and finish with tickets, tests and named accepted risks rather than a document nobody reads.

The first question, what are we working on, is answered with a model of the system. The model does not need to be complete or beautiful. It needs to show where data enters, where it goes, where it is stored, who or what touches it, and where the level of trust changes. Most threats appear at exactly those points, so a model that makes them visible does half the work of finding the threats.

Data flow diagrams

The standard notation is the data flow diagram, which has only a few element types. External entities are people or systems outside the team's control, such as users, partners or third party services. Processes are code that the team runs, such as services, functions or jobs. Data stores hold data at rest, such as databases, buckets, queues and caches. Data flows are arrows showing data moving between the others, labelled with what moves and how. The small vocabulary is deliberate: it keeps the diagram focused on data, which is what attackers are after and what security controls protect.

Each flow should be labelled with what moves and how: card token over HTTPS, refund request as JSON, nightly export as a CSV file in a bucket. The label matters because threats depend on it. A flow carrying a signed message has different tampering threats from one carrying plain JSON, and a flow through a queue has different denial of service threats from a synchronous call. Drawing the direction of each flow also matters, because a request and its response often carry very different data. A diagram that shows only a line between two boxes, with no direction or label, hides exactly the information the next step needs.

Trust boundaries

A trust boundary is a line on the diagram where the level of trust changes: between the internet and the application, between the application and its database, between one tenant's data and another's, between a service and a third party API, between a user's browser and the server. Data crossing a boundary must be checked by whatever is on the receiving side, because it came from somewhere less trusted. Drawing boundaries explicitly is often the most valuable part of the exercise, because teams frequently discover that a flow they thought was internal actually crosses from a less trusted zone.

The refund feature had seven data flows. Four crossed a trust boundary, and those four produced most of the threats the team later found.

Common boundaries that teams forget to draw include the one between a server and the browser running its own front end code, which is fully under the user's control; between a service and a managed database that other teams' services also reach; between production and the analytics or data warehouse environment; between the application and the support tools that can read and change its data; and between a build system and the artefacts it produces. Each of these has been the site of serious incidents in real organisations, usually because a component on the trusted side assumed that everything arriving from the other side had already been checked.

Level of detail

A diagram for a single feature usually needs five to fifteen elements. Too few, and the interesting boundaries disappear inside a box labelled backend. Too many, and the session spends its time on drawing rather than thinking. A useful rule is to draw each separately deployed component that handles the feature's data, each data store it touches, each external party, and the boundaries between them. Internal libraries and functions within one process do not need their own boxes. If a part of the diagram turns out to hide important detail, it can be expanded into its own diagram later.

It also helps to draw the people who operate the system, not only the people who use it. Administrators, on call engineers, support agents and contractors with access to consoles are external entities with their own flows into the system, and many incidents begin with one of their accounts. Including them on the diagram, with the tools they use and the data those tools expose, makes insider threats and compromised staff accounts part of the conversation rather than an afterthought. A support tool that can read every customer record is often the single most powerful component in a design, and it is frequently left off the diagram.

Classifying the data

Not all data deserves the same protection. Classifying the data on each flow and in each store, for example as public, internal, confidential and restricted, with restricted covering credentials, payment data, health records and similar, shows where the strongest controls are needed. Labelling flows with the most sensitive data they carry quickly reveals surprises, such as a logging flow that carries full request bodies including tokens, or an analytics export that includes personal data the analytics system was never meant to hold.

Two of seven flows carried restricted data. One was a logging flow nobody had meant to include, which captured partial card details from provider responses.

Classification should follow a scheme the organisation already uses, so that labels mean the same thing across teams and connect to policies about encryption, access and retention. Where no scheme exists, four levels are usually enough, and the definitions should name concrete examples so engineers do not have to guess. The exercise also reveals data the feature does not need. If a refund flow carries the full customer profile because it was convenient, the threat model is the moment to cut it down to the order number and amount, which removes several threats at once and reduces what any later breach could expose.

Assumptions and dependencies

Every design rests on assumptions: that the identity provider authenticates users correctly, that the network between two services is private, that a third party API validates its own inputs, that only administrators can reach an admin endpoint. Writing these down next to the diagram makes them testable. Many serious vulnerabilities are assumptions that turned out to be false, such as an internal endpoint that was also reachable through a misconfigured load balancer. Listing dependencies, including libraries, managed services and other teams' APIs, shows where the feature inherits risk it does not control.

A short assumptions list for the refund feature might read: the identity provider enforces multi factor authentication for support agents; the payments provider signs its callbacks; the orders database is reachable only from the orders and refund services; refund amounts are computed on the server from stored order data. Each line suggests a test. Can a support agent log in without a second factor? Does the service reject an unsigned callback? Can another service connect to the database? Does a client supplied amount ever reach the payment provider? Several of these checks usually fail the first time they are tried, which is precisely why they belong in the model.

Keeping the model current

A model drawn once and never updated becomes misleading. Keeping it next to the design document, in a format that is easy to edit such as diagrams as code or a shared drawing tool, and updating it when the design changes keeps it useful. Some teams treat the diagram as part of the service's documentation, so new team members read it to understand the system and notice when it no longer matches reality. The cheapest moment to update a model is when the change that invalidates it is being designed.

Diagrams as code have an extra benefit: changes to them appear in pull requests, where reviewers can see that a new flow or data store was added and ask whether the threat model needs another look. Some teams add a lightweight check that flags pull requests touching infrastructure definitions, authentication code or data schemas, prompting the author to confirm the diagram is still accurate. This keeps the model alive with almost no extra effort, because the update happens in the same place and at the same moment as the change that requires it.

Draw the boundaries, label the data

Use a data flow diagram with external entities, processes, stores and flows, draw every trust boundary, keep it to five to fifteen elements per feature, label flows and stores with the most sensitive data they carry, write down assumptions and dependencies, and keep the diagram next to the design so it changes with it.

The second question, what can go wrong, is where unstructured threat modeling falls apart. Asking a room what could go wrong produces whatever the most experienced or most anxious person happens to think of. Structured methods walk through the model systematically, so the threats found depend on the design rather than on who attended.

STRIDE

STRIDE names six categories of threat, each the violation of a security property. Spoofing violates authentication: pretending to be another user or system. Tampering violates integrity: modifying data or code. Repudiation violates accountability: denying an action with no way to prove otherwise. Information disclosure violates confidentiality: exposing data to those not entitled to it. Denial of service violates availability: making the system unusable. Elevation of privilege violates authorization: gaining capabilities beyond those granted. Walking through each category for each element of the diagram produces a broad, repeatable list of candidate threats.

The value of STRIDE lies less in the categories themselves than in the discipline of applying all of them. Teams naturally think of the threats they have seen before, which for most web teams means injection and maybe cross site scripting. Asking explicitly about repudiation surfaces missing audit logs. Asking about denial of service surfaces unbounded queries and missing rate limits. Asking about elevation of privilege surfaces admin functions protected only by a hidden button. Each category acts as a prompt that pulls the conversation toward a property the team might otherwise forget, which is why a structured pass reliably finds more than an open discussion of the same length.

STRIDE per element

Not every category applies to every element type. External entities can be spoofed and can repudiate actions. Processes are subject to all six. Data stores can be tampered with, disclosed, denied and, when they hold logs, used to support or undermine repudiation. Data flows can be tampered with, disclosed and denied. Applying only the relevant categories to each element keeps the list manageable. A typical feature diagram produces a few dozen candidate threats, many of which are already handled by existing controls and can be noted quickly, leaving a smaller set that needs real discussion.

Walking STRIDE across the refund feature produced 31 candidate threats. Existing controls covered 22, leaving 9 that needed a decision.

Recording the result as a table keeps the output usable. Each row names the element, the category, a one line description of the threat, the existing control if there is one, and a status: covered, needs decision, or not applicable with a reason. The table makes it easy to see which threats are already handled by platform features such as the load balancer's TLS or the identity provider's authentication, and which are specific to the new feature. It also gives the later review a checklist to verify, and it shows anyone reading the model that each category was considered for each element rather than skipped.

Attack trees

Attack trees work from a goal rather than from the diagram. The root is something an attacker wants, such as issue a refund to an account they control. Its children are the ways to achieve it, such as compromise a support agent account, abuse the customer refund form or tamper with the payments callback, and each of those is broken down further. Annotating leaves with rough cost or difficulty shows the cheapest path to the goal, which is usually where defences are most needed. Trees complement STRIDE well for the handful of goals that would hurt the business most.

Attack trees are particularly good at revealing where defences should be layered. If every path to a goal passes through one node, such as obtaining a valid support agent session, then strengthening that node with phishing resistant authentication protects against many attacks at once. If paths diverge early, several independent controls are needed. Trees also make the cost of a mitigation easier to judge, because removing the cheapest path only helps if the next cheapest is substantially harder. A defence that raises the cost of one branch from trivial to moderate while another branch remains trivial has bought very little.

Abuse cases

Abuse cases are user stories written from the point of view of someone misusing the feature: as a customer, I want to request a refund for an order I never paid for; as a support agent, I want to refund my own account; as a competitor, I want to enumerate which email addresses have accounts. They are easy for product owners and engineers to write because they use the same format as normal stories, and they often surface business logic abuse that technical categories miss, such as promotions that can be stacked or limits that reset when an account is recreated.

Of three paths to a fraudulent refund, the cheapest ran through the support tool, where any agent could refund any order with no second approval.

Abuse cases also involve the people who will have to deal with abuse later. Fraud analysts, trust and safety staff and customer support can usually list half a dozen ways the previous version of a feature was gamed within minutes of being asked. Writing those down as stories and adding acceptance criteria, such as a second refund request for the same order within a day is held for review, turns institutional memory into requirements. It also helps product owners see security as part of the product working correctly, rather than as an obstacle the security team places in front of launches.

Privacy threats

Security threat categories do not cover every way a system can harm the people whose data it holds. Privacy focused methods such as LINDDUN add categories such as linkability, identifiability, detectability, unawareness and non compliance, which capture harms like combining datasets to identify individuals, collecting more than users expect, or keeping data longer than allowed. For features that process personal data, adding a short privacy pass to the threat model catches problems that would otherwise surface in a regulator's inquiry or a news story.

Privacy threats deserve attention even where no regulation applies, because they are a common source of user distrust and press coverage. Typical examples are identifiers that let records from different systems be joined into a fuller profile than either holds, logs and analytics that keep precise location or behaviour long after it is needed, features that reveal whether a person has an account or what they did, and data collected for one purpose and later reused for another. A short set of privacy questions asked of each flow, what is collected, who can see it, how long it is kept and can it be linked, catches most of these.

Using known failures

Teams do not have to invent threats from first principles. Lists of common weaknesses, such as the OWASP Top Ten for web applications and the CWE catalogue, past incidents in the organisation, findings from previous penetration tests and bug bounty reports for similar features all suggest threats worth checking. A short checklist of threats that recur in a particular organisation, such as missing tenant checks or secrets in logs, added to every session, catches the repeat mistakes that the organisation is most prone to making.

A practical caution applies to all of these methods: the aim is a list of threats specific enough to act on, not an exhaustive catalogue. A threat written as data could be stolen is useless because it suggests no mitigation. A threat written as a support agent could export every customer's order history through the bulk export endpoint, which has no filter by assigned customers, suggests exactly what to fix and how to test it. Facilitators should push vague threats toward that level of precision, and drop candidates that cannot be made precise because they do not really apply to this design.

Let the method find threats, not the loudest voice

Walk STRIDE across each element of the diagram, using only the categories that apply, build attack trees for the goals that would hurt most, write abuse cases with the product owner, add a privacy pass for personal data, and keep a short list of the organisation's repeat mistakes to check every time.

A list of threats is not yet useful. The third question, what are we going to do about it, turns the list into decisions that someone will act on. The decisions should be explicit, because an unrecorded decision to do nothing is indistinguishable from an oversight, and they should be connected to the normal engineering workflow so that they get built.

Four responses

Each threat gets one of four responses. Mitigate means add a control that reduces likelihood or impact, such as an authorization check, input validation, rate limiting or encryption. Eliminate means change the design so the threat no longer applies, such as not storing a piece of data at all or removing a feature that was not needed. Transfer means move the risk to another party, such as using a payment provider so card data never touches the system, or buying insurance. Accept means acknowledge the risk and proceed without further action, with a reason and an owner. Elimination is often the strongest response and the most overlooked.

Teams often reach for mitigation by default because it fits the habit of adding code. Elimination deserves to be asked first, because a threat that no longer applies needs no ongoing maintenance, no tests and no monitoring. Not storing a field, not exposing an endpoint publicly, not supporting a rarely used input format or not granting a permission removes whole sets of threats at once. Transfer is also underused: a payment provider, an identity provider or a managed file scanning service often carries a risk better than the team can, and the decision to use one is a security decision as much as a build or buy decision.

Prioritising

Not every threat deserves the same urgency. A simple rating of likelihood and impact, each on a small scale, is usually enough to order the list, and the risk and triage lesson covers more rigorous approaches. Threats against restricted data, threats reachable from the internet without authentication, and threats with a cheap path in an attack tree go to the top. Threats that require an already privileged insider, or that affect only low value data, can often wait or be accepted. The goal is a short list of things that must be done before launch and a longer list of things that should be done eventually.

Of 9 threats, 5 were mitigated, 1 eliminated by not storing provider responses, 1 transferred to the payment provider and 2 accepted with named owners.

Ordering threats also requires honesty about existing controls. A threat marked as covered because the load balancer requires authentication is only covered if every path to the service goes through that load balancer, which should be checked rather than assumed. Equally, a control that exists but is known to be weak, such as an IP allow list on a range shared with many other tenants, should not be counted as full coverage. The discussion about priority is often where the team discovers that a control it had relied on for years does not actually do what everyone believed.

Mitigations as tickets

A mitigation that is only written in a threat model document rarely gets built. Writing each one as a ticket in the team's normal backlog, linked back to the threat it addresses, puts it in the same flow as feature work. The ticket should state the requirement precisely, such as refunds above 200 dollars require approval from a second agent who is not the requester, rather than vaguely, such as improve refund security. Marking which tickets block launch makes the trade off visible to the people planning the release.

Tickets should also say which threat they address, so that when one is deprioritised later the consequence is visible. A planning discussion that drops a ticket titled add tenant filter to export, mitigates cross tenant disclosure rated high, is a different conversation from one that drops a ticket titled export improvements. Linking in both directions, from threat to ticket and ticket to threat, also lets the security team see at any moment which threats in which services are still open, which is the basis for reporting risk accurately to leadership without asking every team to fill in a spreadsheet.

Mitigations as tests

Each mitigation should come with a test that fails if the control is missing or broken. An authorization check gets a test that calls the endpoint as the wrong user and expects a refusal. A rate limit gets a test that exceeds it. A redaction rule gets a test that logs a sample token and asserts it does not appear. These tests prevent regressions, which are common because later changes can bypass a control without anyone noticing, and they answer part of the fourth question, did we do a good job, with evidence rather than opinion.

Seven mitigation tickets each carried a test. Six closed cleanly; the approval threshold test caught an off by one bug two days before launch.

Security tests are most valuable when they are written as ordinary tests in the same suite as the feature, run on every change and owned by the same team. Negative tests, which check that the wrong user is refused, the oversized input is rejected and the unsigned message is dropped, are the ones most often missing from normal test suites, because developers naturally test that features work rather than that misuse fails. Making the threat model the source of these negative tests closes that gap systematically, and their presence in the suite is a visible signal that the model was acted on.

Accepting risk properly

Accepting a risk is a legitimate decision, but it needs to be made by someone with the authority to accept the consequences, recorded with the reasoning, and revisited. A risk accepted because the feature has few users may need a different answer when it has many. Recording an expiry date or a trigger for review, such as when monthly refunds exceed a set value, keeps accepted risks from becoming permanent by default. A register of accepted risks across the organisation also shows leaders how much risk they are carrying, which is information they need.

Accepted risks should be written in plain language that a non specialist can follow: what could happen, how likely it is thought to be, how much harm it would cause, why the team is not addressing it now, who decided and when it will be looked at again. Vague acceptances, such as low risk, accepted, give a later reader nothing to reassess. Specific ones, such as an agent could refund up to 50 dollars to their own account without detection for about a week until the weekly audit catches it, accepted by the support director until monthly refunds exceed 20 thousand dollars, can be revisited intelligently.

Security requirements

Some decisions are better expressed as requirements for the design than as individual mitigations. All refund actions must be logged with the actor, amount and order. All data from the payment provider must be verified with a signature before it is trusted. No restricted data may be written to logs. These requirements apply to future changes as well as the current one, and they can be checked in code review and by automated tests. Accumulating such requirements per service builds a security specification that grows with the system.

Security requirements are most useful when they are few, specific and checkable. A list of fifty generic statements copied from a standard tends to be ignored, while five sentences that capture what is distinctive about this service's risks get read and enforced. Good requirements name the data or action they protect, state the control in terms that a reviewer can verify, and avoid prescribing an implementation where several would work. Reviewing the list when the service changes, removing requirements that no longer apply and adding ones that recent threat models produced, keeps it a living part of the service's design.

Every threat gets a decision and an owner

Respond to each threat by mitigating, eliminating, transferring or accepting it, prioritise by likelihood and impact, write mitigations as precise tickets with tests that fail if the control is missing, record accepted risks with an owner, a reason and a review trigger, and capture lasting rules as security requirements.

A single threat model helps one feature. A habit of threat modeling changes how an organisation designs systems. Getting there is mostly about making the practice cheap, predictable and useful to the teams doing it, and about closing the loop with the fourth question so that the method improves over time.

When to threat model

Clear triggers decide when a change needs a session. Common ones are a new service or external interface, a new data store holding confidential or restricted data, changes to authentication or authorization, a new third party integration, a new trust boundary such as a partner or tenant model, and features that move money or change permissions. Including these triggers in the design document template means teams decide early, and changes that match none of them proceed without ceremony. Most changes match none, which keeps the overhead in proportion.

Triggers also need an escape for judgement. An engineer who feels uneasy about a change that matches no trigger should be able to ask for a session without justifying it, and a reviewer should be able to request one when a pull request reveals that a change is larger than its description suggested. Conversely, a team that has already modelled a service thoroughly may need only a short update when a trigger fires for a small extension. Treating triggers as defaults rather than rigid rules keeps the practice proportionate without letting important changes slip through because they were described modestly.

Running a session

A good session has a prepared diagram, a facilitator, a timebox and a note taker. The first ten minutes confirm the diagram and boundaries with everyone present. The next forty walk through threats with STRIDE per element or attack trees for the main goals. The last half hour decides responses, assigns owners and writes tickets. Keeping the discussion on the design rather than on implementation details, and parking deep technical questions for follow up, keeps the session within its time. Ending with the list of tickets read aloud makes commitments clear.

Facilitation is a skill that improves with practice. Good facilitators keep the discussion moving, make sure quieter participants contribute, notice when the group is going deep on one threat while ignoring a whole element, and are comfortable saying that a threat needs a follow up rather than a resolution in the room. They also protect the session from becoming a design review of everything, by steering conversations about performance or code style back to what can go wrong from a security point of view. Rotating the facilitator role among trained engineers builds the skill across teams.

Templates and tools

A one page template with sections for scope, diagram, assumptions, threats, decisions and accepted risks gives every session the same shape and makes models easy to compare and review. Diagrams as code, stored with the service, can be updated in the same pull request as the change. Dedicated threat modeling tools can suggest threats from diagram elements, though a shared document and a drawing tool are enough for most teams. The tool matters far less than the habit of using it consistently.

Whatever the format, the model should be easy to find. Linking it from the service's main documentation, the design document and the repository readme means engineers encounter it when they need it. Storing models in one searchable place also makes it possible to look across them, for instance to find every service that handles restricted data or every accepted risk that depends on a particular vendor. These cross cutting questions come up during incidents, audits and vendor changes, and answering them from existing models is much faster than surveying every team from scratch.

Did we do a good job

The fourth question closes the loop. Shortly after launch, a brief review checks that every launch blocking ticket was completed and its tests pass. Over a longer period, security findings from penetration tests, bug bounty reports and incidents are traced back: was the threat in the model, and if so, why was the mitigation insufficient; if not, what in the method would have found it. These answers improve the triggers, the template and the organisation's checklist of repeat mistakes, so each round of threat models is better than the last.

The review after launch should be short and blameless. Its aim is to learn, not to grade the team. A missed threat is useful information: perhaps the diagram omitted a component, perhaps a category was rushed, perhaps the organisation's checklist lacked an entry for a kind of mistake it keeps making. Recording the lesson in the template or checklist means every future session benefits. Teams that treat findings after launch as evidence that threat modeling failed tend to abandon the practice, while teams that treat them as inputs steadily improve it.

Measuring the programme

A few measures show whether threat modeling is working. The number of sessions held and the share of qualifying changes that had one show coverage. The number of design issues found and fixed before launch shows value. The share of serious findings from later stages, such as penetration tests and incidents, that were design flaws missed by a model shows gaps. A rising share of findings caught at design time, and a falling number of serious design flaws found later, is the clearest sign the practice is paying for itself.

Over four quarters, design time findings rose from 20 to 55 percent of all security issues, and high severity pen test findings fell from 12 to 4.

Measures should be chosen to encourage the right behaviour. Counting threats found per session rewards long lists of generic threats. Counting sessions held rewards box ticking on trivial changes. Measures tied to outcomes, such as the share of serious later findings that were design flaws missed by models, or the share of qualifying changes that launched with every blocking mitigation tested, reward the behaviour that actually reduces risk. Reporting them alongside a few concrete stories of problems caught early keeps leadership support, which the practice needs because its successes are, by nature, incidents that did not happen.

Comparing measures across teams should be done carefully. A team building a public payments API will rightly hold more sessions and find more threats than a team maintaining an internal reporting dashboard, and neither number says which team is doing better. Comparing each team against its own trend, and looking at coverage of qualifying changes rather than raw counts, gives a fairer picture. Where one team's coverage drops sharply, the right response is usually a conversation about workload or tooling, since a drop rarely means the team has stopped caring about security.

Spreading the skill

Security teams are small relative to engineering, so threat modeling scales only when engineers lead it. Pairing a security engineer with a team for its first few sessions, then having the team lead with security reviewing the output, and eventually running independently with occasional review, spreads the skill. Security champions, engineers in each team with extra training and time for security work, often become the facilitators. Sharing good examples of models, especially ones that caught real problems, gives other teams a pattern to follow.

Champions need support to stay effective. A small amount of protected time each sprint, access to security engineers for difficult questions, a regular meeting where champions share recent models and findings, and recognition in performance reviews for the work all help. Without these, the role becomes an unpaid extra that the busiest engineers quietly drop. With them, champions become the main channel through which security knowledge spreads, and they bring the security team early warning of designs that need deeper attention, long before those designs reach code review or launch.

What this looks like at each level

Junior:** takes part in sessions, reads the model for their service and builds mitigations with their tests.

Mid-level:** draws accurate diagrams with trust boundaries and applies STRIDE per element to their own features.

Senior:** facilitates sessions, decides responses with product owners and writes security requirements for their services.

Staff:** sets triggers and templates across the organisation, measures the programme and feeds later findings back into the method.