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 · with code: Python · about 17 min to read

Play it as a journeyTutor comes with a plan

Whose page is this? (the browser security model)

Web Vulnerabilities
Web Vulnerabilities · Open board

The places a website reads a stranger’s words. Every defence on its checklist (SameSite, HttpOnly, “check Origin”, a rule saying who may frame the page) is a rule the browser enforces, and this lesson is where those rules come from.

Before you start. Authentication gave you the session: after you log in, the site hands your browser a small pass (a cookie), and the browser shows it on every later request so the site knows it is still you. What a request actually says (HTTP) showed you what a request looks like on the wire, headers and all. This lesson explains why the browser, and not the server, decides which page gets to see what.

Lesson 6 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

  • 18 September 1995: frames and scripts ship in the same beta
  • The origin: scheme, host and port, the page’s return address
  • The same-origin policy: send anywhere, read only your own
  • CORS: the reply that names who may read it
  • Cookies: the keys the courier carries, and three flags
  • October 2008: clickjacking, the button behind the glass

Terms it explains: origin, same-origin policy, CORS, preflight, `Secure`, `HttpOnly`, `SameSite`, clickjacking, and it moved money, cloud metadata endpoint, confused deputy, CSP, CSRF, injection, output encoding, OWASP Top 10, parameterized query / prepared statement, sanitization, SQL injection, SSRF, the universal cure, XSS.

Review Security