CVE Catalog

CVE-2025-21915

HighCVSS 7.0
Published: Updated: Translated: NVD NIST

Exploitation Probability (EPSS)

Low risk
0.19%

9th percentile - higher than 9% of all known CVEs

Summary

In the Linux kernel CDX driver (drivers/cdx/cdx.c), driver_override_show() reads the driver_override field without locking, while driver_override_store() can modify it, freeing the old value. This can lead to a use-after-free (UAF) and potential kernel address leak.

Risk Assessment

A local user can read kernel addresses via sysfs, aiding ASLR bypass attacks. Additionally, accessing freed memory may cause system crashes.

Recommendation

Apply the Linux kernel patch that adds device_lock() in driver_override_show() to ensure safe concurrent access.

Other vulnerabilities in Linux kernel

See all
Original NVD description (English source)

In the Linux kernel, the following vulnerability has been resolved: cdx: Fix possible UAF error in driver_override_show() Fixed a possible UAF problem in driver_override_show() in drivers/cdx/cdx.c This function driver_override_show() is part of DEVICE_ATTR_RW, which includes both driver_override_show() and driver_override_store(). These functions can be executed concurrently in sysfs. The driver_override_store() function uses driver_set_override() to update the driver_override value, and driver_set_override() internally locks the device (device_lock(dev)). If driver_override_show() reads cdx_dev->driver_override without locking, it could potentially access a freed pointer if driver_override_store() frees the string concurrently. This could lead to printing a kernel address, which is a security risk since DEVICE_ATTR can be read by all users. Additionally, a similar pattern is used in drivers/amba/bus.c, as well as many other bus drivers, where device_lock() is taken in the show function, and it has been working without issues. This potential bug was detected by our experimental static analysis tool, which analyzes locking APIs and paired functions to identify data races and atomicity violations.

Vulnerability data from NVD (NIST) · CISA KEV · EPSS