~/talk

Authentication in Single Page Applications

Talkat RubyC 2018 · 2018-06-02..06-03· [security]
links:none on file
slides:none on file

Using an Authorization header makes requests “non‑simple” so CORS prevents CSRF, but storing access tokens in JavaScript‑accessible storage lets XSS steal them; using HTTP‑only cookies prevents JS theft but reintroduces CSRF unless mitigated. Recommended patterns include short‑lived access tokens with a refresh token in an HTTP‑only cookie, token rotation plus CORS and synchronizer/encrypted CSRF tokens (Rails uses this), CSP and a separate login subdomain to isolate credentials and reduce real‑world exploitability.

AI-written summary · about

  1. 0:00Start
  2. 3:51User Agent (aka Browser)
  3. 4:58CSRF vs CORS
  4. 6:39More passive Anti-CSRF
  5. 8:02XSS: Targets and Implementations
  6. 20:38Content Security Policy Level 1
  7. 21:04CSP + Authorization Header
  8. 22:21Separate login page
  9. 24:04Separate login/accounts domain
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.