VDB

CVE-2024-49881

CVE-2024-49881 PUBLISHED

ext4: update orig_path in ext4_find_extent()

Reported by linux · Published October 21, 2024

In the Linux kernel, the following vulnerability has been resolved: ext4: update orig_path in ext4_find_extent() In ext4_find_extent(), if the path is not big enough, we free it and set *orig_path to NULL. But after reallocating and successfully initializing the path, we don't update *orig_path, in which case the caller gets a valid path but a NULL ppath, and this may cause a NULL pointer dereference or a path memory leak. For example: ext4_split_extent path = *ppath = 2000 ext4_find_extent if (depth > path[0].p_maxdepth) kfree(path = 2000); *orig_path = path = NULL; path = kcalloc() = 3000 ext4_split_extent_at(*ppath = NULL) path = *ppath; ex = path[depth].p_ext; // NULL pointer dereference! ================================================================== BUG: kernel NULL pointer dereference, address: 0000000000000010 CPU: 6 UID: 0 PID: 576 Comm: fsstress Not tainted 6.11.0-rc2-dirty #847 RIP: 0010:ext4_split_extent_at+0x6d/0x560 Call Trace: <TASK> ext4_split_extent.isra.0+0xcb/0x1b0 ext4_ext_convert_to_initialized+0x168/0x6c0 ext4_ext_handle_unwritten_extents+0x325/0x4d0 ext4_ext_map_blocks+0x520/0xdb0 ext4_map_blocks+0x2b0/0x690 ext4_iomap_begin+0x20e/0x2c0 [...] ================================================================== Therefore, *orig_path is updated when the extent lookup succeeds, so that the caller can safely use path or *ppath.

Fixed versions

Upgrade to a fixed version or later. Language registries are listed first, then Linux distributions, then vendor products.

PackageEcosystemFixed in
kernel-libbpf-develAmazon Linux6.1.115-126.197.amzn2023
kernel-tools-develAmazon Linux6.1.115-126.197.amzn2023
kernel-develAmazon Linux6.1.115-126.197.amzn2023
kernel-libbpfAmazon Linux6.1.115-126.197.amzn2023
kernelAmazon Linux6.1.115-126.197.amzn2023
kernel-libbpf-staticAmazon Linux6.1.115-126.197.amzn2023
kernel-modules-extraAmazon Linux6.1.115-126.197.amzn2023
SIMATIC S7-1500 CPU 1518-4 PN/DP MFPSiemens3.1.5
linux_kernellinux6.11.3, 6.10.14, 6.6.55, 6.1.113, 5.15.168, 5.10.227
SCALANCE XC-300/XR-300/XC-400/XR-500WG/XR-500 familySiemens3.2
RUGGEDCOM RST2428PSiemens3.2

Affected products

VendorProductVersions
LinuxLinux10809df84a4d868db61af621bae3658494165279, 10809df84a4d868db61af621bae3658494165279, 10809df84a4d868db61af621bae3658494165279
LinuxLinux3.18, 0, 4.19.323
SiemensSIMATIC S7-1500 CPU 1518-4 PN/DP MFP3.1.0
amazon:2023kernel-libbpf-devel0
amazon:2023kernel-tools-devel0
SiemensSCALANCE XC-300/XR-300/XC-400/XR-500WG/XR-500 family0
amazon:2023kernel-devel0
SiemensRUGGEDCOM RST2428P0
amazon:2023kernel-libbpf0
amazon:2023kernel0
amazon:2023kernel-libbpf-static0
amazon:2023kernel-modules-extra0
linuxlinux_kernel3.18, 3.18, 3.18
amazon:2023kernel-tools0
amazon:2023perf0
SiemensSIPLUS S7-1500 CPU 1518-4 PN/DP MFP3.1.0
amazon:2023kernel-livepatch-6.1.115-126.1970
amazon:2023kernel-headers0
LinuxLinux6.6.55, 10809df84a4d868db61af621bae3658494165279, 5.15.168
amazon:2023bpftool0

…and 4 more

Timeline

  • Oct 21, 2024 CVE Published
  • Oct 22, 2024 EPSS Score (30 in total, the first dated here)
  • Oct 23, 2024 Coalition ESS Score (11 in total, the first dated here)
  • Dec 5, 2025 CVE Updated
  • Dec 16, 2025 PoC Published
  • Jan 2, 2026 Security Advisory (449 in total, the first dated here)
  • Mar 30, 2026 Distribution Patch (381 in total, the first dated here)

Query this with the API

The same record, from the CLI:

vulnetix vdb vuln CVE-2024-49881
vulnetix vdb fixes CVE-2024-49881

Or with curl, using the org id and key from your account page:

curl -s -H "Authorization: ApiKey ${VULNETIX_ORG_ID}:${VULNETIX_API_KEY}" \
  "https://api.vdb.vulnetix.com/v2/vuln/CVE-2024-49881/fixes/registry"

The Community plan is free and allows 50 queries a day. Get a free API key · API quickstart

Look up in the Resolve Platform →
$ Lookup Community · 50/day Open Lookup ›