Visual RFC.
ALL RFCs / RFC 7662
Read the RFC ↗
RFC 7662 / OAUTH TOKEN INTROSPECTION

Bound cache use and account for revocation

05

Caching can reduce introspection traffic, but the cached state can become stale if a token is revoked before the cache is refreshed.

RFC 7662 · § 4EXAMPLE
3 / 3
Bound cache use and account for revocationThe worked cache example starts at epoch2000000000 with chosen TTL30 seconds and response exp2000000020, giving a20-second upper bound. Revocation at t+10 leaves a possible stale active-true cache window. At t+20 the old entry cannot continue beyond its expiration boundary; the illustrated fresh query returns active false. The requested t+30 reuse path stops before acceptance. No fixed TTL or immediate push-invalidating mechanism is required by this RFC.Caching trades load for current statefetchedAt = 2000000000 · chosen TTL = 30sAt t+20: refresh → active false{"active":false}reuse old active true at t+30?MUST NOT cache beyond expShorter local cache policy can require earlier refresh
03
Do not reuse that cache entry after its exp limit.

At t+20 the example fetches a fresh response and learns active false. Reusing the original active-true result at t+30 would exceed the expiration limit.

Source for this drawing: RFC 7662 · Read RFC section 4 ↗

Protocol participantThreat or exceptionProtocol controlSimplified drawings · precise section references
New to this? Start hereA quick picture + helpful background

A message needs an address.

Think of a packet as a small addressed envelope. Devices pass it onward; transport protocols decide what delivery promises an application gets.

Helpful first, if these ideas are unfamiliar

These pictures are analogies to help you learn. The linked RFC explains the actual rules.

Terms in this drawing
TTL
A chosen cache time-to-live; it cannot override an earlier token expiration.
Liveness
How current the information is when used for a decision.
Related RFCs and changes

“Updates” changes part of an earlier RFC. “Obsoletes” replaces it. This list shows selected related documents.

KEY POINT

A protected resource MAY cache introspection responses. System designers MUST consider the performance/security trade-off of using cached authorization information.

  • A protected resource MAY cache introspection responses. System designers MUST consider the performance/security trade-off of using cached authorization information.
  • A longer cache lifetime reduces requests but can allow stale active information after revocation. Sensitive deployments can disable caching at the cost of more traffic and server load.
  • If exp is present, the response MUST NOT be cached beyond that time. An application’s shorter cache policy can require refreshing earlier; exp is an upper bound, not a recommended TTL.
  • Introspection conveys token state. It does not itself revoke the token or guarantee a push notification invalidates every cached result immediately.
DETAILS

Worked example: fetchedAt2000000000, chosen TTL30 seconds, exp2000000020. The latest permitted cache boundary is min(fetchedAt+TTL, exp), so20 seconds, not30. Revocation after10 seconds creates a possible stale window until refresh or that bound; it is not a recommended10-second exposure. The t+20 refresh shown obtains active false. Local authorization policy still applies even when a cached result says true.

Read the RFC section ↗

All chapters in RFC 7662

Drawing view

Scroll the drawing to see every part. Playback controls stay above it.

RFC 9700 / CHAPTERS

Chapters

For full details, tables, algorithms, and exceptions, read the original RFC.

RFC status and corrections ↗