-
We’re Here to Help!
Most security problems are cheaper to prevent than to fix. Threat modelling helps you find design weaknesses before code is written or before a new feature goes live, by asking a simple question in a structured way: what could go wrong? STRIDE is one of the most practical frameworks for answering it, and it works for web apps, APIs, mobile apps and cloud systems alike.
This guide explains threat modelling with STRIDE, walks through a simple example and shows how to turn the results into concrete security improvements.
Threat modelling is a structured way to identify, prioritise and address threats to a system. According to the OWASP threat modelling guidance, it typically answers four questions:
Unlike penetration testing, which tests a running system, threat modelling works on the design. The two complement each other: threat modelling shapes what you build, and testing proves whether it holds up.
STRIDE, originally developed at Microsoft, groups threats into six categories. Each one maps to a security property it violates:
| Threat | Violates | Example |
|---|---|---|
| Spoofing | Authentication | An attacker logs in as another user with stolen credentials |
| Tampering | Integrity | A user modifies a price or account ID in an API request |
| Repudiation | Non-repudiation | A user denies making a transaction and there are no reliable logs |
| Information disclosure | Confidentiality | An API returns other customers’ personal data |
| Denial of service | Availability | An expensive search endpoint is flooded until the service fails |
| Elevation of privilege | Authorisation | A normal user gains admin rights through a missing check |
Draw a data flow diagram showing users, external systems, processes, data stores and the data flows between them. Mark trust boundaries, such as the line between the internet and your API, or between your application and a third-party payment provider.
Go through each component and data flow and ask which STRIDE categories apply. Data flows crossing trust boundaries usually deserve the closest attention.
Estimate the likelihood and impact of each threat. A simple high, medium and low rating is often enough to focus effort on what matters.
For each important threat, choose a response: mitigate it with a control, eliminate it by changing the design, transfer it, or formally accept it.
Confirm that mitigations were implemented and work. Security testing, code review and penetration testing provide that evidence.
| Element | STRIDE threat | Mitigation |
|---|---|---|
| Login page | Spoofing through credential stuffing | MFA, rate limiting, breached password checks |
| Checkout API | Tampering with price or quantity | Server-side price calculation and validation |
| Order history | Information disclosure via changed order IDs | Object-level authorisation checks on every request |
| Payment callback | Spoofing of payment confirmation | Verify signatures from the payment provider |
| Admin panel | Elevation of privilege | Role-based access control, separate admin authentication |
| Audit trail | Repudiation of refunds | Tamper-resistant logging of key actions |
Many of these threats appear in the OWASP API Security Top 10, which is why threat modelling and API testing work well together.
You can see how threat modelling applies in a specific industry in our article on threat modelling in the financial sector.
Ideally during design, before code is written, when changes are cheapest. It should then be revisited whenever the architecture changes significantly, for example when adding a new integration, payment flow, data store or deployment model.
A small group that understands the system: an architect or lead developer, someone who knows the business process, and a security specialist. Product owners and operations staff add valuable context about how the system is really used and run.
No. Other approaches include PASTA, attack trees, LINDDUN for privacy and the OWASP threat modelling process. STRIDE is popular because it is simple, systematic and easy for development teams to learn, which makes it a good starting point.
Threat modelling with STRIDE gives development and security teams a shared, structured way to find design flaws early. By modelling your system, applying the six STRIDE categories, prioritising risks and validating mitigations through testing, you can build security in rather than bolt it on later.
Want expert help modelling a new product or architecture? Learn about our threat and risk analysis service or contact the Offensium Vault team. You can also explore all our cybersecurity services.
Free 30-minute consultation
Talk to our ISO 27001 certified team about penetration testing, cloud security or compliance. No obligation, and we are happy to sign an NDA.