Vulnerability · Published Sep 19, 2024 · Assigned by redhat

CVE-2024-8698Keycloak-saml-core: improper verification of saml responses leading to privilege escalation in keycloak

High 7.7

In plain English

A high-severity security flaw in keycloak. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 2.0% (higher than 81% of all known vulnerabilities). Ready-made attack tooling exists: Nuclei, public proof-of-concept code. Fixed versions are available - upgrade the affected package.

Severity (CVSS 3.1)7.7High
Exploit odds (30 days)2.0%top 18.9% of all CVEs
Exploited in the wildNo reportsCISA SSVC: none
Attack tooling2Nuclei, Public PoC

Official description

A flaw exists in the SAML signature validation method within the Keycloak XMLSignatureUtil class. The method incorrectly determines whether a SAML signature is for the full document or only for specific assertions based on the position of the signature in the XML document, rather than the Reference element used to specify the signed element. This flaw allows attackers to create crafted responses that can bypass the validation, potentially leading to privilege escalation or impersonation attacks.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
Mavenorg.keycloak:keycloak-saml-core22.0.13GHSA-xgfv-xpx8-qhcr
Mavenorg.keycloak:keycloak-saml-core24.0.8GHSA-xgfv-xpx8-qhcr
Mavenorg.keycloak:keycloak-saml-core25.0.6GHSA-xgfv-xpx8-qhcr

Affected products (as reported)

VendorProductVersions
keycloak 0 – before 25.0.5
Red Hat Red Hat Build of Keycloak see references
Red Hat Red Hat Build of Keycloak see references
Red Hat Red Hat build of Keycloak 22 see references
Red Hat Red Hat build of Keycloak 22 see references
Red Hat Red Hat build of Keycloak 22 see references
Red Hat Red Hat build of Keycloak 24 see references
Red Hat Red Hat build of Keycloak 24 see references
Red Hat Red Hat build of Keycloak 24 see references
Red Hat Red Hat JBoss Enterprise Application Platform 8 see references
Red Hat Red Hat JBoss Enterprise Application Platform 8 see references
Red Hat Red Hat JBoss Enterprise Application Platform 8.0 for RHEL 8 see references
Red Hat Red Hat JBoss Enterprise Application Platform 8.0 for RHEL 8 see references
Red Hat Red Hat JBoss Enterprise Application Platform 8.0 for RHEL 8 see references
Red Hat Red Hat JBoss Enterprise Application Platform 8.0 for RHEL 8 see references
Red Hat Red Hat JBoss Enterprise Application Platform 8.0 for RHEL 8 see references
Red Hat Red Hat JBoss Enterprise Application Platform 8.0 for RHEL 8 see references
Red Hat Red Hat JBoss Enterprise Application Platform 8.0 for RHEL 8 see references
Red Hat Red Hat JBoss Enterprise Application Platform 8.0 for RHEL 8 see references
Red Hat Red Hat JBoss Enterprise Application Platform 8.0 for RHEL 8 see references
Red Hat Red Hat JBoss Enterprise Application Platform 8.0 for RHEL 8 see references
Red Hat Red Hat JBoss Enterprise Application Platform 8.0 for RHEL 8 see references
Red Hat Red Hat JBoss Enterprise Application Platform 8.0 for RHEL 8 see references
Red Hat Red Hat JBoss Enterprise Application Platform 8.0 for RHEL 8 see references
Red Hat Red Hat JBoss Enterprise Application Platform 8.0 for RHEL 8 see references
Red Hat Red Hat JBoss Enterprise Application Platform 8.0 for RHEL 8 see references
Red Hat Red Hat JBoss Enterprise Application Platform 8.0 for RHEL 8 see references
Red Hat Red Hat JBoss Enterprise Application Platform 8.0 for RHEL 8 see references
Red Hat Red Hat JBoss Enterprise Application Platform 8.0 for RHEL 8 see references
Red Hat Red Hat JBoss Enterprise Application Platform 8.0 for RHEL 8 see references

Weakness: CWE-347 · Vector: CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:L/A:L

References