All quizzes
Free quiz · 20 questions in the bank

JWT quiz

Test your JWT knowledge with a free interactive quiz — 20 questions with answers and explanations. No signup needed to play.

Question 1/5Score 0

What is the main architectural benefit of JWTs for authenticating stateless/distributed APIs, versus traditional server-side sessions?

Questions in this quiz
  1. What is the main architectural benefit of JWTs for authenticating stateless/distributed APIs, versus traditional server-side sessions?
  2. Why is putting a long-lived, highly-privileged JWT (e.g. one lasting 30 days) directly in client-side storage generally considered riskier than a short-lived one?
  3. What are the three parts of a JWT?
  4. What does "audience" (`aud`) and "issuer" (`iss`) claims let a verifier check?
  5. What is the `exp` claim used for?
  6. How is a JWT typically sent in an HTTP request to authenticate the caller?
  7. What is a key challenge with revoking a JWT before its natural expiration (e.g. on logout or a compromised account)?
  8. Where should a JWT be stored client-side in a browser-based web app, and what is the security trade-off?
  9. What is a JWT (JSON Web Token)?
  10. What is a "refresh token", and how does it typically differ from an "access token"?
  11. Why is it important to explicitly verify the `alg` field before trusting a JWT, rather than blindly using whatever algorithm the token itself claims?
  12. What is the difference between the `HS256` and `RS256` signing algorithms?
Gaps to close?
Read the curated JWT notes — core concepts, patterns, interview prep.
JWT notes

More quizzes

.NET.NET MAUIAbsintheAccessibilityActixActix Web