Index

Free, with Google

Keep going, free.

A free account opens lessons 2 and 3 of every track, 33 more lessons, and keeps your progress and review cards on every device.

Start free with Google

A chalk plan

Open everything on chalk.

Every lesson, board, video, lab and paper, and the full review decks. Yearly is $39/year.

See plansStart free instead

Module 01 · Security · Think Like an Attacker · about 17 min to read

Play it as a journeyTutor comes with a plan

Break and fix: the security capstone

The Security Mindset
The Security Mindset · Open board

An ordinary system with every door an attacker could use marked on it. This lesson gives you a small shop with five of those doors open. You walk through each one, then close it.

Before you start. The Security Mindset gave you the door: every place where something from a stranger reaches your system. Authentication gave you the salted slow hash, a way to store a password so a stolen copy is hard to use. Authorization & Identity gave you the ownership check, which asks whether the thing requested belongs to the person asking. Web Vulnerabilities (the OWASP classics) gave you the rule that typed text must be read as a value and never obeyed as an order. The shop you secure (defence in a real app) built a shop with the locks already on, and Review the fix (secure code review) had you find a missing lock by reading code. Here you start with no locks and add them yourself. You need Python 3.

Lesson 39 of 39 in Security

The rest of this lesson is part of a plan.

A plan opens every lesson, board, video, lab and paper on chalk. Yearly is $39/year.

See plansAlready a member? Sign in

Or start free: a free account opens lessons 2 and 3 of every track.

In this lesson

  • October 2015: three web pages nobody was watching
  • The shop: a Python file with five doors left open
  • Flaw 1, SQL injection: the login that obeys the name
  • Flaw 2, weak password storage: bob’s password cracked in one step
  • Flaw 3, a missing ownership check: alice reads bob’s order
  • Flaw 4, cross-site scripting: a review that runs
  • Flaw 5, a guessable token: logging in as admin without a password
  • What the five fixes have in common
  • How the five patches change one request
  • Edge cases the patches do not cover
  • Reviewing a shop you did not write

Terms it explains: token, exploit, patch, bound parameter, hash, salt, slow hash, broken access control, cross-site scripting, Common mistakes, assume breach, attack surface, authenticity, CIA triad, complete mediation, defense in depth, fail secure, least privilege, no security through obscurity (Kerckhoffs), non-repudiation, security mindset, stride, threat model, trust boundary.

Related paper

Review Security