Bug 2565599 (CVE-2026-120984)

Summary: CVE-2026-120984 keycloak-services: keycloak-services: manage-clients to arbitrary code execution through inline JavaScript policy import
Product: [Other] Security Response Reporter: OSIDB Bzimport <bzimport>
Component: vulnerabilityAssignee: Product Security <prodsec-ir-bot>
Status: NEW --- QA Contact:
Severity: high Docs Contact:
Priority: high    
Version: unspecifiedCC: aschwart, aszczucz, boliveir, drichtar, mposolda, pjindal, rmartinc, security-response-team, ssilvert, sthorger, vmuzikar
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: ---
Doc Text:
A flaw was found in the Keycloak server's client management component. When a client is created or imported with authorization services enabled, the system fails to properly clear an internal session attribute used during the setup process. This allows an authenticated attacker with client management permissions to bypass security controls and upload a malicious JavaScript policy, which is then executed on the server when an authorization request is made. Successful exploitation could allow the attacker to run arbitrary code on the server, potentially compromising the entire system.
Story Points: ---
Clone Of: Environment:
Last Closed: Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Deadline: 2027-01-28   

Description OSIDB Bzimport 2026-11-03 05:21:53 UTC
A flaw was found in Keycloak where an authenticated attacker with delegated client management permissions (manage-clients) can achieve arbitrary code execution. When a client is created with authorization services enabled and an authorizationSettings payload is provided in the same request, Keycloak sets an internal session attribute to allow the creation of a default policy but fails to clear it. This mechanism can be abused to supply an inline JavaScript policy during client import, bypassing the security control that normally disables script uploads. When the policy is subsequently evaluated during a User-Managed Access (UMA) authorization request, the injected JavaScript executes within the Keycloak server JVM process. This allows an attacker to escape the delegated administrator's realm boundary and perform actions such as reading sensitive host data, modifying configurations for other realms, or causing a complete system shutdown.