5.5
MEDIUM
CVE-2024-39482
Linux Kernel: Bcache Variable Length Array Over-Indexing Vulnerability
Description

In the Linux kernel, the following vulnerability has been resolved: bcache: fix variable length array abuse in btree_iter btree_iter is used in two ways: either allocated on the stack with a fixed size MAX_BSETS, or from a mempool with a dynamic size based on the specific cache set. Previously, the struct had a fixed-length array of size MAX_BSETS which was indexed out-of-bounds for the dynamically-sized iterators, which causes UBSAN to complain. This patch uses the same approach as in bcachefs's sort_iter and splits the iterator into a btree_iter with a flexible array member and a btree_iter_stack which embeds a btree_iter as well as a fixed-length data array.

INFO

Published Date :

July 5, 2024, 7:15 a.m.

Last Modified :

July 8, 2024, 6 p.m.

Source :

416baaa9-dc9f-4396-8d5f-8c081fb06d67

Remotely Exploitable :

No

Impact Score :

3.6

Exploitability Score :

1.8
Affected Products

The following products are affected by CVE-2024-39482 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 Linux linux_kernel
References to Advisories, Solutions, and Tools

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-39482 vulnerability anywhere in the article.

The following table lists the changes that have been made to the CVE-2024-39482 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.

  • Initial Analysis by [email protected]

    Jul. 08, 2024

    Action Type Old Value New Value
    Added CVSS V3.1 NIST AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
    Changed Reference Type https://git.kernel.org/stable/c/0c31344e22dd8d6b1394c6e4c41d639015bdc671 No Types Assigned https://git.kernel.org/stable/c/0c31344e22dd8d6b1394c6e4c41d639015bdc671 Mailing List, Patch
    Changed Reference Type https://git.kernel.org/stable/c/2c3d7b03b658dc8bfa6112b194b67b92a87e081b No Types Assigned https://git.kernel.org/stable/c/2c3d7b03b658dc8bfa6112b194b67b92a87e081b Mailing List, Patch
    Changed Reference Type https://git.kernel.org/stable/c/3a861560ccb35f2a4f0a4b8207fa7c2a35fc7f31 No Types Assigned https://git.kernel.org/stable/c/3a861560ccb35f2a4f0a4b8207fa7c2a35fc7f31 Mailing List, Patch
    Changed Reference Type https://git.kernel.org/stable/c/5a1922adc5798b7ec894cd3f197afb6f9591b023 No Types Assigned https://git.kernel.org/stable/c/5a1922adc5798b7ec894cd3f197afb6f9591b023 Mailing List, Patch
    Changed Reference Type https://git.kernel.org/stable/c/6479b9f41583b013041943c4602e1ad61cec8148 No Types Assigned https://git.kernel.org/stable/c/6479b9f41583b013041943c4602e1ad61cec8148 Mailing List, Patch
    Changed Reference Type https://git.kernel.org/stable/c/934e1e4331859183a861f396d7dfaf33cb5afb02 No Types Assigned https://git.kernel.org/stable/c/934e1e4331859183a861f396d7dfaf33cb5afb02 Mailing List, Patch
    Added CWE NIST CWE-770
    Added CPE Configuration OR *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 5.10 up to (excluding) 5.10.221 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 5.15 up to (excluding) 5.15.162 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 6.1 up to (excluding) 6.1.94 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 6.6 up to (excluding) 6.6.34 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 6.9 up to (excluding) 6.9.5
  • CVE Modified by 416baaa9-dc9f-4396-8d5f-8c081fb06d67

    Jul. 05, 2024

    Action Type Old Value New Value
    Added Reference kernel.org https://git.kernel.org/stable/c/2c3d7b03b658dc8bfa6112b194b67b92a87e081b [No types assigned]
    Added Reference kernel.org https://git.kernel.org/stable/c/5a1922adc5798b7ec894cd3f197afb6f9591b023 [No types assigned]
  • CVE Received by 416baaa9-dc9f-4396-8d5f-8c081fb06d67

    Jul. 05, 2024

    Action Type Old Value New Value
    Added Description In the Linux kernel, the following vulnerability has been resolved: bcache: fix variable length array abuse in btree_iter btree_iter is used in two ways: either allocated on the stack with a fixed size MAX_BSETS, or from a mempool with a dynamic size based on the specific cache set. Previously, the struct had a fixed-length array of size MAX_BSETS which was indexed out-of-bounds for the dynamically-sized iterators, which causes UBSAN to complain. This patch uses the same approach as in bcachefs's sort_iter and splits the iterator into a btree_iter with a flexible array member and a btree_iter_stack which embeds a btree_iter as well as a fixed-length data array.
    Added Reference kernel.org https://git.kernel.org/stable/c/934e1e4331859183a861f396d7dfaf33cb5afb02 [No types assigned]
    Added Reference kernel.org https://git.kernel.org/stable/c/6479b9f41583b013041943c4602e1ad61cec8148 [No types assigned]
    Added Reference kernel.org https://git.kernel.org/stable/c/0c31344e22dd8d6b1394c6e4c41d639015bdc671 [No types assigned]
    Added Reference kernel.org https://git.kernel.org/stable/c/3a861560ccb35f2a4f0a4b8207fa7c2a35fc7f31 [No types assigned]
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-39482 is associated with the following CWEs:

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