Keycloak: keycloak: privilege escalation via improper scope mapping enforcement
Published May 28, 2026
7.3
HIGHCVSS 3.1
EPSS 0.49%
Description
A 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.
Affected products
No data.
- n/a
No data.
Red Hat build of Keycloak 26.4
rhbk/keycloak-operator-bundle:26.4.13-1
Fixed · RHSA-2026:30050
Red Hat build of Keycloak 26.4
rhbk/keycloak-rhel9-operator:26.4-19
Fixed · RHSA-2026:30050
Red Hat build of Keycloak 26.4
rhbk/keycloak-rhel9:26.4-19
Fixed · RHSA-2026:30050
Red Hat build of Keycloak 26.4.13
rhbk/keycloak-rhel9
Fixed · RHSA-2026:30049
Red Hat build of Keycloak 26.6
rhbk/keycloak-operator-bundle:26.6.4-2
Fixed · RHSA-2026:30084
Red Hat build of Keycloak 26.6
rhbk/keycloak-rhel9-operator:26.6-8
Fixed · RHSA-2026:30084
Red Hat build of Keycloak 26.6
rhbk/keycloak-rhel9:26.6-8
Fixed · RHSA-2026:30084
Red Hat build of Keycloak 26.6.4
rhbk/keycloak-rhel9
Fixed · RHSA-2026:30083
| Product | Package | State | Advisory |
|---|---|---|---|
| Red Hat build of Keycloak 26.4 | rhbk/keycloak-operator-bundle:26.4.13-1 | Fixed | RHSA-2026:30050 |
| Red Hat build of Keycloak 26.4 | rhbk/keycloak-rhel9-operator:26.4-19 | Fixed | RHSA-2026:30050 |
| Red Hat build of Keycloak 26.4 | rhbk/keycloak-rhel9:26.4-19 | Fixed | RHSA-2026:30050 |
| Red Hat build of Keycloak 26.4.13 | rhbk/keycloak-rhel9 | Fixed | RHSA-2026:30049 |
| Red Hat build of Keycloak 26.6 | rhbk/keycloak-operator-bundle:26.6.4-2 | Fixed | RHSA-2026:30084 |
| Red Hat build of Keycloak 26.6 | rhbk/keycloak-rhel9-operator:26.6-8 | Fixed | RHSA-2026:30084 |
| Red Hat build of Keycloak 26.6 | rhbk/keycloak-rhel9:26.6-8 | Fixed | RHSA-2026:30084 |
| Red Hat build of Keycloak 26.6.4 | rhbk/keycloak-rhel9 | Fixed | RHSA-2026:30083 |
No package ranges for this CVE.
Remediation
Vendor solution
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.
Red Hat statement
This is an Important privilege escalation flaw in Keycloak when Fine-Grained Admin Permissions (FGAPv2) are enabled. An attacker with fine-grained client management permissions can bypass role mapping restrictions, allowing them to inject arbitrary realm roles into a client's scope. Subsequent authentication by a privileged user through the compromised client would then project these injected roles into their token, leading to unauthorized access. Exploitation requires specific administrative preconditions and user interaction.
Red Hat mitigation
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.
Metrics
No CVSS v4.0 score for this CVE.
CVSS:3.1/AV:N/AC:H/PR:H/UI:R/S:C/C:H/I:H/A:N
No CVSS v3.0 score for this CVE.
No CVSS v2.0 score for this CVE.
This CVE is not in the KEV list.
CISA SSVC (Vulnrichment)
Stakeholder-Specific Vulnerability Categorization from CISA ADP.
Exploitation
NoneAutomatable
NoTechnical Impact
TotalDecision
n/aAssessed May 28, 2026 · SSVC 2.0.3
Estimated probability of exploitation in the wild in the next 30 days (FIRST EPSS). As of Oct 3, 2026.
Score over time
May–Oct 2026- EPSS v4
- EPSS v5
Percentile over time
- EPSS v4
- EPSS v5
Table of values (3 key points)
Flat stretches are collapsed; showing up to 120 newest points.
| Date | Score | Percentile | Model |
|---|---|---|---|
| Oct 3, 2026 | 0.49% (0.00492) | 40.13th | v5 (v2026.06.15) |
| Jun 15, 2026 | 0.22% (0.00223) | 12.75th | v5 (v2026.06.15) |
| May 28, 2026 | 0.03% (0.00031) | 9.48th | v4 (v2025.03.14) |
References (14)
- https://access.redhat.com/errata/RHSA-2026:30049 vendor-advisoryx_refsource_REDHAT
- https://access.redhat.com/errata/RHSA-2026:30050 vendor-advisoryx_refsource_REDHAT
- https://access.redhat.com/errata/RHSA-2026:30083 vendor-advisoryx_refsource_REDHAT
- https://access.redhat.com/errata/RHSA-2026:30084 vendor-advisoryx_refsource_REDHAT
- https://access.redhat.com/security/cve/CVE-2026-9795 vdb-entryx_refsource_REDHATMitigationVendor Advisory
- https://bugzilla.redhat.com/show_bug.cgi?id=2482462 issue-trackingx_refsource_REDHATIssue TrackingVendor Advisory
- https://github.com/advisories/GHSA-32h4-44jj-c5vx Advisory
- https://github.com/keycloak/keycloak/commit/8894c027e788904c740ff9a1a60fcfaa34a10d13
- https://github.com/keycloak/keycloak/issues/50350
- https://github.com/keycloak/keycloak/pull/50451
- https://github.com/keycloak/keycloak/security/advisories/GHSA-32h4-44jj-c5vx
- https://nvd.nist.gov/vuln/detail/CVE-2026-9795
- https://security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-9795.json
- https://www.cve.org/CVERecord?id=CVE-2026-9795
Change history (0)
No recorded changes yet.