CVE-2022-48790·Kernel vulnerability
In the Linux kernel, the following vulnerability has been resolved: nvme: fix a possible use-after-free in controller reset during load Unlike .queue_rq, in .submit_async_event drivers may not check the ctrl readiness for AER submission. This may lead to a use-after-free condition that was observed with nvme-tcp. The race condition may happen in the following scenario: 1. driver executes its reset_ctrl_work 2. -> nvme_stop_ctrl - flushes ctrl async_event_work 3. ctrl sends AEN which is received by the host, which in turn schedules AEN handling 4. teardown admin queue (which releases the queue socket) 5. AEN processed, submits another AER, calling the driver to submit 6. driver attempts to send the cmd ==> use-after-free In order to fix that, add ctrl state check to validate the ctrl is actually able to accept the AER submission. This addresses the above race in controller resets because the driver during teardown should: 1. change ctrl state to RESETTING 2. flush async_event_work (as well as other async work elements) So after 1,2, any other AER command will find the ctrl state to be RESETTING and bail out without submitting the AER.
- Severity
- high
- Software
- Kernel
- Fixed in
- 5.16.11
- Published
- 2024-07-16
Affected versions
From: 5.16
Until: 5.16.11
Fixed in: 5.16.11
How to fix this CVE
Update your Linux kernel to version 5.16.11 or later to resolve a use-after-free condition in NVMe controller reset handling. This vulnerability occurs when asynchronous event requests (AER) are submitted during controller teardown, potentially causing memory corruption or system instability. Apply the patch immediately through your distribution's package manager to prevent exploitation during kernel operations.
sudo dnf update kernel kernel-develDefensia detects this vulnerability
How to check if you are affected
- Check your current kernel version: uname -r
- Verify if NVMe devices are present: lspci | grep -i nvme or nvme list
- Examine kernel logs for NVMe errors during controller resets: dmesg | grep -i 'nvme.*reset\|use.after.free'
- Confirm kernel update was applied: uname -r should show version 5.16.11 or later
FAQ
What is CVE-2022-48790?
This vulnerability is a use-after-free condition in the Linux NVMe driver that occurs when asynchronous event requests are processed after the admin queue has been released during controller reset, potentially leading to kernel memory corruption.
Is CVE-2022-48790 being actively exploited?
No, this vulnerability is not listed in the CISA Known Exploited Vulnerabilities (KEV) catalog and no public exploits are available. However, it poses a local denial-of-service risk to systems with NVMe storage.
What versions of Kernel are affected by CVE-2022-48790?
Linux kernel versions 5.16 through 5.16.10 are vulnerable. The fix is included in kernel 5.16.11 and all subsequent releases.
How do I check if my server is vulnerable to CVE-2022-48790?
Run 'uname -r' and check if the output is between 5.16 and 5.16.10. If your version is 5.16.11 or higher, you are patched. Additionally, verify NVMe presence with 'nvme list'.
Does Defensia detect CVE-2022-48790?
Yes — Defensia's CVE advisory scanner compares installed package versions against the NVD database. If the Linux kernel is installed on a monitored server, CVE-2022-48790 will appear in your dashboard with remediation steps.
Related Kernel CVEs
References
- https://git.kernel.org/stable/c/0ead57ceb21bbf15963b4874c2ac67143455382f
- https://git.kernel.org/stable/c/0fa0f99fc84e41057cbdd2efbfe91c6b2f47dd9d
- https://git.kernel.org/stable/c/70356b756a58704e5c8818cb09da5854af87e765
- https://git.kernel.org/stable/c/9e956a2596ae276124ef0d96829c013dd0faf861
- https://git.kernel.org/stable/c/a25e460fbb0340488d119fb2e28fe3f829b7417e
Track CVEs across your fleet automatically
Defensia scans your Linux servers and tells you exactly which ones are running vulnerable versions — including CVE-2022-48790. Free for 1 server.
Get started free