01 Your first threat model · Beginner
Draw your system as a data flow diagram
Add the parts of your system, put a trust boundary around what you control, and connect everything with labeled data flows.
In this lesson you will learn
- Which element to use for each part of the system
- Where trust boundaries go, and why they matter
- How to draw and label a data flow
- Which security properties change the threats you get
What the diagram is for
A data flow diagram (DFD) shows what talks to what, and where trust changes. It has four kinds of building block: processes that do work, data stores that keep data, external entities you don't control (people and outside systems), and trust boundaries around what one party controls. The arrows between them are data flows.
Steps
-
Add the parts of the system
The palette on the left holds every element. The four basic shapes are at the top; the groups below them (Standard elements, Containers, AI & ML, Fintech, AWS, Azure and more) hold specific types such as a web client, an application server or a database. Drag each part onto the canvas. Specific types matter: the threat dictionary has threats for each one.
-
Draw a trust boundary around what you control
Drag a Trust Boundary onto the canvas and resize it around the parts your team runs, such as your cloud account. Leave people and third parties outside it.
The finished diagram for the expenses app. The dashed box is the trust boundary. -
Connect the elements with data flows
Select the element the data leaves from. In the properties panel on the right, click Draw connection (or press C), then click the element the data goes to. Click the new arrow to give it a label that says what crosses it, such as Claim (HTTPS).
-
Describe each element and set its security properties
With an element selected, add a one-line description, then set Authentication required, Internet-facing and Privileged (admin). Generate attack trees uses these to pick threats and to suggest scores, so a few seconds here saves time later.
An element's properties. Draw connection is at the bottom.
Changes save as you go. The editor shows Saved after each change. Undo and redo are next to the Save button.
Practice
Try it
Draw your system with at least four elements, one trust boundary and a labeled flow between each pair that exchanges data. Set Authentication required and Internet-facing on the element users reach first.
Open My ForestsQuiz
Check what you learned
Three quick questions. Your answers stay in this browser.