PatchSiren

PatchSiren cyber security CVE debrief

CVE-2026-97848 Red Hat CVE debrief

A flaw in Keycloak's token sanitization logic allows an attacker to inject forged client roles into security tokens when a protocol mapper is configured to emit structured claims using the JSON type. This issue arises because the security check designed to remove unauthorized role mappings fails to recognize Jackson-based JSON objects, potentially leading to unauthorized access to protected resources.

Vendor
Red Hat
Product
Red Hat build of Keycloak 26.4
CVSS
MEDIUM 6.5
CISA KEV
Not listed in stored evidence
Original CVE published
2026-11-06
Original CVE updated
2026-11-09
Advisory published
2026-11-06
Advisory updated
2026-11-09

Who should care

Defenders responsible for Keycloak configurations and security, as well as operators and security teams, should assess exposure and verify token sanitization and role mapping security checks to prevent potential unauthorized access. This includes reviewing and updating Keycloak configurations, monitoring security tokens, and ensuring proper compensating controls are in place.

Why it matters

CVE-2026-97848 is a medium-severity vulnerability in Keycloak's token sanitization logic, allowing an attacker to inject forged client roles into security tokens. Defenders responsible for Keycloak configurations should assess exposure and verify token sanitization and role mapping security checks to prevent potential unauthorized access.

  • Potential unauthorized access to protected resources due to forged client role injection.
  • Need to verify and update Keycloak configurations to ensure proper token sanitization.
  • Requirement to review and restrict protocol mapper configurations.
  • Importance of monitoring security tokens for unauthorized role mappings.

Technical summary

The flaw in Keycloak's token sanitization logic occurs when a protocol mapper is configured to emit structured claims using the JSON type. The security check designed to remove unauthorized role mappings only looks for standard Java maps and fails to recognize Jackson-based JSON objects, allowing an attacker to inject forged client roles into security tokens. This issue arises because the security check is limited to standard Java maps and does not account for Jackson-based JSON objects, potentially leading to unauthorized access to protected resources. Affected product deployments should be verified for exposure and updated to ensure proper token sanitization.

Defensive priority

Defenders should prioritize verifying and updating Keycloak configurations to ensure proper token sanitization and role mapping security checks.

Recommended defensive actions

  • Verify and update Keycloak configurations to ensure proper token sanitization and role mapping security checks.
  • Review and restrict protocol mapper configurations to prevent exploitation.
  • Monitor security tokens for unauthorized role mappings.
  • Confirm whether affected Keycloak deployments exist in managed environments and assign an owner for follow-up.
  • Review the supplied official advisory or CVE record to validate affected scope, severity, and vendor guidance.
  • Plan vendor-supported updates or mitigations through normal change control where exposure is confirmed.
  • Check relevant monitoring, detection, and logs for exposed assets that need extra review.

Evidence notes

The CVE record and NVD entry provide details on the vulnerability in Keycloak's token sanitization logic. Red Hat has provided references to errata and security advisories related to this issue. Defenders should verify token sanitization and role mapping security checks with explicit evidence limits and defensive verification tasks. Evidence from the CVE Program and NVD detail page supports this vulnerability assessment.

Sources and references

Verified primary and authoritative sources

  • CVE-2026-97848 CVE Program record

    Publisher, destination, and source semantics verified

    URL: https://www.cve.org/CVERecord?id=CVE-2026-97848

    CVE Program - Official CVE Program record with source-provided CVE metadata.

  • CVE-2026-97848 NVD vulnerability detail

    Publisher, destination, and source semantics verified

    URL: https://nvd.nist.gov/vuln/detail/CVE-2026-97848

    NIST National Vulnerability Database - Official NIST NVD detail page and source-specific vulnerability assessment.

Supplemental references

Methodology and review provenance

AI-assisted synthesis based on stored public vulnerability evidence. System validation, approval state, and publication status do not by themselves establish human review of this revision. PatchSiren helps prioritize defensive review and does not prove exposure or remediation on any system.