Keycloak: keycloak: privilege escalation via improper scope mapping enforcement

Summary

CVECVE-2026-9795
StatePUBLISHED
Assignerredhat
Source PriorityCVE Program / NVD first with legacy fallback
Published2026-05-28 05:16:41 UTC
Updated2026-06-03 19:38:04 UTC
DescriptionA flaw was found in Keycloak's Fine-Grained Admin Permissions (FGAPv2) feature. An administrator with limited client management permissions can exploit this vulnerability to assign any realm role, including highly privileged roles, to a client's scope mapping. This bypasses intended security controls, allowing the injected role to be projected into a user's authentication token when they access the modified client. This could lead to unauthorized privilege escalation within the Keycloak realm.

Risk And Classification

Primary CVSS: v3.1 7.3 HIGH from [email protected]

CVSS:3.1/AV:N/AC:H/PR:H/UI:R/S:C/C:H/I:H/A:N

EPSS: 0.000340000 probability, percentile 0.102540000 (date 2026-06-03)

Problem Types: CWE-266 | CWE-266 Incorrect Privilege Assignment


VersionSourceTypeScoreSeverityVector
3.1[email protected]Secondary7.3HIGHCVSS:3.1/AV:N/AC:H/PR:H/UI:R/S:C/C:H/I:H/A:N
3.1CNACVSS7.3HIGHCVSS:3.1/AV:N/AC:H/PR:H/UI:R/S:C/C:H/I:H/A:N

CVSS v3.1 Breakdown

Attack Vector
Network
Attack Complexity
High
Privileges Required
High
User Interaction
Required
Scope
Changed
Confidentiality
High
Integrity
High
Availability
None

CVSS:3.1/AV:N/AC:H/PR:H/UI:R/S:C/C:H/I:H/A:N

NVD Known Affected Configurations (CPE 2.3)

TypeVendorProductVersionUpdateEditionLanguage
Application Redhat Build Of Keycloak - All All All

Vendor Declared Affected Products

SourceVendorProductVersionPlatforms
CNA Red Hat Red Hat Build Of Keycloak Not specified Not specified

References

ReferenceSourceLinkTags
bugzilla.redhat.com/show_bug.cgi [email protected] bugzilla.redhat.com Issue Tracking, Vendor Advisory
access.redhat.com/security/cve/CVE-2026-9795 [email protected] access.redhat.com Mitigation, Vendor Advisory
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 Andrej Tomci for reporting this issue. (en)

Additional Advisory Data

SourceTimeEvent
CNA2026-05-28T03:15:51.639ZReported to Red Hat.
CNA2026-05-28T03:16:49.326ZMade public.

Workarounds

CNA: To mitigate this issue, disable the Fine-Grained Admin Permissions (FGAPv2) feature in Keycloak if it is not strictly required. This can typically be done by setting `adminPermissionsEnabled` to `false` in the realm configuration. Disabling FGAPv2 will prevent the exploitation of this flaw by removing the vulnerable functionality. However, this may impact administrative delegation capabilities within Keycloak. A restart or reload of the Keycloak service may be required for the changes to take effect.

© CVE.report 2026 |

Use of this information constitutes acceptance for use in an AS IS condition. There are NO warranties, implied or otherwise, with regard to this information or its use. Any use of this information is at the user's risk. It is the responsibility of user to evaluate the accuracy, completeness or usefulness of any information, opinion, advice or other content. EACH USER WILL BE SOLELY RESPONSIBLE FOR ANY consequences of his or her direct or indirect use of this web site. ALL WARRANTIES OF ANY KIND ARE EXPRESSLY DISCLAIMED. This site will NOT BE LIABLE FOR ANY DIRECT, INDIRECT or any other kind of loss.

CVE, CWE, and OVAL are registred trademarks of The MITRE Corporation and the authoritative source of CVE content is MITRE's CVE web site. This site includes MITRE data granted under the following license.

Free CVE JSON API cve.report/api

CVE.report and Source URL Uptime Status status.cve.report