Kernel NULL Pointer Dereference in Linux Package - CVE-2024-46857
Summary
CVE-2024-46857: In the Linux kernel, the following vulnerability has been resolved: net/mlx5: Fix bridge mode operations when there are no VFs Currently, trying to set the bridge mode attribute when numvfs=0 leads to a crash: bridge lin... Affects linux versions 5.10.103-1 – 6.9.9-1. No fix is published. How to fix ↓
Check if this vulnerability affects your application
Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.
No signup required · Results in about 60 seconds
Background
The Linux kernel is the core component of the Linux operating system, responsible for managing hardware and system resources. It provides essential services for all other parts of the operating system. The kernel supports various networking features, including bridging, which allows multiple network interfaces to communicate as if they were a single interface. However, a vulnerability has been identified that affects bridge mode operations when there are no Virtual Functions (VFs) available, leading to potential system crashes.
Vulnerability Detail
The vulnerability, identified as CVE-2024-46857, arises when attempting to set the bridge mode attribute on a network interface (eth2) with no VFs configured. This action results in a kernel NULL pointer dereference, causing a crash. The specific error occurs in the mlx5_add_flow_rules function, where the esw->fdb_table.legacy.vepa_fdb is null. This issue can lead to system instability and unexpected behavior, particularly in environments relying on network bridging functionality.
How To Fix
No fixed version is published for this vulnerability.
Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. Scan free →
Workaround
As a temporary workaround, avoid using the command 'bridge link set dev eth2 hwmode vepa' when there are no VFs configured. This will prevent the kernel from attempting to access null pointers and avoid crashes.
Conclusion
CVE-2024-46857 is a critical vulnerability in the Linux kernel that can lead to system crashes when bridge mode is set without available Virtual Functions. Users are advised to avoid this operation and update their kernel to mitigate the risk. Utilizing tools like Vulert can help monitor and manage vulnerabilities effectively.
See every vulnerability recorded for linux →
FAQ
CVE-2024-46857 is a vulnerability in the Linux kernel that causes a kernel crash when attempting to set bridge mode on a network interface without any Virtual Functions configured.
You can use the Vulert platform to monitor and alert for open-source vulnerabilities in your software. By uploading your manifest file, such as package-lock.json, you can check if your application is affected by CVE-2024-46857.
Virtual Functions (VFs) are lightweight virtualized representations of physical network interfaces, allowing multiple virtual machines to share a single physical network interface while maintaining isolation.
If your system crashes due to this vulnerability, reboot the system and ensure that you do not set the bridge mode on interfaces without VFs. Consider updating the kernel to a version that addresses this issue.
Yes, the permanent fix involves updating the Linux kernel to a version that includes the patch for CVE-2024-46857, which prevents the setting of bridge mode when there are no VFs.
Related vulnerabilities
Recent vulnerabilities recorded for linux.