CVE-2024-56652: drm/xe/reg_sr: Remove register pool
In the Linux kernel, the following vulnerability has been resolved:
drm/xe/regsr: Remove register pool
That pool implementation doesn't really work: if the krealloc happens to move the memory and return another address, the entries in the xarray become invalid, leading to use-after-free later:
BUG: KASAN: slab-use-after-free in xeregsrapplymmio+0x570/0x760 [xe] Read of size 4 at addr ffff8881244b2590 by task modprobe/2753
Allocated by task 2753: kasansavestack+0x39/0x70 kasansavetrack+0x14/0x40 kasansaveallocinfo+0x37/0x60 kasankmalloc+0xc3/0xd0 kmallocnodetrackcallernoprof+0x200/0x6d0 kreallocnoprof+0x229/0x380
Simplify the code to fix the bug. A better pooling strategy may be added back later if needed.
(cherry picked from commit e5283bd4dfecbd3335f43b62a68e24dae23f59e4)
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.22-1Fixed in 6.12.25-1
Event History
Frequently Asked Questions
What is the severity of CVE-2024-56652?
CVE-2024-56652 has a medium severity rating due to potential use-after-free vulnerabilities in the Linux kernel.
How do I fix CVE-2024-56652?
To fix CVE-2024-56652, update the Linux kernel to version 6.12.6 or later.
Which versions of the Linux kernel are affected by CVE-2024-56652?
CVE-2024-56652 affects Linux kernel versions from 6.8 to 6.12.6, including 6.13-rc1 and 6.13-rc2.
What are the risks associated with CVE-2024-56652?
The risks associated with CVE-2024-56652 include potential system crashes and unauthorized access due to memory management issues.
Is there a workaround for CVE-2024-56652?
There is no known workaround for CVE-2024-56652; updating the kernel is the recommended remediation.