LiveActive security incident?Get immediate response
CVE Record

CVE-2021-32701: Possible bypass of token claim validation when OAuth2 Introspection caching is enabled

ORY Oathkeeper is an Identity & Access Proxy (IAP) and Access Control Decision API that authorizes HTTP requests based on sets of Access Rules. When you make a request to an endpoint that requires the scope `foo` using an access token granted with that `foo` scope, introspection will be valid and that token will be cached. The problem comes when a second requests to an endpoint that requires the scope `bar` is made before the cache has expired. Whether the token is granted or not to the `bar` scope, introspection will be valid. A patch will be released with `v0.38.12-beta.1`. Per default, caching is disabled for the `oauth2_introspection` authenticator. When caching is disabled, this vulnerability does not exist. The cache is checked in [`func (a *AuthenticatorOAuth2Introspection) Authenticate(...)`](https://github.com/ory/oathkeeper/blob/6a31df1c3779425e05db1c2a381166b087cb29a4/pipeline/authn/authenticator_oauth2_introspection.go#L152). From [`tokenFromCache()`](https://github.com/ory/oathkeeper/blob/6a31df1c3779425e05db1c2a381166b087cb29a4/pipeline/authn/authenticator_oauth2_introspection.go#L97) it seems that it only validates the token expiration date, but ignores whether the token has or not the proper scopes. The vulnerability was introduced in PR #424. During review, we failed to require appropriate test coverage by the submitter which is the primary reason that the vulnerability passed the review process.

HighCVSS 7.5Not KEV-listedUpdated
Glexia's TakeAutomated analysishigh

Security readout for executives and security teams

Plain-English summary

Some Ory Oathkeeper deployments could let a token accepted for one scope be reused for another protected endpoint while OAuth2 introspection caching is enabled. This can expose protected data without changing the token itself. The issue is limited to affected beta versions and does not exist when this cache is disabled.

Executive priority

Prioritize remediation for internet-facing or shared Oathkeeper gateways protecting sensitive data. Default configurations are less exposed because caching is disabled, but enabled caching creates a direct authorization bypass risk.

Technical view

CVE-2021-32701 is a CWE-863 authorization flaw in Ory Oathkeeper oauth2_introspection caching. Cached introspection checked token expiration but not whether the cached token satisfied the current endpoint's required claims or scopes. A token accepted for scope foo could be treated as valid for scope bar before cache expiry.

Likely exposure

Exposure is likely only for Ory Oathkeeper versions >=v0.38.0-beta.2 and <v0.38.12-beta.1 with oauth2_introspection authenticator caching enabled. Default caching is disabled, which materially reduces default exposure.

Exploitation context

The source bundle does not show KEV listing or active exploitation. Abuse requires the affected Oathkeeper version, OAuth2 introspection caching enabled, and a cached token being evaluated against a different scope requirement before cache expiry.

Researcher notes

The vendor states the flaw was introduced in PR #424 and fixed by the referenced commit. Focus review on AuthenticatorOAuth2Introspection Authenticate and tokenFromCache behavior, especially whether cached introspection results are revalidated against current scope requirements.

Mitigation direction

  • Upgrade Ory Oathkeeper to v0.38.12-beta.1 or a later vendor-fixed release.
  • Disable oauth2_introspection authenticator caching if immediate upgrade is not possible.
  • Review access rules that rely on token scopes or claims for sensitive endpoints.
  • Check Ory advisory and release notes before deploying any workaround or upgrade.
  • Monitor protected routes for unexpected authorization outcomes during the affected period.

Validation and detection

  • Inventory Ory Oathkeeper versions across environments.
  • Confirm whether oauth2_introspection authenticator caching is enabled.
  • Identify routes requiring different scopes behind the same Oathkeeper deployment.
  • Verify affected instances are upgraded or caching is disabled.
  • Review tests for scope-specific authorization decisions with cached introspection responses.
Prepared
Confidence
high
Sources
5

Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.

Potential ATT&CK relevance

Conservative CVE-to-ATT&CK context

These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.

ATT&CK lookup starting points

Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.

cwe · medium confidence lookup

CWE-863: Authorization and privilege behavior lookup

Authorization weaknesses can support privilege escalation and valid-account review, depending on exploit path. Open the exact CWE lookup page first, then review the ATT&CK searches from that MITRE weakness context. This is a Glexia lookup hint, not an official ATT&CK mapping.

Open ATT&CK lookup
description · low confidence lookup

Credential and access behavior lookup

The CVE wording references authentication or credential exposure, so valid-account and credential-access review may help. This is a Glexia inferred lookup path, not an official MITRE, ATT&CK, or CVE Program mapping.

Open ATT&CK lookup
cve · low confidence lookup

CVE-2021-32701 mapping review

Open the CVE-to-ATT&CK bridge for reviewed, inferred, or future official mappings tied to this CVE.

Open ATT&CK lookup
Vulnerability profileCVE Program record
Severity
High
CVSS
7.5 (3.1)
Known Exploited
No
Published

Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N

Official CVE source material

CNA and ADP enrichment extracted from CVE v5

These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.

1CVSS vectors
0Timeline events
0ADP providers
4Source links

CVSS vector scores

1 official score

We collect every scored CVSS vector available in the official CNA and ADP containers. When more than one version is present, the table keeps the source vectors side by side instead of collapsing them into the highest score.

ScoreVersionSeverityVectorExploitImpactSource
7.5CVSS 3.1HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N3.93.6Primary CVE score

Vulnerability scoring details

Base CVSS 3.1 score

7.5High
CVSS 3.1 vector shape for CVE-2021-32701Attack VectorAttack ComplexityPrivileges RequiredUser InteractionScopeConfidentiality ImpactIntegrity ImpactAvailability Impact

Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N

Attack Vector
NetworkAdjacentLocalPhysical
Attack Complexity
LowHigh
Privileges Required
NoneLowHigh
User Interaction
NoneRequired
Scope
ChangedUnchanged
Confidentiality Impact
HighLowNone
Integrity Impact
HighLowNone
Availability Impact
HighLowNone
Affected products

Products and packages named in the record

VendorProductVersion / packageStatus
oryoathkeeper>=v0.38.0-beta.2, < v0.38.12-beta.1Listed
Weakness

CWE details

CWE links open Glexia weakness intelligence pages with official CWE context, developer remediation guidance, and related CVE mappings.

CWE-863 · source CWE mapping

Incorrect Authorization

Incorrect Authorization represents a recurring weakness pattern that can create exploitable paths when design, validation, or implementation controls are missing.