CVE-2026-9704 Details
Description
A flaw was found in Keycloak. An authenticated user with low privileges can exploit this vulnerability by sending an oversized subject_token JSON Web Token (JWT) to the TokenEndpoint. When the token exceeds a 4000-character limit, it is silently dropped, causing the system to fall back to client credentials. This allows the user to gain the permissions of the client's service account, leading to privilege escalation.
A vulnerability in Keycloak allows an authenticated user with low privileges to escalate rights by sending an oversized subject_token JSON Web Token (JWT) to the TokenEndpoint. Tokens exceeding 4000 characters are silently discarded, causing the system to revert to client credentials. This switch grants the user access to the permissions of the client's service account, facilitating unauthorized privilege escalation.
To address this vulnerability, configure Keycloak to enforce strict parameter validation by setting the 'fail-fast' parameter to 'true' for the 'TokenEndpoint' configuration. This adjustment will ensure that requests with oversized parameters are explicitly rejected instead of being silently processed with diminished privileges. Refer to the Keycloak documentation for guidance on modifying these settings, and note that a restart of the Keycloak service may be required for the changes to take effect.
Metrics
CVSS 4.0 Severity and Vector Strings:
No CVSS 4.0 data is available for this CVE.
CVSS 3.x Severity and Vector Strings:
No data available for CVSS Version 2.0 on this CVE.
CISA-ADP
Assessed May 27, 2026References to Advisories, Solutions, and Tools
By selecting these links, you will be leaving this site. These are references gathered from the official CVE record and are not endorsed by Volerion.
Weakness Enumeration
| CWE-ID | CWE Name | Source |
|---|---|---|
| CWE-1284 | Improper Validation of Specified Quantity in Input | [email protected] |
Affected Products
| Product | Versions |
|---|---|
| redhat build of keycloak | All versions |
CPE
Remediation
| |
Change History
9 change records found show changes
| Date | Action | Recorded By |
|---|---|---|
| Jun 26, 2026 | CVE Modified | [email protected] |
| Jun 26, 2026 | CVE Modified | [email protected] |
| Jun 25, 2026 | CVE Modified | [email protected] |
| Jun 17, 2026 | CVE Modified | [email protected] |
| Jun 17, 2026 | CVE Modified | CISA-ADP |
| Jun 10, 2026 | CVE Modified | [email protected] |
| Jun 10, 2026 | CVE Modified | [email protected] |
| Jun 3, 2026 | Initial Analysis | [email protected] |
| May 27, 2026 | New CVE Received | [email protected] |