CVE-2026-64027 Overview
CVE-2026-64027 is a use-after-free vulnerability in the Linux kernel's network shaper subsystem (net/shaper). The flaw stems from a race condition in the recently reworked VALID marking logic. XArray marks are not stored atomically with their corresponding entries, allowing a reader to observe a VALID mark for a slot, get preempted, and then read a different pointer after a writer replaces the entry. The net_shaper_rollback() function assumed entries without the VALID mark could be freed without observing Read-Copy-Update (RCU) grace periods, leading to memory corruption.
Critical Impact
A local, low-privileged attacker can trigger a use-after-free (UAF) condition in the kernel, potentially resulting in privilege escalation, kernel memory disclosure, or denial of service.
Affected Products
- Linux kernel versions containing the reworked net/shaper VALID marking logic
- Distributions shipping the affected upstream commit prior to the fix
- Systems using network traffic shaping via the shaper subsystem
Discovery Timeline
- 2026-07-19 - CVE-2026-64027 published to NVD
- 2026-07-20 - Last updated in NVD database
Technical Details for CVE-2026-64027
Vulnerability Analysis
The vulnerability resides in the Linux kernel net/shaper subsystem, which manages network traffic shaping entries stored in an XArray data structure. A prior commit changed the semantics of entry flags from NOT_VALID to VALID, but the flags are not stored atomically alongside the XArray entry itself.
This introduces a time-of-check to time-of-use (TOCTOU) race window. A reader thread can observe the VALID mark on a slot, then be interrupted before dereferencing the pointer. During this window, a writer thread can replace the entry with a different object. When the reader resumes, it fetches a pointer that no longer corresponds to the object for which VALID was originally observed.
The upstream fix removes reliance on XArray marks entirely and replaces them with an explicit valid field guarded by smp_load_acquire() and smp_store_release() memory barriers, ensuring correct ordering between the flag and the entry pointer.
Root Cause
The root cause is a non-atomic pairing between XArray entry pointers and their associated marks. The net_shaper_rollback() code path assumed that entries lacking the VALID mark could be safely freed without waiting for an RCU grace period. Because concurrent readers can hold stale references to freed entries, this assumption leads to a use-after-free condition [CWE-416].
Attack Vector
Exploitation requires local access with the ability to invoke network shaper operations. An attacker races two operations against the shaper XArray to trigger the pointer replacement window. Once the UAF is triggered, an attacker with sufficient primitives can pivot to kernel memory corruption. The attack does not require user interaction.
No public proof-of-concept exploit code is available for this vulnerability. Refer to the upstream commit references for technical patch details.
Detection Methods for CVE-2026-64027
Indicators of Compromise
- Kernel oops or panic messages referencing net_shaper_rollback or net/shaper call stacks
- KASAN reports indicating use-after-free in the shaper subsystem
- Unexpected kernel crashes on systems using network traffic shaping features
Detection Strategies
- Enable Kernel Address Sanitizer (KASAN) on test systems to surface use-after-free conditions during shaper operations
- Monitor dmesg and /var/log/kern.log for shaper-related warnings, RCU stalls, or slab corruption reports
- Audit installed kernel packages against distribution advisories referencing the upstream commits 2417df5e7bb4, 96ea960dd40f, and b8d75193 52ba
Monitoring Recommendations
- Track kernel version inventory across Linux fleets and flag hosts running unpatched builds
- Alert on repeated invocations of shaper netlink operations from unprivileged users
- Correlate kernel crash telemetry with process execution history to identify race-condition exploitation attempts
How to Mitigate CVE-2026-64027
Immediate Actions Required
- Apply the upstream kernel patches referenced in the git.kernel.org commits as soon as vendor builds are available
- Prioritize patching multi-tenant hosts, container hosts, and systems permitting untrusted local users
- Restrict access to network shaping configuration operations to trusted administrative accounts
Patch Information
The fix replaces the XArray VALID mark with an explicit valid field protected by smp_load_acquire() and smp_store_release() memory barriers. Patch details are available in the upstream commits 2417df5e7bb4, 96ea960dd40f, and b8d7519352ba. Consult your distribution's security tracker for backported package versions.
Workarounds
- Disable or remove kernel modules providing net shaper functionality where the feature is not required
- Limit CAP_NET_ADMIN capability to a minimal set of trusted users and services
- Deploy seccomp or AppArmor profiles that block shaper-related netlink operations from untrusted workloads
# Verify kernel version and check for shaper subsystem exposure
uname -r
grep -i shaper /proc/kallsyms | head
# Restrict CAP_NET_ADMIN via systemd unit hardening
# Add to service unit: CapabilityBoundingSet=~CAP_NET_ADMIN
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

