CVE-2024-47733 netfs: Delete subtree of 'fs/netfs' when netfs module exits

Medium 5.5 Published Updated

A memory leak in the Linux kernel netfs module occurs during exit, potentially leading 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-47733?

CVE-2024-47733 is a medium-severity memory corruption vulnerability in Linux kernel, published on 21 Oct 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:

netfs: Delete subtree of 'fs/netfs' when netfs module exits

In netfs_init() or fscache_proc_init(), we create dentry under 'fs/netfs', but in netfs_exit(), we only delete the proc entry of 'fs/netfs' without deleting its subtree. This triggers the following WARNING:

================================================================== remove_proc_entry: removing non-empty directory 'fs/netfs', leaking at least 'requests' WARNING: CPU: 4 PID: 566 at fs/proc/generic.c:717 remove_proc_entry+0x160/0x1c0 Modules linked in: netfs(-) CPU: 4 UID: 0 PID: 566 Comm: rmmod Not tainted 6.11.0-rc3 #860 RIP: 0010:remove_proc_entry+0x160/0x1c0 Call Trace: <TASK> netfs_exit+0x12/0x620 [netfs] __do_sys_delete_module.isra.0+0x14c/0x2e0 do_syscall_64+0x4b/0x110 entry_SYSCALL_64_after_hwframe+0x76/0x7e ==================================================================

Therefore use remove_proc_subtree() instead of remove_proc_entry() to fix the above problem.

Weakness: CWE-772

Which versions are affected by CVE-2024-47733?

It affects 1 product.

Products include Linux kernel.

How do I fix CVE-2024-47733?

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-47733 being exploited?

There is no known exploitation of CVE-2024-47733 in the wild and no public exploit code.

All Linux kernel vulnerabilities

Sources

Also known as BELL-CVE-2024-47733, DEBIAN-CVE-2024-47733, GHSA-32j9-8mq4-72ff, UBUNTU-CVE-2024-47733.

Is CVE-2024-47733 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free