This post is about how to perform Threat Modelling using the STRIDE model. I'll also highlight some tips with using OWASP Threat Dragon, and some practices I choose to follow.
Threat modelling is a critical part of a secure development lifecycle. We use a model, such as STRIDE, to help us identify, review and mitigate potential threats and vulnerabilities within a software system (or application).
The goal is to identify and mitigate threats early, before they become problems. It is critical that everyone in the team responsible for the software application is involved, as everyone can bring a different perspective. Furthermore, it helps educate all members of the team, as application security is everyone's responsibility.
STRIDE is a threat classification model which was developed by Microsoft.
| Threat | Description |
|---|---|
| Spoofing | Impersonating something or someone else. |
| Tampering | Modifying data or code, in transit or at rest. |
| Repudiation | Denying an action or transaction has taken place. Denying without accountability. |
| Information Disclosure | Exposing data to unauthorised parties. |
| Denial of Service (DoS) | Preventing legitimate people or processes from access a service or resource. |
| Elevation of Privilege | Gaining unauthorised access to resources or functionality. |
Each element within the system can be exposed to different threats in different ways. Furthermore, they could be exposed to multiple 'implementations' of the same threat. For example Denial of Service against a process, could come from a DDos attack or from an internal, malicious actor. Each would be represented as a different threat on that process.
| Threat | Description | Key Question |
|---|---|---|
| Spoofing | Impersonating others or systems. | "Can someone pretend to be someone else?" |
| Tampering | Modifying data or code. | "Can someone alter information?" |
| Repudiation | Denying actions occurred. | "Can someone deny they did something?" |
| Information Disclosure | Exposing sensitive data. | "Can someone see information they shouldn't?" |
| Denial of Service | Blocking legitimate access. | "Can someone prevent the system from working?" |
| Elevation of Privilege | Gaining unauthorised access. | "Can someone do things they're not allowed to?" |
| Element | Applicable Threats | Common Examples |
|---|---|---|
| đ§ Actor | None directly | Customers, other systems. |
| âŠī¸ Data Flow | Tampering, Info Disclosure, DoS | HTTP requests, database queries, API calls. |
| đĻ Process | All STRIDE threats | Web apps, APIs, microservices. |
| đ Store | Tampering, Repudiation, Info Disclosure, DoS | Databases, file systems, browser storage. |
| đ¤ Trust Boundary | Defines the threat context | Network perimeters, different infrastructure. |
| Threat Type | Typical Mitigations |
|---|---|
| Spoofing | MFA, authentication. |
| Tampering | Encryption, input validation. |
| Repudiation | Audit logs, digital signatures. |
| Information Disclosure | Encryption, access controls, limit data stored. |
| Denial of Service | Rate limiting, load balancing, monitoring. |
| Elevation of Privilege | Role-Based Access controls, least privilege, regular reviews. |
Threat Dragon is a free, open-source threat modelling tool developed by OWASP. It enables teams to visually develop the data flows of a system, and document threats and mitigations. It supports STRIDE, which this article focuses on, and other threat models. The output of Threat Dragon is not only visual, but is in JSON, so can be easily added to any source control system.
Threat Dragon is available in two ways:
Simply create a new model and start adding elements - Threat Dragon will suggest applicable STRIDE threats for each component you add.
Threat Dragon is a little temperamental but once you get use to it, it is a great tool.
Here is a small, not very detailed example of a web application, which

