KernelScan.io

HIGH Introduced in 5.11

veth XdpNapi UAF

CVE-2026-80613

CVSS 7.8 / 10.0 NVD

CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

KernelScan AI7.8HIGH

01

In the Linux kernel, the following vulnerability has been resolved: veth: fix NAPI leak in XDP enable error path During XDP enablement in veth, if xdp_rxq_info_reg() or xdp_rxq_info_reg_mem_model() fails, the driver rolls back the changes. However, the rollback loop: for (i--; i >= start; i--) { decrements the loop index 'i' before the first iteration. This correctly skips unregistering the rxq for the failed index 'i' (as registration failed or was already cleaned up), but it also erroneously skips calling netif_napi_deli() for rq[i].xdp_napi. Since netif_napi_add() was already called for index 'i', this leaves a dangling napi_struct in the device's napi_list. When the veth device is later destroyed, the freed queue memory (which contains the leaked NAPI structure) can be reused. The subsequent device teardown iterates the NAPI list and corrupts the reallocated memory, leading to UAF. Fix this by explicitly deleting the NAPI association for the failed index 'i' before rolling back the successfully configured queues.

02

Engine v0.6.0

Risk summary

A local unprivileged user who can create a user namespace (and thus obtain CAP_NET_ADMIN) can trigger a use-after-free in the veth driver by causing an error during XDP enablement. The leaked NAPI structure remains on the device list after its backing memory is freed, and subsequent device teardown corrupts reallocated memory. This can lead to kernel code execution and container escape.

Affecteddrivers/net/veth.c (veth driver)

Vulnerability analysis

When enabling XDP on a veth device, the driver adds NAPI structures to each receive queue before finishing queue setup. If setup fails for one queue, the error cleanup skips removing that queue's NAPI structure from the device list. The queue memory is later freed, leaving the NAPI entry dangling. When the device is eventually destroyed, the kernel walks that list and touches the freed memory, which may have been reallocated, causing a use-after-free. The fix removes the leaked NAPI entry for the failed queue before cleaning up the rest. Any local user who can obtain CAP_NET_ADMIN in a user namespace can reach this, so it is exploitable from unprivileged container workloads.

03

BranchIntroducedFixed inPatch commit
5.155.115.15.212fc51373345e7
6.15.116.1.1784559770b2a24
6.125.116.12.97d3eb258ad398
6.185.116.18.40a9e6707322ef
6.65.116.6.14583090f5e7b54
7.15.117.1.54bd2e5dbe623
mainline5.117.26739027cb72d
cip/6.15.116.1.182-cip594559770b2a24
cip/6.1-rt5.116.1.182-cip59-rt314559770b2a24
cip/6.125.116.12.101-cip29d3eb258ad398

04

State of the newest release of each Civil Infrastructure Platform SLTS tree, from CIP's own fix records.

CIP treeState
cip/6.12Fixed in 6.12.101-cip29
cip/6.1Fixed in 6.1.182-cip59
cip/6.1-rtFixed in 6.1.182-cip59-rt31