CVE-2026-23319

bpf: Fix a UAF issue in bpf_trampoline_link_cgroup_shim

No CVSS score yet EPSS 0.21%

Published 25 Mar 2026 Updated 10 Nov 2026 CNA: Linux

Check your servers for CVE-2026-23319

The Vulnpocalypse collector sends the package list of each Linux server and of its container images once a day. Vulnpocalypse shows every server where CVE-2026-23319 affects the running kernel, with the command that installs the fix. The free plan covers one server and one domain and does not need a credit card.

Check my servers

Description

In the Linux kernel, the following vulnerability has been resolved:

bpf: Fix a UAF issue in bpf_trampoline_link_cgroup_shim

The root cause of this bug is that when 'bpf_link_put' reduces the refcount of 'shim_link->link.link' to zero, the resource is considered released but may still be referenced via 'tr->progs_hlist' in 'cgroup_shim_find'. The actual cleanup of 'tr->progs_hlist' in 'bpf_shim_tramp_link_release' is deferred. During this window, another process can cause a use-after-free via 'bpf_trampoline_link_cgroup_shim'.

Based on Martin KaFai Lau's suggestions, I have created a simple patch.

To fix this: Add an atomic non-zero check in 'bpf_trampoline_link_cgroup_shim'. Only increment the refcount if it is not already zero.

Testing: I verified the fix by adding a delay in 'bpf_shim_tramp_link_release' to make the bug easier to trigger:

static void bpf_shim_tramp_link_release(struct bpf_link *link) { /* ... */ if (!shim_link->trampoline) return;

+ msleep(100); WARN_ON_ONCE(bpf_trampoline_unlink_prog(&shim_link->link, shim_link->trampoline, NULL)); bpf_trampoline_put(shim_link->trampoline); }

Before the patch, running a PoC easily reproduced the crash(almost 100%) with a call trace similar to KaiyanM's report. After the patch, the bug no longer occurs even after millions of iterations.

Exploitation

EPSS 0.21%: the probability of exploitation activity in the next 30 days, from the EPSS model of FIRST. The score is higher than 6.14% of all scored CVEs. Scores of 30 Nov 2026.

Affected products

As the CNA lists them.

ProductVersions
Linux
affected from 69fd337a975c7e690dfe49d9cb4fe5ba1e6db44e, before 529e685e522b9d7fb379dbe6929dcdf520e34c8c
affected from 69fd337a975c7e690dfe49d9cb4fe5ba1e6db44e, before 9b02c5c4147f8af8ed783c8deb5df927a55c3951
affected from 69fd337a975c7e690dfe49d9cb4fe5ba1e6db44e, before cfcfa0ca0212162aa472551266038e8fd6768cff
affected from 69fd337a975c7e690dfe49d9cb4fe5ba1e6db44e, before 3eeddb80191f7626ec1ef742bfff51ec3b0fa5c2
affected from 69fd337a975c7e690dfe49d9cb4fe5ba1e6db44e, before 4e8a0005d633a4adc98e3b65d5080f93b90d356b
affected from 69fd337a975c7e690dfe49d9cb4fe5ba1e6db44e, before 56145d237385ca0e7ca9ff7b226aaf2eb8ef368b
Other versions: unaffected
Linux
affected 6.0
unaffected before 6.0
unaffected from 6.1.167 up to and including 6.1.*
unaffected from 6.6.130 up to and including 6.6.*
unaffected from 6.12.77 up to and including 6.12.*
unaffected from 6.18.17 up to and including 6.18.*
unaffected from 6.19.7 up to and including 6.19.*
unaffected 7.0 and later
Other versions: affected

Is my server affected?

This CVE is in the Linux kernel. Compare the running kernel with the fixed kernel version of your distribution, and reboot after a kernel update:

uname -r
# Debian, Ubuntu: does the changelog of the running kernel name the CVE?
zgrep -l CVE-2026-23319 /usr/share/doc/linux-image-$(uname -r)/changelog.Debian.gz
# RHEL, Rocky, Alma
rpm -q --changelog kernel | grep CVE-2026-23319

With Trivy, on the host and for a container image. When a package is affected, it prints the installed and the fixed version:

trivy rootfs --scanners vuln / | grep CVE-2026-23319
trivy image --scanners vuln IMAGE | grep CVE-2026-23319

Vulnpocalypse makes this comparison every day for the package lists of your servers and container images, including language packages (npm, PyPI, Go, Maven and others), and sends the command that installs the fix. Start free with one server and one domain or read how to install the collector.

References

Other references

Source: the record CVE-2026-23319 of the CVE List (CVE Program), CVE Terms of Use; EPSS of FIRST. The text of the record is shown as published. Data sources and licences.