| Threat | Risk | Status | Mitigation |
|---|---|---|---|
| Spoofing | A malicious actor is able to gain access as another user of the application. | đĸ Mitigated | Tokens are only stored in secure, httpOnly, SameSite cookies so cannot be accessed by anything else. XSS & CSP is in use too. |
| Tampering | Modifying data or code. | đĸ Mitigated | đ Code reviews, signed commits, and access controls are enforced. No data is stored with the Frontend application. |
| Repudiation | Denying an action or transaction has taken place. Denying without accountability. | đĸ Mitigated | đ Audit logs are maintained with user identifiers. All commits must be signed |
| Information Disclosure | Some, customer information is stored in the browser local storage. | đ´ Open (High) | Avoid using localStorage or sessionStorage. |
| Denial of Service | Preventing legitimate users from accessing a service or resource. | đĸ Mitigated | âī¸ Uses CDN caching and load balancing. |
| Elevation of Privilege | Gaining unauthorised access to resources or functionality. | đĸ Mitigated | đ Authorisation checks are carried out and there is no concept of roles within the application. Control to the infrastructure of the application and code is access controlled following least-privilege. |
| Threat | Risk | Status | Mitigation |
|---|---|---|---|
| Spoofing | A malicious actor is able to gain access as another user of the application. | đ´ Open (High) | CORS is used to limit access to just the Web App domain. However, no authorisation checks are carried out on the requests using the JWT, meaning anyone with a valid JWT can impersonate another customer. |
| Tampering | Modifying data or code. | đĸ Mitigated | đ Signed commits, code reviews, and access controls. No data is stored with the API. |
| Repudiation | Denying an action or transaction has taken place. Denying without accountability. | đĸ Mitigated | đ Log all requests with user ID from the JWT and associated actions. |
| Information Disclosure | A 500 error response shows the stack trace, which exposes the language the API is written in etc. | đ´ Open (Medium) | Return generic or sanitised error responses. |
| Denial of Service | Preventing legitimate people or processes from access a service or resource. | đĸ Mitigated | âī¸ Rate limiting, load balancing, and request timeouts. |
| Elevation of Privilege | Gaining unauthorised access to resources or functionality. | đĸ Mitigated | đ Role-based access control and least privilege enforced at the API code & infrastructure. |
| Threat | Risk | Status | Mitigation |
|---|---|---|---|
| Tampering | Queries or stored data could be manipulated. | đ´ Open (High) | Use parameterised queries, restrict database accounts, and enforce strict schema validation. |
| Repudiation | Denying an action or transaction has taken place. Denying without accountability. | đĸ Mitigated | đ Database logs are maintained. |
| Information Disclosure | Personally identifiable information stored in plain text. | đ´ Open (High) | Encrypt sensitive fields at rest & while in use. Ensure there are strict access controls to the database. |
| Denial of Service | Preventing legitimate people or processes from access a service or resource. | đĸ Mitigated | âī¸ Apply query limits, use indexes, and enable monitoring and alerts. |
| Threat | Status | Key Issue |
|---|---|---|
| Tampering | đĸ Mitigated | TLS encryption. |
| Information Disclosure | đ´ Open (High) | Username is in URL path. |
| Denial of Service | đĸ Mitigated | Rate limiting, API gateway. |
| Threat | Status | Key Issue |
|---|---|---|
| Tampering | đĸ Mitigated | TLS encryption. |
| Information Disclosure | đĸ Mitigated | TLS with no sensitive data in request. |
| Denial of Service | âĒ N/A | Third-party dependency risk. However, if they suffer a DoS, what impact will it have on us? |
| Threat | Status | Key Issue |
|---|---|---|
| Tampering | đ´ Open (Medium) | TLS 1.1 used (insecure) |
| Information Disclosure | đ´ Open (Low) | TLS 1.1 used (insecure) |
| Denial of Service | âĒ N/A | Third-party dependency risk. However, if they suffer a DoS, what impact will it have on us? |
| Threat | Status | Key Issue |
|---|---|---|
| Tampering | đ´ Open (Low) | No SSL on internal connections. |
| Information Disclosure | đ´ Open (Low) | Credentials / queries unencrypted. |
| Denial of Service | đĸ Mitigated | Resource limits & monitoring. |
Threat modelling with STRIDE and Threat Dragon can help teams to methodically analyse software systems, to help them identify vulnerabilities before they become issues.
Threat Dragon may have its quirks, but it is free, accessible and fairly straight-forward to use. The JSON-based output is ideal for source control.
Remember: the goal isn't for bullet-proof security, it is about understanding and documenting the known risks.