6.9medium
Org.keycloak.forms.login: keycloak: keycloak: arbitrary code execution via stored cross-site scripting (xss) in organization selection login page
- Severity
- 6.9medium CVSS:3.1 by redhat
- Exploit likelihood
- 0.37% (higher than 32% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- redhat
- Also known as
- GHSA-m32f-8vh9-2hh3
Description
A flaw was found in Keycloak, specifically in the organization selection login page. A remote attacker with `manage-realm` or `manage-organizations` administrative privileges can exploit a Stored Cross-Site Scripting (XSS) vulnerability. This flaw occurs because the `organization.alias` is placed into an inline JavaScript `onclick` handler, allowing a crafted JavaScript payload to execute in a user's browser when they view the login page. Successful exploitation enables arbitrary JavaScript execution, potentially leading to session theft, unauthorized account actions, or further attacks against users of the affected realm.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| Red Hat Red Hat build of Keycloak 26.4.12 | Not specified | CVE List |
| rhbk/keycloak-rhel9 | Not specified | CVE List |
| org.keycloak:keycloak-services (Maven) | up to 26.5.5 | GitHub Advisory Database |
| redhat build_of_keycloak | Not specified | NVD |
All scores
| redhat | 6.9medium CVSS:3.1 | CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:C/C:H/I:L/A:N |
| GitHub | 6.9medium CVSS:3.1 | CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:C/C:H/I:L/A:N |
| NVD | 4.8medium CVSS:3.1 | CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:C/C:L/I:L/A:N |
Classification
SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial.
What each source says
CVE List
A flaw was found in Keycloak, specifically in the organization selection login page. A remote attacker with `manage-realm` or `manage-organizations` administrative privileges can exploit a Stored Cross-Site Scripting (XSS) vulnerability. This flaw occurs because the `organization.alias` is placed into an inline JavaScript `onclick` handler, allowing a crafted JavaScript payload to execute in a user's browser when they view the login page. Successful exploitation enables arbitrary JavaScript execution, potentially leading to session theft, unauthorized account actions, or further attacks against users of the affected realm.
NVD (es)
Se encontró un fallo en Keycloak, específicamente en la página de inicio de sesión de selección de organización. Un atacante remoto con privilegios administrativos ’manage-realm’ o ’manage-organizations’ puede explotar una vulnerabilidad de Cross-Site Scripting (XSS) almacenado. Este fallo ocurre porque el ’organization.alias’ se inserta en un gestor ’onclick’ de JavaScript en línea, permitiendo que una carga útil de JavaScript manipulada se ejecute en el navegador de un usuario cuando visualizan la página de inicio de sesión. La explotación exitosa permite la ejecución arbitraria de JavaScript, lo que podría llevar al robo de sesión, acciones de cuenta no autorizadas o ataques adicionales contra usuarios del reino afectado.
References
| https://access.redhat.com/errata/RHSA-2026:19596 | vendor-advisory, web | |
| https://access.redhat.com/security/cve/CVE-2026-37980 | mitigation, vdb-entry, vendor-advisory, web | |
| https://bugzilla.redhat.com/show_bug.cgi?id=2455325 | issue-tracking, vendor-advisory, web | |
| https://nvd.nist.gov/vuln/detail/CVE-2026-37980 | advisory | |
| https://github.com/keycloak/keycloak/issues/48049 | web | |
| https://github.com/keycloak/keycloak | package | |
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2026-37980 changed 2026-11-26 | CVE Terms of Use |
| GitHub Advisory Database | GHSA-m32f-8vh9-2hh3 changed 2026-10-22 | CC-BY-4.0 |
| NVD | CVE-2026-37980 changed 2026-10-26 | Public domain |