Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2024-49889 Overview
CVE-2024-49889 is a use-after-free vulnerability [CWE-416] in the Linux kernel's ext4 filesystem code. The flaw resides in ext4_ext_show_leaf(), where a previously saved extent path pointer may be freed or reallocated by ext4_find_extent() before being dereferenced. The issue only triggers when the kernel is built with EXT_DEBUG defined, which limits exposure in production builds but still affects debug-enabled distributions and vendor kernels.
Critical Impact
A local authenticated attacker triggering ext4 extent operations on a kernel compiled with EXT_DEBUG can cause memory corruption, potentially leading to privilege escalation or kernel crash.
Affected Products
- Linux Kernel (multiple stable branches prior to the fix commits)
- Debian GNU/Linux (addressed in Debian LTS January and March 2025 advisories)
- Siemens industrial products referenced in advisories SSA-265688 and SSA-355557
Discovery Timeline
- 2024-10-21 - CVE-2024-49889 published to the National Vulnerability Database
- 2026-10-15 - Last updated in NVD database
Technical Details for CVE-2024-49889
Vulnerability Analysis
The vulnerability occurs in the ext4 extent tree handling path. During ext4_split_extent(), the kernel caches the extent path pointer path = *ppath before calling ext4_split_extent_at(ppath). The nested call invokes ext4_find_extent(ppath), which may free or reallocate the path buffer on error or during tree rebalancing.
After the split operation, the kernel passes the stale cached path to ext4_ext_show_leaf(). That function dereferences path[depth].p_hdr, reading from memory that has already been released. The same unsafe pattern exists in ext4_ext_handle_unwritten_extents().
The condition only materializes when EXT_DEBUG is enabled at kernel build time, because ext4_ext_show_leaf() is a debug-only tracing helper. Distributions shipping debug-instrumented kernels and specialized builds are directly exposed.
Root Cause
The root cause is incorrect pointer lifetime management across function boundaries in the ext4 extent code. Callers retained a copy of *ppath while nested routines were permitted to free or reallocate the underlying buffer, violating the invariant that only the current *ppath dereference is valid after helpers return.
Attack Vector
Exploitation requires local access with privileges sufficient to perform filesystem operations that drive ext4 extent splits, such as writing to or truncating files on an ext4 volume. The attack vector is local with low complexity and low privileges required. Successful exploitation yields high confidentiality, integrity, and availability impact against the kernel. No public proof-of-concept is listed, and the CVE is not present on the CISA Known Exploited Vulnerabilities catalog.
The upstream fix removes the stale path local variable and passes *ppath directly to ext4_ext_show_leaf() and ext4_ext_handle_unwritten_extents(). See the Kernel Commit 4e2524b for the authoritative patch.
Detection Methods for CVE-2024-49889
Indicators of Compromise
- Unexpected kernel oops or panic messages referencing ext4_ext_show_leaf, ext4_split_extent, or ext4_ext_handle_unwritten_extents in dmesg or /var/log/kern.log.
- KASAN reports flagging use-after-free in the ext4 extent code path on debug-enabled kernels.
- Repeated process crashes from unprivileged users performing heavy ext4 write, truncate, or fallocate activity.
Detection Strategies
- Inventory running kernels and identify builds compiled with CONFIG_EXT4_DEBUG or EXT_DEBUG enabled, which are the exposed configurations.
- Compare installed kernel package versions against vendor advisories, including the Debian LTS Announcement January 2025 and Debian LTS Announcement March 2025.
- Correlate kernel crash telemetry with ext4-heavy workloads to surface attempted triggers.
Monitoring Recommendations
- Forward kernel ring buffer and syslog data to a centralized analytics platform and alert on ext4 subsystem faults.
- Track filesystem syscalls from non-root users on multi-tenant hosts, particularly repeated truncate, fallocate, and large-file write patterns.
- Monitor process termination and OOM events on servers running debug or vendor-instrumented kernels.
How to Mitigate CVE-2024-49889
Immediate Actions Required
- Apply the vendor-supplied kernel update that incorporates the upstream fix commits, then reboot into the patched kernel.
- Audit custom and embedded kernel builds and disable CONFIG_EXT4_DEBUG unless actively required for development.
- Restrict local shell and filesystem write access on multi-tenant systems until patches are deployed.
Patch Information
The fix is distributed across stable kernel branches in the following commits: Kernel Commit 2eba3b0, Kernel Commit 34b2096, Kernel Commit 4999fed, Kernel Commit 4e2524b, Kernel Commit 8b114f2, Kernel Commit b0cb456, and Kernel Commit d483c7c. Industrial operators should review the Siemens Security Advisory SSA-265688 and Siemens Security Advisory SSA-355557 for product-specific guidance.
Workarounds
- Rebuild affected kernels with CONFIG_EXT4_DEBUG disabled to eliminate the vulnerable code path.
- Limit untrusted local accounts and container workloads from issuing extent-splitting operations on ext4 volumes.
- Where feasible, migrate critical workloads to patched hosts until the vulnerable kernels are retired.
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

