CVE-2024-38585·Kernel vulnerability
In the Linux kernel, the following vulnerability has been resolved: tools/nolibc/stdlib: fix memory error in realloc() Pass user_p_len to memcpy() instead of heap->len to prevent realloc() from copying an extra sizeof(heap) bytes from beyond the allocated region.
- Severity
- high
- Software
- Kernel
- Fixed in
- 6.9.3
- Published
- 2024-06-19
Affected versions
From: 6.9
Until: 6.9.3
Fixed in: 6.9.3
How to fix this CVE
Update your Linux kernel to version 6.9.3 or later to patch a critical memory handling flaw in the realloc() function. This vulnerability affects the nolibc standard library component and can result in heap memory corruption leading to denial of service or information disclosure. Apply the kernel update through your distribution's package manager and reboot your system to activate the patched kernel.
sudo dnf update kernel kernel-develDefensia detects this vulnerability
How to check if you are affected
- Step 1: Check your current kernel version with `uname -r` and compare against affected range 6.9 to 6.9.2
- Step 2: Verify if nolibc-based applications are compiled and running on your system using `grep -r nolibc /usr/src/linux-* 2>/dev/null || echo 'Checking kernel build config'`
- Step 3: Review kernel logs for memory-related errors using `dmesg | grep -i 'heap\|memory\|corruption\|segfault'`
- Step 4: Confirm the patch by checking kernel version shows 6.9.3 or later with `uname -r` after reboot, and verify git commit 4e6f225aefeb712cdb870176b6621f02cf235b8c is included in your kernel build
FAQ
What is CVE-2024-38585?
CVE-2024-38585 is a heap memory corruption vulnerability in the Linux kernel's nolibc realloc() function that copies incorrect byte counts during memory reallocation, potentially leading to buffer overruns and system instability.
Is CVE-2024-38585 being actively exploited?
No — this vulnerability is not currently listed in the CISA Known Exploited Vulnerabilities catalog and has no public exploits available.
What versions of Kernel are affected by CVE-2024-38585?
Linux kernel versions 6.9 through 6.9.2 are vulnerable; version 6.9.3 and later contain the fix.
How do I check if my server is vulnerable to CVE-2024-38585?
Run `uname -r` and check if the output shows a version between 6.9 and 6.9.2; if so, your system is vulnerable and requires immediate patching.
Does Defensia detect CVE-2024-38585?
Yes — Defensia's CVE advisory scanner compares installed package versions against the NVD database. If the Linux kernel is installed on a monitored server, CVE-2024-38585 will appear in your dashboard with remediation steps.
Related Kernel CVEs
References
- https://git.kernel.org/stable/c/4e6f225aefeb712cdb870176b6621f02cf235b8c
- https://git.kernel.org/stable/c/5996b2b2dac739f2a27da13de8eee5b85b2550b3
- https://git.kernel.org/stable/c/791f4641142e2aced85de082e5783b4fb0b977c2
- https://git.kernel.org/stable/c/8019d3dd921f39a237a9fab6d2ce716bfac0f983
- https://git.kernel.org/stable/c/f678c3c336559cf3255a32153e9a17c1be4e7c15
Track CVEs across your fleet automatically
Defensia scans your Linux servers and tells you exactly which ones are running vulnerable versions — including CVE-2024-38585. Free for 1 server.
Get started free