CVE-2022-48985 net: mana: Fix race on per-CQ variable napi work_done
A race condition in the Linux kernel's mana network driver can lead to memory corruption and system panic, requiring a kernel patch.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2022-48985?
CVE-2022-48985 is a critical vulnerability in Linux kernel, published on 21 Oct 2024. An attacker can exploit it over the internet without logging in, with no action from the victim.
Official description
In the Linux kernel, the following vulnerability has been resolved:
net: mana: Fix race on per-CQ variable napi work_done
After calling napi_complete_done(), the NAPIF_STATE_SCHED bit may be cleared, and another CPU can start napi thread and access per-CQ variable, cq->work_done. If the other thread (for example, from busy_poll) sets it to a value >= budget, this thread will continue to run when it should stop, and cause memory corruption and panic.
To fix this issue, save the per-CQ work_done variable in a local variable before napi_complete_done(), so it won't be corrupted by a possible concurrent thread after napi_complete_done().
Also, add a flag bit to advertise to the NIC firmware: the NAPI work_done variable race is fixed, so the driver is able to reliably support features like busy_poll.
Which versions are affected by CVE-2022-48985?
It affects 1 product.
Products include Linux kernel.
How do I fix CVE-2022-48985?
Apply the vendor's patch.
Is CVE-2022-48985 being exploited?
There is no known exploitation of CVE-2022-48985 in the wild and no public exploit code.
Other vulnerabilities in Linux kernel
Sources
Also known as DEBIAN-CVE-2022-48985, GHSA-m4qg-9xvx-47wq, UBUNTU-CVE-2022-48985.