CVE-2024-34777
📋 TL;DR
A memory corruption vulnerability in the Linux kernel's DMA mapping benchmark module allows local attackers to trigger a wild memory access via invalid node ID validation. This affects systems with the map_benchmark debugfs interface enabled, potentially leading to kernel crashes or privilege escalation. Only users with local access to the debugfs interface are affected.
💻 Affected Systems
- Linux kernel
📦 What is this software?
Linux Kernel by Linux
The Linux Kernel is the core component of the Linux operating system, serving as the critical interface between computer hardware and software processes. As the heart of millions of servers, cloud infrastructure, embedded systems, Android devices, and IoT deployments worldwide, the Linux Kernel mana...
Learn more about Linux Kernel →Linux Kernel by Linux
The Linux Kernel is the core component of the Linux operating system, serving as the critical interface between computer hardware and software processes. As the heart of millions of servers, cloud infrastructure, embedded systems, Android devices, and IoT deployments worldwide, the Linux Kernel mana...
Learn more about Linux Kernel →Linux Kernel by Linux
The Linux Kernel is the core component of the Linux operating system, serving as the critical interface between computer hardware and software processes. As the heart of millions of servers, cloud infrastructure, embedded systems, Android devices, and IoT deployments worldwide, the Linux Kernel mana...
Learn more about Linux Kernel →Linux Kernel by Linux
The Linux Kernel is the core component of the Linux operating system, serving as the critical interface between computer hardware and software processes. As the heart of millions of servers, cloud infrastructure, embedded systems, Android devices, and IoT deployments worldwide, the Linux Kernel mana...
Learn more about Linux Kernel →Linux Kernel by Linux
The Linux Kernel is the core component of the Linux operating system, serving as the critical interface between computer hardware and software processes. As the heart of millions of servers, cloud infrastructure, embedded systems, Android devices, and IoT deployments worldwide, the Linux Kernel mana...
Learn more about Linux Kernel →⚠️ Risk & Real-World Impact
Worst Case
Local privilege escalation to kernel-level code execution leading to full system compromise.
Likely Case
Kernel panic or system crash causing denial of service.
If Mitigated
No impact if debugfs interface is disabled or access restricted.
🎯 Exploit Status
Requires local access and ability to interact with debugfs interface. No public exploits known.
🛠️ Fix & Mitigation
✅ Official Fix
Patch Version: Fixed in kernel commits: 1ff05e723f7ca30644b8ec3fb093f16312e408ad and related stable backports
Vendor Advisory: https://git.kernel.org/stable/c/1ff05e723f7ca30644b8ec3fb093f16312e408ad
Restart Required: Yes
Instructions:
1. Update to patched kernel version from your distribution vendor. 2. Reboot system. 3. Verify kernel version after reboot.
🔧 Temporary Workarounds
Disable DMA debug interface
linuxRemove debugfs access to map_benchmark interface
rmmod map_benchmark
echo 'blacklist map_benchmark' > /etc/modprobe.d/disable-map-benchmark.conf
Restrict debugfs access
linuxMount debugfs with restricted permissions
mount -t debugfs -o mode=0750,uid=0,gid=0 debugfs /sys/kernel/debug
🧯 If You Can't Patch
- Disable CONFIG_DMA_API_DEBUG_SG kernel configuration option and rebuild kernel
- Implement strict access controls to /sys/kernel/debug/dma directory
🔍 How to Verify
Check if Vulnerable:
Check if /sys/kernel/debug/dma/map_benchmark exists and kernel version is unpatched
Check Version:
uname -r
Verify Fix Applied:
Verify kernel version includes fix commits or /sys/kernel/debug/dma/map_benchmark no longer accessible
📡 Detection & Monitoring
Log Indicators:
- Kernel panic messages
- KASAN reports for wild-memory-access in map_benchmark_ioctl
- dma_map_benchma process crashes
Network Indicators:
- None - local-only vulnerability
SIEM Query:
process.name:dma_map_benchma AND event.outcome:failure
🔗 References
- https://git.kernel.org/stable/c/1ff05e723f7ca30644b8ec3fb093f16312e408ad
- https://git.kernel.org/stable/c/34a816d8735f3924b74be8e5bf766ade1f3bd10b
- https://git.kernel.org/stable/c/35d31c8bd4722b107f5a2f5ddddce839de04b936
- https://git.kernel.org/stable/c/63e7e05a48a35308aeddd7ecccb68363a5988e87
- https://git.kernel.org/stable/c/c57874265a3c5206d7aece3793bb2fc9abcd7570
- https://git.kernel.org/stable/c/1ff05e723f7ca30644b8ec3fb093f16312e408ad
- https://git.kernel.org/stable/c/34a816d8735f3924b74be8e5bf766ade1f3bd10b
- https://git.kernel.org/stable/c/35d31c8bd4722b107f5a2f5ddddce839de04b936
- https://git.kernel.org/stable/c/63e7e05a48a35308aeddd7ecccb68363a5988e87
- https://git.kernel.org/stable/c/c57874265a3c5206d7aece3793bb2fc9abcd7570