The Security Mindset a show in 8 chapters
Goal: find every way in, then keep 100 of them all locked 99 days in 100
1 of 8 Your guess
Before we start
A program is instructions a machine runs one at a time. Two programs sharing one machine can step on each other's memory, unless something stops them.
Someone has to make sure a system does only what it should. Which picture is closest to how they do it?
Pick the closest. You find out which fits at the end.
2 of 8 The problem
1967: one machine, two users
A defense contractor in St. Louis owns an IBM mainframe, one big computer that many jobs share. It runs classified work for a fighter jet program.
Until now, everyone who touched a computer was already cleared for whatever was on it. Nothing on the machine had to keep one user from another.
Wanting extra income, the contractor asks the Pentagon to let it sell the machine's spare hours to local businesses. They would connect over remote terminals while the classified job keeps running underneath.
A business that has never seen a classified file would share the same memory and disks. Each wire in is a door: a place something from outside gets in. A stranger at one of those terminals who wants the classified job is an attacker.
The Department of Defense has no answer ready. Its research arm asks Willis Ware, of the think tank RAND, to chair a committee: let both users on the machine, without the classified one leaking to the other.
The committee works about three years. Its report, January 1970, is known since as the Ware report.
Your goal: find every way into a system, then make one with 100 ways in hold all of them at once, 99 days in 100.
3 of 8 The idea
The opposite question
An engineer building the shared machine asks how to let two users on at once. Ware's committee had to ask the opposite question about the same machine: how does the classified one leak to the other?
Same drawing, opposite question. The first lists what the machine should do. The second hunts for what it should never do.
Asked once and forgotten, that second question does little. Written down as a list of every way in, and checked one by one before the system ships, it becomes a habit.
That written, checked list is a threat model. Without one, the first person to find the way in is often the attacker.
This whole show is that one habit, in practice.
9 arrows − 1 that stays inside one zone = 8 doors
4 of 8 Try it
Count the doors
Draw the dashed line between the stranger's terminals and the shared machine. Every door crosses it. That line is the trust boundary, and the full set of doors is the attack surface.
Ware's answer: assume a boundary exists whether or not anyone built one on purpose.
Now the same walk on an ordinary web system. Each dashed zone trusts what is inside it. The front server is the one machine the internet can reach. The app server and the worker do the work, behind it.
Every arrow that leaves its zone crosses a dashed line: that crossing is a door.
How many arrows cross a dashed line?
Next step: walk the arrows one at a time.
Walk every arrow. Does it cross a dashed line?
Press Play to walk the nine arrows.
Why are the browser and the attacker two doors?
They cross the same dashed line, but they are two separate ways in. Each one needs its own lock, so each one counts.
The last door is the one people forget. When a payment goes through, the payment provider calls your front server back with a message saying so. That call back is a webhook.
It looks safe because you chose that provider. It isn't: anyone who can reach that address can send a message shaped the same way.
So the webhook needs the same lock as every other door: check the provider's signature on each message, and turn away anything that fails.
A signature here is a mark on the message that only the real provider can make, and that your server can check.
8 doors found on one system, each with a lock.
5 of 8 The idea
Six ways in
At each door, what could go wrong? Ware's committee had to invent its own list. Two of the ways in, drawn: someone at a door claiming to be a user they aren't, and someone flooding a door with so many requests that real users can't get through.
Today's engineers use a ready-made list of 6, one letter each. The first is the fake identity, spoofing. The fifth is the flood, denial of service.
The other four, in plain words, are in the picture. Together the six letters spell STRIDE, a checklist to walk at every door.
Walk the six letters at every door: 8 doors × 6 letters = 48 questions. Most are a fast "no". The few that aren't are the list of things to fix, worst first.
The webhook gets two: S, someone faking the provider, carrying T, tampered data. The fix is the signature check from the last chapter.
Asked on a whiteboard, each question costs nothing. Found after the system ships, the same gap costs a break-in.
this run: 37 of 100 days fully lockedthe average: 0.99 multiplied by itself 100 times = 0.366, about 37 days in 100 on average
one door, two locks: holds 9,999 times in 10,000, that is 0.99990.9999 multiplied by itself 100 times = 0.990, about 99 days in 100 on averagethis run: 99 of 100 days fully locked
0.99 multiplied by itself 373 times = 2.4%0.9999 multiplied by itself 373 times = 96.3%
6 of 8 The fix
A hundred doors, then two locks
Say each door has a lock that holds 99 times out of 100. A genuinely good rate. Now give a system 100 such doors, each locking on its own.
On how many days in 100 do all 100 doors hold at once?
Next step: run 100 days and count.
Each day, every door's lock holds or misses, 1 miss in 100, decided by a fixed sum on the day and the door, so every run is the same. A red door is open that day.
Press Play to run the days.
Why does one open door spoil the whole day?
The attacker does not need all 100 doors to fail. One open door is enough to get in, so a day counts as locked only when every door held.
Why so few? One door holds 99 times in 100. Two doors both hold 0.99 × 0.99 = 98 times in 100. Every door added multiplies by 0.99 again.
The attacker doesn't need all 100 to fail. Just one.
The fix is not a better single lock. It is a second lock behind the first, failing on its own, so one miss doesn't reach anything. Engineers call this defense in depth.
Both locks now have to miss on the same day: 1% becomes 0.01%.
Same 100 doors, same days, now with two locks each. A door is open only when both of its locks miss.
Press Play to run the days again.
A package is somebody else's code that a program pulls in and runs as you. This site's build pulls in 373 of them: 373 more doors.
At one lock each, they all hold 2.4% of the time. With two, 96.3%. Fewer doors, or more independent locks per door: those are the only two levers.
What changed
- All 373 package doors holding, one lock to two: 2.4% → 96.3%
7 of 8 Your guess
Your picture now
Goal met: 8 doors found on one system, 6 checks walked at each, and 100 doors with two locks each held all at once 99 days in 100, up from 37. Which picture is closest now?
Pick one.
c is the lesson: a threat model walked at every door, and more than one lock on each. a trusts one lock: 100 doors with one good lock each held all at once only 37 days in 100. b waits for someone else to find the door first, and the attacker needs only one.
8 of 8 Keep this
Keep this
Assume a door exists wherever something crosses in. Walk the six checks at every one. Never trust a single lock with everything behind it.
The defender has to hold every door, the attacker needs one. That is why security is designed in before a system ships, not patched on after. The next lesson builds the locks: cryptography.
Read the full lessonComing up You found the doors and put two locks on each. Next, the locks themselves: the five tools that keep a message secret, keep it unchanged and prove who sent it.