Linux kernel patches fanotify, TCP-AO, and Btrfs flaws including 17-year-old bug
Vulnerability Disclosure · 11 sources · Updated 4mo ago · First seen Oct 28, 2025

Upstream Linux kernel maintainers patched three vulnerabilities reported by researchers, including two NULL pointer dereferences reachable by unprivileged users and a long-standing Btrfs memory corruption issue. CVE-2025-40072 affects fanotify mount-namespace monitoring introduced in Linux 6.16, where do_fanotify_mark() dereferenced the return value of mnt_ns_from_dentry() without verifying it was non-NULL, allowing a kernel crash and denial of service; the fix landed in 6.17.3 and 6.18-rc1. CVE-2025-39950 affects the TCP stack when TCP-AO is combined with TCP_REPAIR, causing tcp_ao_finish_connect() to dereference a NULL skb during connect() and crash the kernel.
A third fix, CVE-2025-40205, addresses a potential 8-byte out-of-bounds write in Btrfs btrfs_encode_fh() that could occur when parent and inode root IDs differ and the function reports a smaller buffer requirement than it later writes. Kernel discussions said the flaw had effectively persisted for about 17 years, with an earlier latent memory-corruption concern in the same area dating back to 2010; the final patch corrected size calculations, added bounds validation, and was marked for stable kernels back to 3.0+. Researchers said the Btrfs issue may be difficult to trigger in practice, but all three bugs were fixed upstream and highlighted as kernel stability and memory-safety risks.
Why it matters
Impact assessment
These flaws affect Linux systems running vulnerable upstream kernel versions, especially environments that expose unprivileged local user access, use fanotify namespace monitoring, enable TCP-AO with TCP_REPAIR, or rely on Btrfs. The immediate impact is primarily local denial of service through kernel crashes for CVE-2025-40072 and CVE-2025-39950, while CVE-2025-40205 introduces a memory-safety risk with potential kernel memory corruption in Btrfs.
The exposure is broad for Linux operators but practical exploitability varies by feature usage and kernel version. No reference reports confirmed exploitation in the wild; however, the bugs are reachable by unprivileged users in at least the fanotify and TCP cases, which raises multi-user host and container-host risk.
Affected populations
- Linux administrators and platform teams running upstream or downstream kernels derived from affected branches
- Multi-user Linux servers, shared compute environments, CI/CD runners, academic clusters, and container hosts where unprivileged local users may execute code
- Network infrastructure or appliances using Linux TCP-AO for authenticated TCP sessions such as BGP-related use cases
- Systems using Btrfs, particularly where exportfs/file-handle operations are exercised
Severity and business effect
- CVE-2025-40072: local kernel crash/denial of service via fanotify mount-namespace handling
- CVE-2025-39950: local kernel crash/denial of service via TCP-AO plus TCP_REPAIR during connect()
- CVE-2025-40205: potential kernel memory corruption from an 8-byte out-of-bounds write in Btrfs
- Likely operational impact: host instability, service interruption, node recycling, and possible cascading effects in clustered/containerized environments
- No direct evidence in the references of data theft or remote code execution
Scope and exploitation status
- Scope is widespread at the ecosystem level because Linux is broadly deployed, but practical exposure depends on enabled kernel features and filesystem choice
- CVE-2025-40072 affects kernels starting in 6.16
- CVE-2025-40205 persisted since Linux 2.6.29 and was marked for stable backports across many maintained branches
- No published in-the-wild exploitation is cited in the provided references


