CVE-2024-26812: vfio/pci: Create persistent INTx handler
In the Linux kernel, the following vulnerability has been resolved:
vfio/pci: Create persistent INTx handler
A vulnerability exists where the eventfd for INTx signaling can be deconfigured, which unregisters the IRQ handler but still allows eventfds to be signaled with a NULL context through the SETIRQS ioctl or through unmask irqfd if the device interrupt is pending.
Ideally this could be solved with some additional locking; the igate mutex serializes the ioctl and config space accesses, and the interrupt handler is unregistered relative to the trigger, but the irqfd path runs asynchronous to those. The igate mutex cannot be acquired from the atomic context of the eventfd wake function. Disabling the irqfd relative to the eventfd registration is potentially incompatible with existing userspace.
As a result, the solution implemented here moves configuration of the INTx interrupt handler to track the lifetime of the INTx context object and irqtype configuration, rather than registration of a particular trigger eventfd. Synchronization is added between the ioctl path and eventfdsignal() wrapper such that the eventfd trigger can be dynamically updated relative to in-flight interrupts or irqfd callbacks.
Other sources
In the Linux kernel, the following vulnerability has been resolved:
vfio/pci: Create persistent INTx handler
The Linux kernel CVE team has assigned CVE-2024-26812 to this issue.
Upstream advisory: https://lore.kernel.org/linux-cve-announce/2024040550-CVE-2024-26812-1e08@gregkh/T
— Red Hat
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 - Upgrade
Upgrade
redhat/kernelto a version that resolves this vulnerability.Fixed in 6.1.84 - Upgrade
Upgrade
redhat/kernelto a version that resolves this vulnerability.Fixed in 6.6.24 - Upgrade
Upgrade
redhat/kernelto a version that resolves this vulnerability.Fixed in 6.7.12 - Upgrade
Upgrade
redhat/kernelto a version that resolves this vulnerability.Fixed in 6.8.3 - Upgrade
Upgrade
redhat/kernelto a version that resolves this vulnerability.Fixed in 6.9 - Upgrade
Upgrade to a fixed release to a version that resolves this vulnerability.
Fixed in 5.15.176.3-3 - Upgrade
Upgrade
Linux kernel vfio/pci INTx handlerto a version that resolves this vulnerability.Patch CVE-2024-26812
Event History
Frequently Asked Questions
What is the severity of CVE-2024-26812?
CVE-2024-26812 has been classified as a medium severity vulnerability in the Linux kernel.
How do I fix CVE-2024-26812?
To remediate CVE-2024-26812, update your Linux kernel to versions 6.1.84 or newer, or 5.10.223-1 or newer for Debian systems.
What impact does CVE-2024-26812 have on system security?
CVE-2024-26812 can lead to deregistration of the IRQ handler while allowing signaling, which may result in unexpected behavior or privilege escalation.
Which Linux kernel versions are affected by CVE-2024-26812?
CVE-2024-26812 affects multiple kernel versions prior to 6.1.84, 6.6.24, 6.7.12, 6.8.3, and 6.9.
Is CVE-2024-26812 present in earlier Debian kernels?
Yes, CVE-2024-26812 is present in earlier Debian kernels before the fixed versions 5.10.223-1 and 6.1.123-1.