Skip to content
OpenAdvisories
Medium · 6.5 CVE-2023-6787 EUVD-2024-1185GHSA-c9h6-v78w-52wj

Keycloak: session hijacking via re-authentication

Published Apr 25, 2024 · Updated Nov 11, 2025 · Assigned by redhat

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.

Affected products

VendorProductAffectedFixed
— keycloak < 22.0.10, < 24.0.3 22.0.10
Red Hat Red Hat build of Keycloak 22 — —
Red Hat Red Hat build of Keycloak 22.0.10 — —
Red Hat Red Hat Single Sign-On 7 — —

Affected packages

EcosystemPackageAffectedFixedRecord
Maven org.keycloak:keycloak-services < 22.0.10 22.0.10 GHSA-c9h6-v78w-52wj
Maven org.keycloak:keycloak-services >= 23.0.0, < 24.0.3 24.0.3 GHSA-c9h6-v78w-52wj

Advisories 2

References