~/talk

Securing Web APIs from JavaScript/SPA Applications

Talkat NDC Oslo 2019 · 2019-06-17..06-21· [security, web-platform]
links:none on file
slides:none on file

Explains concrete patterns: use OpenID Connect + OAuth2 to get an ID token (for UI) and an access token (for APIs), prefer the authorization code flow with PKCE from browsers, and avoid refresh tokens in SPAs today. Demonstrates the oidc-client JavaScript library talking to IdentityServer, storing tokens in sessionStorage, doing silent renew via an iframe (prompt=none) and validating bearer tokens on the API. Covers CSP, CSRF and same-site cookie tradeoffs and how each approach actually prevents specific attacks.

AI-written summary · about

  1. 0:00Start
  2. 2:00Outline
  3. 2:38Styles of JavaScript browser-based apps
  4. 4:25Threats against JavaScript apps
  5. 10:48CSRF mitigation with anti-forgery tokens
  6. 16:11Token based authentication
  7. 18:02Client, token server, and API
  8. 18:36Protocol flows
  9. 21:17Token server endpoints
  10. 21:49Discovery endpoint
  11. 22:22Authorization request
  12. 24:15Authorization response
  13. 27:43Token endpoint exchange
  14. 40:29Validating access tokens at API
  15. 57:59Renewing access tokens
  16. 58:12Summary
~/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.