CVE-2023-6787
Keycloak: session hijacking via re-authentication
MEDIUM 6.5
At a glance
- Source
- NVD
- EPSS
- EPSS 0.74 % · percentile 55 ()
- State
- PUBLISHED
- Published
- Updated
- Assigner
- redhat
- NVD status
- Analyzed
Description
A flaw was found in Keycloak that occurs from an error in the re-authentication mechanism within org.keycloak.authentication. This flaw allows hijacking an active Keycloak session by triggering a new authentication process with the query parameter "prompt=login," prompting the user to re-enter their credentials. If the user cancels this re-authentication by selecting "Restart login," an account takeover may occur, as the new session, with a different SUB, will possess the same SID as the previous session.
Weaknesses (CWE)
- CWE-287 — Improper Authentication
References
Scores
| Version | Score | Vector | Scored by |
|---|---|---|---|
| CVSS 3.1 | MEDIUM 6.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:H/A:N | redhat |
| CVSS 3.1 | MEDIUM 6.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:H/A:N | NVD · secalert@redhat.com (Secondary) |
| CVSS 3.1 | HIGH 8.8 | CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H | NVD · nvd@nist.gov (Primary) |
Advisories
- GHSA-c9h6-v78w-52wj — Keycloak vulnerable to session hijacking via re-authentication
European references
- ENISA EUVD · EUVD-2024-1185
- GCVE · GCVE-0-2023-6787
Affected configurations (NVD CPE)
cpe:2.3:a:redhat:build_of_keycloak:-:*:*:*:text-only:*:*:*cpe:2.3:a:redhat:keycloak:*:*:*:*:*:*:*:*< 22.0.10cpe:2.3:a:redhat:keycloak:*:*:*:*:*:*:*:*≥ 23.0.0 < 24.0.3
Affected products
| Product | Versions |
|---|---|
| keycloak | affected 0 < 22.0.10 ; affected 0 < 24.0.3 |
| Red Hat · Red Hat build of Keycloak 22 | unaffected 22.0.10-1 < * |
| Red Hat · Red Hat build of Keycloak 22 | unaffected 22-13 < * |
| Red Hat · Red Hat build of Keycloak 22 | unaffected 22-16 < * |
| Red Hat · Red Hat build of Keycloak 22.0.10 | |
| Red Hat · Red Hat Single Sign-On 7 |
Sources
| Source | Licence |
|---|---|
| CVE List (CVEProject cvelistV5) | CVE Program Terms of Use |
| EPSS (FIRST.org) | FIRST — attribution requested |
| ENISA EUVD | ENISA — reproduction authorised, source acknowledged |
| NVD (NIST) via fkie-cad/nvd-json-data-feeds | Public domain — this product uses data from the NVD API but is not endorsed or certified by the NVD |