Skip to content

GHSA-c7xw-p58w-h6fj CVE-2023-0105

Keycloak: Impersonation and lockout possible through incorrect handling of email trust

Medium Maven
Severity
6.5 / 10
Medium · CVSS 3.1
Exploit chance (EPSS)
0.72%
Chance of exploitation in the next 30 days. Higher than 53.92% of scored vulnerabilities.
Known exploited
No
Not in CISA's catalog
Weakness
CWE-287 Improper Authentication
CWE-841 Improper Enforcement of Behavioral Workflow
Fix
22.0.1
Upgrade org.keycloak:keycloak-core to this version or later

Description

Impersonation and lockout are possible due to email trust not being handled correctly in Keycloak. Since the verified state is not reset when the email changes, it is possible for users to shadow others with the same email and lock out or impersonate them.

Affected versions

Maven

PackageVulnerableFixed in
org.keycloak:keycloak-core
< 22.0.1
22.0.1

How to fix

Move to the fixed version or later with your package manager, update the lockfile, and run your tests. If the package only arrives through another dependency, upgrade that dependency first. If none of its releases pulls a fixed version yet, force the version with your package manager's override.

org.keycloak:keycloak-core Maven → 22.0.1

maven
<dependency><groupId>org.keycloak</groupId><artifactId>keycloak-core</artifactId><version>22.0.1</version></dependency>
gradle
implementation("org.keycloak:keycloak-core:22.0.1")

Severity breakdown

CVSS 3.1 6.5

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:L

Attack vector
Network
Attack complexity
Low
Privileges required
None
User interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
Low
Availability
Low

Weakness

CWE-287: Improper Authentication

When an actor claims to have a given identity, the product does not prove or insufficiently proves that the claim is correct.

How to prevent it
  • Architecture and Design: Use an authentication framework or library such as the OWASP ESAPI Authentication feature.

CWE-841: Improper Enforcement of Behavioral Workflow

The product supports a session in which more than one behavior must be performed by an actor, but it does not properly ensure that the actor performs the behaviors in the required sequence.

References

Timeline

  1. Published
  2. Last updated by the source
  3. Latest EPSS score
AdvisorySeverityWhy it's related
GHSA-q4xq-445g-g6ch
Keycloak allows cross-site scripting (XSS)
Low Also affects org.keycloak:keycloak-core
GHSA-93ww-43rr-79v3
Keycloak mTLS Authentication Bypass via Reverse Proxy TLS Termination
High Also affects org.keycloak:keycloak-core
GHSA-w97f-w3hq-36g2
Keycloak Denial of Service vulnerability
High Also affects org.keycloak:keycloak-core
GHSA-xmmm-jw76-q7vg
Keycloaks's One Time Passcode (OTP) is valid longer than expiration timeSeverity
Medium Also affects org.keycloak:keycloak-core
GHSA-g4gc-rh26-m3p5
Keycloak Open Redirect vulnerability
Medium Also affects org.keycloak:keycloak-core
GHSA-9vm7-v8wj-3fqw
keycloak-core: open redirect via "form_post.jwt" JARM response mode
Medium Also affects org.keycloak:keycloak-core
GHSA-5q66-v53q-pm35
Keycloak vulnerable to Plaintext Storage of User Password
High Also affects org.keycloak:keycloak-core
GHSA-5cc8-pgp5-7mpm
Keycloak Untrusted Certificate Validation vulnerability
Medium Also affects org.keycloak:keycloak-core
Is this in your code?

MergeHarbor checks every repository's dependencies against this database, ranks what matters by exploitability and reachability, routes it to the owning team and opens the fix pull request.

Check your repos with MergeHarbor