Genai Applied
Sign in Get my playbook

Track 15 · Security

15.6 JWT & Token Validation

19 topics in 3 parts. Use it as a checklist before an interview, or as a map of what to learn next.

  • CCritical
  • HHigh
  • MMedium
  • NNew 2026

01JWT Structure & Claims8 topics

  • Header, payload, signature; Base64URL is encoding, not encryptionC
  • JWS vs JWE — and why JWE usually signals a design smellM
  • iss, sub, aud, exp, nbf, iat, jti — the question each answersC
  • scp vs roles vs azp/client_id vs tid — reading a token correctlyC
  • amr / auth_time / acr for step-up authentication on destructive operationsH
  • Key users on (iss, sub) — never on sub alone, never on emailC
  • Never put secrets, large mutable state, or anything you'd regret, in a tokenC
  • The staleness trade-off: a signed snapshot validated offlineC

02Validating a JWT — Decoding Is Not Validating8 topics

  • The ten-step ordered algorithm, and why the order mattersC
  • decode() / verify_signature=False is an authentication bypass, not a shortcutC
  • alg:none, and RS256→HS256 algorithm confusion using the public key as the HMAC secretC
  • jku/x5u key confusion — never resolve keys from the tokenH
  • Audience validation as the anti-replay control between servicesC
  • Cross-tenant issuer confusion in a multi-tenant IdPC
  • JWKS caching, kid lookup, and seamless key rotationH
  • Three layers kept separate: authN middleware, authZ dependency, business logicH

03Drills & Architecture Exercise 9.53 topics

  • Why isn't a valid JWT enough?C
  • Why shouldn't secrets be placed in a JWT?C
  • Write the PR review comment for verify_signature=False feeding a tenant queryC

All 53 modules

Practise it

Knowing it is half.
Saying it is the rest.

Run a realistic voice interview with an AI panel in the Interview Room, then read a scored report on every answer.