Keycloak-services: keycloak-services: protocol mapper with jsontype=json bypasses token sanitization
Summary
| CVE | CVE-2026-97848 |
|---|---|
| State | PUBLISHED |
| Assigner | redhat |
| Source Priority | CVE Program / NVD first with legacy fallback |
| Published | 2026-11-06 06:16:45 UTC |
| Updated | 2026-11-06 18:18:28 UTC |
| Description | A flaw was found in the token sanitization logic of Keycloak, an open source identity and access management solution. The issue 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. This allows an attacker to inject forged client roles into security tokens, which could lead to unauthorized access to protected resources. |
Risk And Classification
Primary CVSS: v3.1 6.5 MEDIUM from [email protected]
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N
Problem Types: CWE-20 | CWE-20 Improper Input Validation
| Version | Source | Type | Score | Severity | Vector |
|---|---|---|---|---|---|
| 3.1 | [email protected] | Secondary | 6.5 | MEDIUM | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N |
| 3.1 | CNA | CVSS | 6.5 | MEDIUM | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N |
CVSS v3.1 Breakdown
Attack Vector
NetworkAttack Complexity
LowPrivileges Required
LowUser Interaction
NoneScope
UnchangedConfidentiality
NoneIntegrity
HighAvailability
NoneCVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N
Vendor Declared Affected Products
| Source | Vendor | Product | Version | Platforms |
|---|---|---|---|---|
| CNA | Red Hat | Red Hat Build Of Keycloak 26.4 | unaffected 26.4.17-2 * rpm | Not specified |
| CNA | Red Hat | Red Hat Build Of Keycloak 26.4 | unaffected 26.4-29 * rpm | Not specified |
| CNA | Red Hat | Red Hat Build Of Keycloak 26.4 | unaffected 26.4-30 * rpm | Not specified |
| CNA | Red Hat | Red Hat Build Of Keycloak 26.4.17 | Not specified | Not specified |
| CNA | Red Hat | Red Hat Build Of Keycloak 26.4.17 | Not specified | Not specified |
| CNA | Red Hat | Red Hat Build Of Keycloak 26.6 | unaffected 26.6.8-2 * rpm | Not specified |
| CNA | Red Hat | Red Hat Build Of Keycloak 26.6 | unaffected 26.6-24 * rpm | Not specified |
| CNA | Red Hat | Red Hat Build Of Keycloak 26.6 | unaffected 26.6-24 * rpm | Not specified |
| CNA | Red Hat | Red Hat Build Of Keycloak 26.6.8 | Not specified | Not specified |
| CNA | Red Hat | Red Hat Build Of Keycloak 26.6.8 | Not specified | Not specified |
| CNA | Red Hat | Red Hat Single Sign-On 7 | Not specified | Not specified |
References
| Reference | Source | Link | Tags |
|---|---|---|---|
| access.redhat.com/errata/RHSA-2026:95761 | [email protected] | access.redhat.com | |
| bugzilla.redhat.com/show_bug.cgi | [email protected] | bugzilla.redhat.com | |
| access.redhat.com/errata/RHSA-2026:95759 | [email protected] | access.redhat.com | |
| access.redhat.com/errata/RHSA-2026:95760 | [email protected] | access.redhat.com | |
| access.redhat.com/errata/RHSA-2026:95762 | [email protected] | access.redhat.com | |
| access.redhat.com/security/cve/CVE-2026-97848 | [email protected] | access.redhat.com | |
| CVE Program record | CVE.ORG | www.cve.org | canonical |
| NVD vulnerability detail | NVD | nvd.nist.gov | canonical, analysis |
Vendor Comments And Credit
Discovery Credit
CNA: Red Hat would like to thank Katika Mohaseen (GitHub: h1-mrz) for reporting this issue. (en)
Additional Advisory Data
| Source | Time | Event |
|---|---|---|
| CNA | 2026-09-24T13:41:47.000Z | Reported to Red Hat. |
| CNA | 2026-11-05T00:00:00.000Z | Made public. |
Workarounds
CNA: Mitigation for this issue is either not available or the currently available options do not meet the Red Hat Product Security criteria comprising ease of use and deployment, applicability to widespread installation base, or stability.
There are currently no legacy QID mappings associated with this CVE.