CVE-2024-58056
📋 TL;DR
This vulnerability in the Linux kernel's remoteproc subsystem causes a kernel warning when ida_free() is called on an unallocated ID during error handling in rproc_alloc(). This affects systems using the remoteproc framework, particularly STM32-based devices, causing potential system instability and denial of service.
💻 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 →⚠️ Risk & Real-World Impact
Worst Case
Kernel panic or system crash due to improper resource cleanup during error conditions in remoteproc initialization.
Likely Case
Kernel warning messages in system logs and potential denial of service for remoteproc-dependent functionality.
If Mitigated
Minor system log warnings with no functional impact if error conditions don't occur.
🎯 Exploit Status
Exploitation requires triggering specific error conditions during remoteproc initialization, making it difficult to weaponize.
🛠️ Fix & Mitigation
✅ Official Fix
Patch Version: Fixed in Linux kernel stable commits: 2cf54928e7e3, 7378aeb664e5, b32d60a852bb, e9efd9fa4679, f2013d19b770
Vendor Advisory: https://git.kernel.org/stable/c/2cf54928e7e32362215c69b68a6a53d110323bf3
Restart Required: Yes
Instructions:
1. Update Linux kernel to version containing the fix commits. 2. For embedded systems: Update kernel via vendor-provided patches or BSP updates. 3. Reboot system after kernel update.
🔧 Temporary Workarounds
Disable remoteproc subsystem
linuxDisable the vulnerable remoteproc subsystem if not needed
echo "blacklist remoteproc" >> /etc/modprobe.d/blacklist.conf
update-initramfs -u
🧯 If You Can't Patch
- Monitor system logs for WARNING messages related to ida_free() calls
- Avoid using or loading remoteproc modules and dependent hardware
🔍 How to Verify
Check if Vulnerable:
Check kernel version and if remoteproc is loaded: lsmod | grep remoteproc && uname -r
Check Version:
uname -r
Verify Fix Applied:
Check if kernel version includes fix commits: git log --oneline | grep -E "(2cf54928e7e3|7378aeb664e5|b32d60a852bb|e9efd9fa4679|f2013d19b770)"
📡 Detection & Monitoring
Log Indicators:
- WARNING: CPU: ... at lib/idr.c:525 ida_free+0x100/0x164
- ida_free called for id=0 which is not allocated
Network Indicators:
- None - this is a local kernel issue
SIEM Query:
source="kernel" AND "ida_free called for id=0"
🔗 References
- https://git.kernel.org/stable/c/2cf54928e7e32362215c69b68a6a53d110323bf3
- https://git.kernel.org/stable/c/7378aeb664e5ebc396950b36a1f2dedf5aabec20
- https://git.kernel.org/stable/c/b32d60a852bb3952886625d0c3b1c9a88c3ceb7c
- https://git.kernel.org/stable/c/e9efd9fa4679803fe23188d7b47119cf7bc2de6f
- https://git.kernel.org/stable/c/f2013d19b7704cd723ab42664b8d9408ea8cc77c
- https://lists.debian.org/debian-lts-announce/2025/03/msg00028.html