Skip to content

ADR-0003. Stateless JWT — no revocation list, short TTL + refresh

FieldValue
StatusAccepted
Date2026-02-10
Decidersidentity-team
Supersedes

Context

  • JWTs are signed claims; once issued, they're valid until expiry — there's no way to instantly invalidate them without state.
  • Adding a revocation list (blocklist) means every sister service must check it on every request — defeats the point of stateless verification.
  • POS workflows need responsive logout / lockout (admin disables a user → they should be cut off quickly).

Decision

JWTs are stateless — no revocation list. We accept the trade-off:

  • TTL is short (default 1 hour) — bounded blast radius.
  • Refresh tokens are rotated on use — long-lived sessions still get fresh tokens.
  • Lockout / disable updates User.status immediately, but token holders retain access until natural expiry. Critical lockouts (security incidents) require key rotation.

Consequences

ProsCons
Sister services verify locally without any shared stateDisabled users keep access for up to TTL
No central blocklist to consultCritical lockout requires JWKS key rotation (force-logs-out everyone)
Horizontal scale is trivial"Logout other sessions" is best-effort UX (token in browser still valid)

Mitigation patterns

  • Sensitive operations (password change, role downgrade) re-fetch user state and re-evaluate authorization server-side
  • Short TTL (1h) + refresh on activity = 1h max stale window
  • For incidents: rotate JWKS keypair → all tokens become invalid

Alternatives Considered

OptionProsConsWhy rejected
Redis-backed token blocklistInstant revocationSister services need to check Redis on every request — defeats stateless verificationWrong layer
Reference tokens (opaque, server-stored)Instant revocationEvery request → identity HTTP call; latency disasterWrong tradeoff
Very-short TTL (5min)Smaller stale windowExcessive refresh churnPerf cost

References

  • JWKSIssuerTokenService (TTL configuration)
  • AuthenticationService.refreshToken

Proprietary and Confidential. Unauthorized copying, distribution, or use of this software is strictly prohibited.