CVE-2024-56549
cachefiles: Fix NULL pointer dereference in object->file
Reported by linux · Published December 27, 2024
In the Linux kernel, the following vulnerability has been resolved: cachefiles: Fix NULL pointer dereference in object->file At present, the object->file has the NULL pointer dereference problem in ondemand-mode. The root cause is that the allocated fd and object->file lifetime are inconsistent, and the user-space invocation to anon_fd uses object->file. Following is the process that triggers the issue: [write fd] [umount] cachefiles_ondemand_fd_write_iter fscache_cookie_state_machine cachefiles_withdraw_cookie if (!file) return -ENOBUFS cachefiles_clean_up_object cachefiles_unmark_inode_in_use fput(object->file) object->file = NULL // file NULL pointer dereference! __cachefiles_write(..., file, ...) Fix this issue by add an additional reference count to the object->file before write/llseek, and decrement after it finished.
Fixed versions
Upgrade to a fixed version or later. Language registries are listed first, then Linux distributions, then vendor products.
| Package | Ecosystem | Fixed in |
|---|---|---|
| perf | Amazon Linux | 6.1.131-143.221.amzn2023 |
| kernel-tools | Amazon Linux | 6.1.131-143.221.amzn2023 |
| kernel-modules-extra | Amazon Linux | 6.1.131-143.221.amzn2023 |
| kernel | Amazon Linux | 6.1.131-143.221.amzn2023 |
| kernel-modules-extra-common | Amazon Linux | 6.1.131-143.221.amzn2023 |
| python3-perf | Amazon Linux | 6.1.131-143.221.amzn2023 |
| kernel-devel | Amazon Linux | 6.1.131-143.221.amzn2023 |
| kernel-libbpf-static | Amazon Linux | 6.1.131-143.221.amzn2023 |
| kernel-libbpf-devel | Amazon Linux | 6.1.131-143.221.amzn2023 |
| kernel-livepatch-6.1.131-143.221 | Amazon Linux | 1.0-0.amzn2023 |
| kernel-tools-devel | Amazon Linux | 6.1.131-143.221.amzn2023 |
| linux_kernel | linux | 6.12.2, 6.11.11 |
1 more packages have a fixed version. See every fix in Lookup.
Risk scores
Affected products
| Vendor | Product | Versions |
|---|---|---|
| Linux | Linux | c8383054506c77b814489c09877b5db83fd4abf2, c8383054506c77b814489c09877b5db83fd4abf2, c8383054506c77b814489c09877b5db83fd4abf2 |
| Linux | Linux | 5.19, 0, 6.1.129 |
| amazon:2023 | perf | 0 |
| amazon:2023 | kernel-tools | 0 |
| amazon:2023 | kernel-modules-extra | 0 |
| amazon:2023 | kernel | 0 |
| amazon:2023 | kernel-modules-extra-common | 0 |
| amazon:2023 | python3-perf | 0 |
| amazon:2023 | kernel-devel | 0 |
| amazon:2023 | kernel-libbpf-static | 0 |
| amazon:2023 | kernel-libbpf-devel | 0 |
| amazon:2023 | kernel-livepatch-6.1.131-143.221 | 0 |
| amazon:2023 | kernel-tools-devel | 0 |
| Linux | Linux | *, 0, 6.1.129 |
| amazon:2023 | kernel-headers | 0 |
| linux | linux_kernel | 5.19, 5.19, 5.19 |
| amazon:2023 | bpftool | 0 |
| amazon:2023 | kernel-libbpf | 0 |
Timeline
- Dec 27, 2024 CVE Published
- Dec 28, 2024 EPSS Score (30 in total, the first dated here)
- Jan 20, 2025 Coalition ESS Score (8 in total, the first dated here)
- Dec 16, 2025 PoC Published
- Dec 30, 2025 Security Advisory (450 in total, the first dated here)
- Dec 30, 2025 CVE Updated
- Apr 29, 2026 Distribution Patch (367 in total, the first dated here)
Query this with the API
The same record, from the CLI:
vulnetix vdb vuln CVE-2024-56549
vulnetix vdb fixes CVE-2024-56549
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-56549/fixes/registry"
The Community plan is free and allows 50 queries a day. Get a free API key · API quickstart