CVE-2024-42108: net: rswitch: Avoid use-after-free in rswitch_poll()
In the Linux kernel, the following vulnerability has been resolved:
net: rswitch: Avoid use-after-free in rswitchpoll()
The use-after-free is actually in rswitchtxfree(), which is inlined in rswitchpoll(). Since skb and gq->skbs[gq->dirty] are in fact the same pointer, the skb is first freed using devkfreeskbany(), then the value in skb->len is used to update the interface statistics.
Let's move around the instructions to use skb->len before the skb is freed.
This bug is trivial to reproduce using KFENCE. It will trigger a splat every few packets. A simple ARP request or ICMP echo request is enough.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
debian/linuxto a version that resolves this vulnerability.Fixed in 5.10.223-1Fixed in 5.10.234-1Fixed in 6.1.129-1Fixed in 6.1.135-1Fixed in 6.12.25-1Fixed in 6.12.27-1
Event History
Frequently Asked Questions
What is the severity of CVE-2024-42108?
CVE-2024-42108 is classified as a high-severity vulnerability due to the potential for use-after-free exploits.
How do I fix CVE-2024-42108?
To fix CVE-2024-42108, update your Linux kernel to at least version 5.10.223-1 or any later patched version.
Which systems are affected by CVE-2024-42108?
CVE-2024-42108 affects various versions of the Linux kernel, specifically between 6.8 and 6.9.9.
What could happen if CVE-2024-42108 is exploited?
If exploited, CVE-2024-42108 could lead to system crashes or potentially allow for remote code execution.
Is there a specific package version to address CVE-2024-42108?
Yes, users should upgrade to linux package versions 5.10.223-1 or 5.10.226-1 or higher to mitigate the risk.