4.8
MEDIUM
CVE-2024-7318
Keycloak FreeOTP OTP Code Expiration Bypass (Default Token Period)
Description

A vulnerability was found in Keycloak. Expired OTP codes are still usable when using FreeOTP when the OTP token period is set to 30 seconds (default). Instead of expiring and deemed unusable around 30 seconds in, the tokens are valid for an additional 30 seconds totaling 1 minute. A one time passcode that is valid longer than its expiration time increases the attack window for malicious actors to abuse the system and compromise accounts. Additionally, it increases the attack surface because at any given time, two OTPs are valid.

INFO

Published Date :

Sept. 9, 2024, 7:15 p.m.

Last Modified :

Oct. 7, 2024, 8:15 p.m.

Remotely Exploitable :

Yes !

Impact Score :

2.5

Exploitability Score :

2.2
Affected Products

The following products are affected by CVE-2024-7318 vulnerability. Even if cvefeed.io is aware of the exact versions of the products that are affected, the information is not represented in the table below.

ID Vendor Product Action
1 Redhat build_of_keycloak
References to Advisories, Solutions, and Tools

Here, you will find a curated list of external links that provide in-depth information, practical solutions, and valuable tools related to CVE-2024-7318.

URL Resource
https://access.redhat.com/errata/RHSA-2024:6502 Issue Tracking
https://access.redhat.com/errata/RHSA-2024:6503 Issue Tracking
https://access.redhat.com/security/cve/CVE-2024-7318 Vendor Advisory
https://bugzilla.redhat.com/show_bug.cgi?id=2301876 Issue Tracking Vendor Advisory

We scan GitHub repositories to detect new proof-of-concept exploits. Following list is a collection of public exploits and proof-of-concepts, which have been published on GitHub (sorted by the most recently updated).

Results are limited to the first 15 repositories due to potential performance issues.

The following list is the news that have been mention CVE-2024-7318 vulnerability anywhere in the article.

The following table lists the changes that have been made to the CVE-2024-7318 vulnerability over time.

Vulnerability history details can be useful for understanding the evolution of a vulnerability, and for identifying the most recent changes that may impact the vulnerability's severity, exploitability, or other characteristics.

  • Reanalysis by [email protected]

    Oct. 07, 2024

    Action Type Old Value New Value
    Removed CVSS V3.1 NIST AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H
    Added CVSS V3.1 NIST AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:L/A:N
  • Initial Analysis by [email protected]

    Sep. 20, 2024

    Action Type Old Value New Value
    Added CVSS V3.1 NIST AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H
    Changed Reference Type https://access.redhat.com/errata/RHSA-2024:6502 No Types Assigned https://access.redhat.com/errata/RHSA-2024:6502 Issue Tracking
    Changed Reference Type https://access.redhat.com/errata/RHSA-2024:6503 No Types Assigned https://access.redhat.com/errata/RHSA-2024:6503 Issue Tracking
    Changed Reference Type https://access.redhat.com/security/cve/CVE-2024-7318 No Types Assigned https://access.redhat.com/security/cve/CVE-2024-7318 Vendor Advisory
    Changed Reference Type https://bugzilla.redhat.com/show_bug.cgi?id=2301876 No Types Assigned https://bugzilla.redhat.com/show_bug.cgi?id=2301876 Issue Tracking, Vendor Advisory
    Added CPE Configuration OR *cpe:2.3:a:redhat:build_of_keycloak:*:*:*:*:*:*:*:* versions from (including) 22.0 up to (excluding) 24.0.7
  • CVE Received by [email protected]

    Sep. 09, 2024

    Action Type Old Value New Value
    Added Description A vulnerability was found in Keycloak. Expired OTP codes are still usable when using FreeOTP when the OTP token period is set to 30 seconds (default). Instead of expiring and deemed unusable around 30 seconds in, the tokens are valid for an additional 30 seconds totaling 1 minute. A one time passcode that is valid longer than its expiration time increases the attack window for malicious actors to abuse the system and compromise accounts. Additionally, it increases the attack surface because at any given time, two OTPs are valid.
    Added Reference Red Hat, Inc. https://access.redhat.com/errata/RHSA-2024:6502 [No types assigned]
    Added Reference Red Hat, Inc. https://access.redhat.com/errata/RHSA-2024:6503 [No types assigned]
    Added Reference Red Hat, Inc. https://access.redhat.com/security/cve/CVE-2024-7318 [No types assigned]
    Added Reference Red Hat, Inc. https://bugzilla.redhat.com/show_bug.cgi?id=2301876 [No types assigned]
    Added CWE Red Hat, Inc. CWE-324
    Added CVSS V3.1 Red Hat, Inc. AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:L/A:N
EPSS is a daily estimate of the probability of exploitation activity being observed over the next 30 days. Following chart shows the EPSS score history of the vulnerability.
CWE - Common Weakness Enumeration

While CVE identifies specific instances of vulnerabilities, CWE categorizes the common flaws or weaknesses that can lead to vulnerabilities. CVE-2024-7318 is associated with the following CWEs:

Common Attack Pattern Enumeration and Classification (CAPEC)

Common Attack Pattern Enumeration and Classification (CAPEC) stores attack patterns, which are descriptions of the common attributes and approaches employed by adversaries to exploit the CVE-2024-7318 weaknesses.

CVSS31 - Vulnerability Scoring System
Attack Vector
Attack Complexity
Privileges Required
User Interaction
Scope
Confidentiality
Integrity
Availability