CVE-2024-56669: iommu/vt-d: Remove cache tags before disabling ATS
In the Linux kernel, the following vulnerability has been resolved:
iommu/vt-d: Remove cache tags before disabling ATS
The current implementation removes cache tags after disabling ATS, leading to potential memory leaks and kernel crashes. Specifically, CACHETAGDEVTLB type cache tags may still remain in the list even after the domain is freed, causing a use-after-free condition.
This issue really shows up when multiple VFs from different PFs passed through to a single user-space process via vfio-pci. In such cases, the kernel may crash with kernel messages like:
BUG: kernel NULL pointer dereference, address: 0000000000000014 PGD 19036a067 P4D 1940a3067 PUD 136c9b067 PMD 0 Oops: Oops: 0000 [#1] PREEMPT SMP NOPTI CPU: 74 UID: 0 PID: 3183 Comm: testCli Not tainted 6.11.9 #2 RIP: 0010:cachetagflushrange+0x9b/0x250 Call Trace: <TASK> ? die+0x1f/0x60 ? pagefaultoops+0x163/0x590 ? excpagefault+0x72/0x190 ? asmexcpagefault+0x22/0x30 ? cachetagflushrange+0x9b/0x250 ? cachetagflushrange+0x5d/0x250 inteliommutlbsync+0x29/0x40 inteliommuunmappages+0xfe/0x160 iommuunmap+0xd8/0x1a0 vfiounmapunpin+0x182/0x340 [vfioiommutype1] vfioremovedma+0x2a/0xb0 [vfioiommutype1] vfioiommutype1ioctl+0xafa/0x18e0 [vfioiommutype1]
Move cachetagunassigndomain() before iommudisablepcicaps() to fix it.
Other sources
This CVE was automatically created from a reference found in an email or other text. If you are reading this, then this CVE entry is probably erroneous, since this text should be replaced by the official CVE description automatically.
— Launchpad
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.27-1
Event History
Frequently Asked Questions
What is the severity of CVE-2024-56669?
CVE-2024-56669 is classified with a high severity due to potential memory leaks and kernel crashes.
How do I fix CVE-2024-56669?
To fix CVE-2024-56669, update the Linux kernel to the latest version beyond 6.12.6 or apply the relevant patches provided.
What versions of the Linux kernel are affected by CVE-2024-56669?
CVE-2024-56669 affects Linux kernel versions from 6.10 to 6.12.6 and includes 6.13-rc1 and 6.13-rc2.
What are the potential impacts of CVE-2024-56669?
The potential impacts of CVE-2024-56669 include memory leaks and potential kernel crashes, which can disrupt system stability.
Is CVE-2024-56669 remotely exploitable?
CVE-2024-56669 is not considered remotely exploitable as it affects local kernel operations.