
Cloud Vulnerability DB
A community-led vulnerabilities database
In the Linux kernel, a memory leak vulnerability (CVE-2021-47519) was discovered in the m_can_read_fifo function. The issue occurs when the second call to m_can_fifo_read() fails, causing the function to jump to the out_fail label and return without calling m_can_receive_skb(). As a result, the skb previously allocated by alloc_can_skb() is not freed, leading to a memory leak. The vulnerability was discovered using GCC -fanalyzer (Kernel Patch).
The vulnerability exists in the Linux kernel's CAN (Controller Area Network) subsystem, specifically in the m_can driver. The issue stems from improper memory management in the error handling path of the m_can_read_fifo function. When an error occurs during the second m_can_fifo_read() call, the function jumps to the out_fail label without properly freeing the previously allocated socket buffer (skb). The CVSS v3.1 base score is 5.5 (Medium) with vector: CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H (NVD).
The vulnerability results in a memory leak, which can lead to gradual system memory depletion over time. While this doesn't present an immediate security risk in terms of data exposure or system compromise, it can potentially cause system performance degradation or denial of service if the leak occurs frequently enough to exhaust available system memory (NVD).
The vulnerability requires local access with low privileges to exploit. The attack complexity is low, and no user interaction is required. However, the impact is limited to availability (memory resources) with no direct impact on confidentiality or integrity (NVD).
The vulnerability has been patched by adding a new goto label (out_free_skb) to properly free the skb in the error path. The fix ensures that kfree_skb(skb) is called before returning from the function when an error occurs. The patch has been merged into the Linux kernel (Kernel Patch).
Source: This report was generated using AI
Free Vulnerability Assessment
Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.
Get a personalized demo
"Best User Experience I have ever seen, provides full visibility to cloud workloads."
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
"We know that if Wiz identifies something as critical, it actually is."