CVE-2024-45016 netem: fix return value if duplicate enqueue fails
A use-after-free vulnerability in the Linux kernel netem qdisc allows local attackers to potentially execute code or escalate privileges.
- 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-45016?
CVE-2024-45016 is a high-severity use after free vulnerability in Linux kernel, published on 11 Sep 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:
netem: fix return value if duplicate enqueue fails
There is a bug in netem_enqueue() introduced by commit 5845f706388a ("net: netem: fix skb length BUG_ON in __skb_to_sgvec") that can lead to a use-after-free.
This commit made netem_enqueue() always return NET_XMIT_SUCCESS when a packet is duplicated, which can cause the parent qdisc's q.qlen to be mistakenly incremented. When this happens qlen_notify() may be skipped on the parent during destruction, leaving a dangling pointer for some classful qdiscs like DRR.
There are two ways for the bug happen:
- If the duplicated packet is dropped by rootq->enqueue() and then the original packet is also dropped. - If rootq->enqueue() sends the duplicated packet to a different qdisc and the original packet is dropped.
In both cases NET_XMIT_SUCCESS is returned even though no packets are enqueued at the netem qdisc.
The fix is to defer the enqueue of the duplicate packet until after the original packet has been guaranteed to return NET_XMIT_SUCCESS.
Weakness: CWE-416
Which versions are affected by CVE-2024-45016?
It affects 1 product.
Linux distribution packages (1)
kgraft-patch-SLE12-SP5_Update_62 SUSE:Linux Enterprise Live Patching 12 SP5 | All versions | 3-2.1 |
Products include Linux kernel.
How do I fix CVE-2024-45016?
Apply the vendor's patch.
Upgrade to the fixed version. These bugs are found with fuzzing and sanitisers and avoided by memory-safe languages. More about Use after free.
Is CVE-2024-45016 being exploited?
There is no known exploitation of CVE-2024-45016 in the wild and no public exploit code.
Other vulnerabilities in Linux kernel
Sources
Also known as AZL-49211, AZL-49239, BELL-CVE-2024-45016, DEBIAN-CVE-2024-45016, GHSA-q53p-qm4c-c2wj, SUSE-SU-2025:0414-1 and 3 more.