Linux Kernel Bcache NULL Pointer Dereference Vulnerability

Vulnerability

A vulnerability in the Linux kernel's bcache component allows for a NULL pointer dereference, leading to a kernel crash. This issue arises during the registration of cache sets, where memory allocation failures are not properly handled. Specifically, the problem occurs in the 'bch_cache_set_alloc' function, which fails to allocate memory for cache set structures. When the 'register_cache_set' function attempts to use this uninitialized data, it results in a NULL pointer dereference, causing a system crash.

Impact

Exploitation of this vulnerability leads to a kernel crash due to a NULL pointer dereference, causing a denial of service by interrupting normal system operations.

Reproduction

The vulnerability can be reproduced by registering a cache set in the bcache component of the Linux kernel. If the memory allocation for the cache set fails, the 'bch_cache_set_alloc' function returns NULL. The 'register_cache_set' function then attempts to use this NULL value, which results in a NULL pointer dereference in the 'cache_set_flush' function, causing the kernel to crash.

Added: Jul 9, 2025, 11:18 AM
Updated: Jul 9, 2025, 11:18 AM

Vulnerability Rating

Custom Algorithm
spread
9.0
impact
2.5
exploitability
4.3
remediation
0.0
relevance
0.2
threat
4.8
urgency
2.9
incentive
1.7

Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.