CVE-2024-26993 fs: sysfs: Fix reference leak in sysfs_break_active_protection()
A reference leak in the Linux kernel sysfs subsystem can lead to resource exhaustion and denial of service.
- Exploited in the wild
- Not known
- Login needed
- Any signed-in user
- Attackable
- Local or same network only
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2024-26993?
CVE-2024-26993 is a medium-severity memory corruption vulnerability in Linux kernel, published on 1 May 2024. It can only be exploited from the same machine or local network, with no action from the victim.
Official description
In the Linux kernel, the following vulnerability has been resolved:
fs: sysfs: Fix reference leak in sysfs_break_active_protection()
The sysfs_break_active_protection() routine has an obvious reference leak in its error path. If the call to kernfs_find_and_get() fails then kn will be NULL, so the companion sysfs_unbreak_active_protection() routine won't get called (and would only cause an access violation by trying to dereference kn->parent if it was called). As a result, the reference to kobj acquired at the start of the function will never be released.
Fix the leak by adding an explicit kobject_put() call when kn is NULL.
Which versions are affected by CVE-2024-26993?
It affects 1 product.
Products include Linux kernel.
How do I fix CVE-2024-26993?
Apply the vendor's patch.
Upgrade to the fixed version. Memory-safe languages, compiler hardening and fuzzing prevent most new cases. More about Memory corruption.
Is CVE-2024-26993 being exploited?
There is no known exploitation of CVE-2024-26993 in the wild and no public exploit code.
Other vulnerabilities in Linux kernel
Sources
Also known as AZL-40511, BELL-CVE-2024-26993, DEBIAN-CVE-2024-26993, GHSA-x5rp-2v68-jcgf, UBUNTU-CVE-2024-26993.