CVE-2021-47278·Kernel vulnerability
In the Linux kernel, the following vulnerability has been resolved: bus: mhi: pci_generic: Fix possible use-after-free in mhi_pci_remove() This driver's remove path calls del_timer(). However, that function does not wait until the timer handler finishes. This means that the timer handler may still be running after the driver's remove function has finished, which would result in a use-after-free. Fix by calling del_timer_sync(), which makes sure the timer handler has finished, and unable to re-schedule itself.
- Severity
- high
- Software
- Kernel
- Fixed in
- 5.12.11
- Published
- 2024-05-21
Affected versions
From: 5.12
Until: 5.12.11
Fixed in: 5.12.11
How to fix this CVE
Update your Linux kernel to version 5.12.11 or later to resolve a use-after-free vulnerability in the MHI PCI driver's removal routine. The vulnerability occurs when the timer cleanup function completes before its handler finishes execution, potentially causing memory corruption. Apply the kernel update through your distribution's package manager and reboot to activate the patched kernel.
sudo dnf update kernel kernel-devel && sudo rebootDefensia detects this vulnerability
How to check if you are affected
- Check your current kernel version with: uname -r | grep -E '^5\.12\.[0-9]+'
- Verify MHI PCI driver is loaded by running: lsmod | grep mhi_pci
- Search kernel logs for driver removal events and crashes: sudo journalctl -u kernel | grep -i 'mhi\|pci.*remove'
- Confirm patch application by checking if del_timer_sync is used in the driver: sudo strings /boot/vmlinuz-$(uname -r) | grep -i 'del_timer'
FAQ
What is CVE-2021-47278?
This vulnerability is a use-after-free flaw in the Linux kernel's MHI PCI generic driver that occurs during device removal, where the timer handler may execute after the driver cleanup completes, leading to memory corruption or system instability.
Is CVE-2021-47278 being actively exploited?
No, this vulnerability is not listed on the CISA Known Exploited Vulnerabilities catalog and no public exploits are currently available.
What versions of Kernel are affected by CVE-2021-47278?
Linux kernel versions 5.12 through 5.12.10 are vulnerable; the fix is included in kernel 5.12.11 and all subsequent releases.
How do I check if my server is vulnerable to CVE-2021-47278?
Run 'uname -r' to display your kernel version and check if it falls within the 5.12.0 to 5.12.10 range; if so, your system requires patching.
Does Defensia detect CVE-2021-47278?
Yes — Defensia's CVE advisory scanner compares installed package versions against the NVD database. If Kernel is installed on a monitored server, CVE-2021-47278 will appear in your dashboard with remediation steps.
Related Kernel CVEs
References
Track CVEs across your fleet automatically
Defensia scans your Linux servers and tells you exactly which ones are running vulnerable versions — including CVE-2021-47278. Free for 1 server.
Get started free