CVE-2026-23158
Unknown Unknown - Not Provided
Use-After-Free in Linux Kernel gpio-virtuser Mutex Handling

Publication date: 2026-02-14

Last updated on: 2026-03-18

Assigner: kernel.org

Description
In the Linux kernel, the following vulnerability has been resolved: gpio: virtuser: fix UAF in configfs release path The gpio-virtuser configfs release path uses guard(mutex) to protect the device structure. However, the device is freed before the guard cleanup runs, causing mutex_unlock() to operate on freed memory. Specifically, gpio_virtuser_device_config_group_release() destroys the mutex and frees the device while still inside the guard(mutex) scope. When the function returns, the guard cleanup invokes mutex_unlock(&dev->lock), resulting in a slab use-after-free. Limit the mutex lifetime by using a scoped_guard() only around the activation check, so that the lock is released before mutex_destroy() and kfree() are called.
CVSS Scores
EPSS Scores
Probability:
Percentile:
Meta Information
Published
2026-02-14
Last Modified
2026-03-18
Generated
2026-05-06
AI Q&A
2026-02-14
EPSS Evaluated
2026-05-05
NVD
EUVD
Affected Vendors & Products
Showing 9 associated CPEs
Vendor Product Version / Range
linux linux_kernel 6.19
linux linux_kernel 6.19
linux linux_kernel 6.19
linux linux_kernel 6.19
linux linux_kernel 6.19
linux linux_kernel 6.19
linux linux_kernel 6.19
linux linux_kernel From 6.13 (inc) to 6.18.9 (exc)
linux linux_kernel From 6.11 (inc) to 6.12.69 (exc)
Helpful Resources
Exploitability
CWE
CWE Icon
KEV
KEV Icon
CWE ID Description
CWE-416 The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. Any operations using the original pointer are no longer valid because the memory "belongs" to the code that operates on the new pointer.
Attack-Flow Graph
AI Powered Q&A
Can you explain this vulnerability to me?

This vulnerability is a use-after-free (UAF) issue in the Linux kernel's gpio-virtuser configfs release path. The problem occurs because the device structure is freed before the mutex guarding it is properly released. Specifically, the function gpio_virtuser_device_config_group_release() destroys the mutex and frees the device while still inside the mutex guard scope. When the guard cleanup tries to unlock the mutex, it operates on memory that has already been freed, leading to a use-after-free condition.

The fix involves limiting the mutex's lifetime by using a scoped guard only around the activation check, ensuring the lock is released before the mutex is destroyed and the device memory is freed.


How can this vulnerability impact me? :

A use-after-free vulnerability like this can lead to undefined behavior in the kernel, including potential system crashes, data corruption, or escalation of privileges if exploited by an attacker. Since the mutex_unlock() operates on freed memory, it could be manipulated to execute arbitrary code or cause denial of service by crashing the system.


How does this vulnerability affect compliance with common standards and regulations (like GDPR, HIPAA)?:

I don't know


How can this vulnerability be detected on my network or system? Can you suggest some commands?

I don't know


What immediate steps should I take to mitigate this vulnerability?

The vulnerability has been resolved by limiting the mutex lifetime in the gpio-virtuser configfs release path. To mitigate this vulnerability, you should update your Linux kernel to a version that includes the fix for CVE-2026-23158.

Specifically, ensure your kernel includes the patch that changes the gpio_virtuser_device_config_group_release() function to release the lock before destroying the mutex and freeing the device, preventing the use-after-free condition.


Ask Our AI Assistant
Need more information? Ask your question to get an AI reply (Powered by our expertise)
0/70
EPSS Chart