CVE-2024-50130·Kernel vulnerability
In the Linux kernel, the following vulnerability has been resolved: netfilter: bpf: must hold reference on net namespace BUG: KASAN: slab-use-after-free in __nf_unregister_net_hook+0x640/0x6b0 Read of size 8 at addr ffff8880106fe400 by task repro/72= bpf_nf_link_release+0xda/0x1e0 bpf_link_free+0x139/0x2d0 bpf_link_release+0x68/0x80 __fput+0x414/0xb60 Eric says: It seems that bpf was able to defer the __nf_unregister_net_hook() after exit()/close() time. Perhaps a netns reference is missing, because the netns has been dismantled/freed already. bpf_nf_link_attach() does : link->net = net; But I do not see a reference being taken on net. Add such a reference and release it after hook unreg. Note that I was unable to get syzbot reproducer to work, so I do not know if this resolves this splat.
- Severity
- high
- Software
- Kernel
- Fixed in
- 6.11.6
- Published
- 2024-11-05
Affected versions
From: 6.7
Until: 6.11.6
Fixed in: 6.11.6
How to fix this CVE
Update your Linux kernel to version 6.11.6 or later to resolve a use-after-free vulnerability in the netfilter BPF subsystem. This flaw allows improper memory access when BPF programs interact with network namespaces that have been deallocated. Kernel maintainers have backported the fix to stable branches; ensure your system receives the patched kernel image and reboot to activate the security update.
sudo dnf update kernel && sudo rebootDefensia detects this vulnerability
How to check if you are affected
- Run 'uname -r' to retrieve your current kernel version and confirm it is earlier than 6.11.6
- Check if BPF netfilter hooks are loaded by running 'lsmod | grep -i nf_bpf' or examining /proc/modules for netfilter BPF modules
- Review kernel logs with 'sudo dmesg | grep -i "use-after-free\|kasan\|nf_unregister_net_hook"' to detect past exploitation attempts
- After patching, reboot the system and run 'uname -r' again to verify the kernel version is 6.11.6 or newer
FAQ
What is CVE-2024-50130?
CVE-2024-50130 is a use-after-free vulnerability in the Linux kernel's netfilter BPF subsystem where network namespace references are not properly retained, leading to memory corruption when BPF programs interact with deallocated namespaces.
Is CVE-2024-50130 being actively exploited?
No, CVE-2024-50130 is not listed on CISA's Known Exploited Vulnerabilities catalog and no public exploits are available. However, the high CVSS score of 7.8 indicates significant risk to local attackers with kernel access.
What versions of Kernel are affected by CVE-2024-50130?
Linux kernel versions 6.7 through 6.11.5 are vulnerable. The fix is available in kernel 6.11.6 and later stable releases.
How do I check if my server is vulnerable to CVE-2024-50130?
Run 'uname -r' and compare your kernel version against the affected range (6.7–6.11.5). If your version falls within this range, your system is vulnerable and requires a kernel update.
Does Defensia detect CVE-2024-50130?
Yes — Defensia's CVE advisory scanner compares installed package versions against the NVD database. If the Linux kernel is installed on a monitored server, CVE-2024-50130 will appear in your dashboard with remediation steps.
Related Kernel CVEs
References
Track CVEs across your fleet automatically
Defensia scans your Linux servers and tells you exactly which ones are running vulnerable versions — including CVE-2024-50130. Free for 1 server.
Get started free