data built 2026-10-19T13:16:53Z

Look up another CVE · open CVE-2026-31516 in the interactive tracker

CVE-2026-31516

xfrm: prevent policy_hthresh.work from racing with netns teardown

7.8 EPSS 0.1% AV:L

Published 2026-04-22 (6 months ago) by the Linux kernel CNA. Subsystem net/xfrm. Debian urgency: not yet assigned.

What to do, per Debian release

Debian's own status for CVE-2026-31516 in every release this site tracks, and what each one means in practice. Every status below is the one the Debian Security Team publishes for this CVE. source

ReleaseStatus VersionWhat this means
Debian 12bookwormvulnerable6.1.190-1No fix published anywhere yet, neither in Debian nor upstream for the series bookworm tracks. Watch the Debian tracker page for this CVE. Advisories for bookworm have historically landed a median of 23 days after publication.
Debian 13trixiefixedDSA-6238-1 · 2026-04-30 · text6.12.85-1Update the kernel and reboot. DSA-6238-1 shipped the fix on 2026-04-30, in 6.12.85-1. A running kernel keeps the old code until the machine restarts.
Debian 14forkyfixed6.19.11-1Update the kernel and reboot. Fixed in 6.19.11-1. A running kernel keeps the old code until the machine restarts.
Debian unstablesidfixed6.19.11-1Update the kernel and reboot. Fixed in 6.19.11-1. A running kernel keeps the old code until the machine restarts.

The vulnerability

What the bug is

A XFRM_MSG_NEWSPDINFO request can queue the per-net work item policy_hthresh.work onto the system workqueue. The queued callback, xfrm_hash_rebuild(), retrieves the enclosing struct net via container_of(). If the net namespace is torn down before that work runs, the associated struct net may already have been freed, and xfrm_hash_rebuild() may then dereference stale memory. xfrm_policy_fini() already flushes policy_hash_work during teardown, but it does not synchronize policy_hthresh.work. Synchronize policy_hthresh.work in xfrm_policy_fini() as well, so the queued work cannot outlive the net namespace teardown and access a freed struct net.

Where it lives

The fix touches these files. If the subsystem is one you do not use, the practical exposure is lower, though the package is still the vulnerable one.

net/xfrm/xfrm_policy.c

What this is
NETWORKING [IPSEC]MAINTAINERS section matched on net/xfrm/ · netdev@vger.kernel.org · Maintained

Check it on the machine

grep -w CONFIG_XFRM /boot/config-$(uname -r)

Reads the booted kernel's own configuration, on the machine and nowhere else. =y is built in, =m is a module, and an is not set line means the code is not there.

Show whether Debian builds this, per release

Debian builds this code. Every release below compiles the affected file into the kernels it ships.

  • bookworm, trixie, forky, sidy
y
built into the kernel image on every flavour - only a patch removes it
Build switch
CONFIG_XFRM

From the configuration Debian publishes for every kernel flavour it builds. It covers only the architectures Debian ships a linux-config package for, and nothing about a kernel you built yourself. Debian's own status above stays authoritative about the source package.MAINTAINERS kbuild Makefiles Debian linux-config packages

Signals

Published
2026-04-22 (6 months ago)source
CVSS
7.8 high
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:Hsource recompute it
Attack vector
local (AV:L)source
EPSS
0.14%, higher than 2.7% of all CVEssource
CISA KEV
not listedthe KEV catalogue
Debian urgency
not yet assignedsource
Subsystem
net/xfrm

Upstream fixes

The versions the CNA records as introducing and fixing this, and the commit for each. source

IntroducedFixed inCommit
3.186.12.8056ea2257b83e
3.186.18.218854e9367465
3.186.19.114e2e77843fef
3.187.029fe3a61bcdc

Debian advisories

AdvisoryDateShipped toDebian
DSA-6238-12026-04-30trixie 6.12.85-1tracker

Why the CNA scored it this way

Quoted from the kernel CNA's own scoring file, word for word. A highlighted metric carries the most severe value CVSS v3.1 defines for it, which is what pushes the score up. source

AV:LAttack vector, local
The vulnerable path is reached by a local NETLINK_XFRM request, specifically XFRM_MSG_NEWSPDINFO, not by remote packet processing.
AC:LAttack complexity, low
The attacker can create the net namespace, send the request that queues policy_hthresh.work, and tear the namespace down; this is an attacker-controlled race and can be retried.
PR:LPrivileges required, low
XFRM netlink operations require CAP_NET_ADMIN over the target network namespace. This is reachable with low privileges via user and network namespaces rather than requiring real init-namespace root.
UI:NUser interaction, none
No victim action is required after the attacker has local execution; the attacker directly drives the netlink request and namespace teardown.
S:UScope, unchanged
The impact is within the kernel security authority and does not cross a separate boundary such as guest-to-host or IOMMU isolation.
C:HConfidentiality impact, high
The bug is a use-after-free of struct net reached by queued work dereferencing stale namespace memory. Under the required conservative kernel scoring guidance, UAF memory corruption is treated as capable of high confidentiality impact.
I:HIntegrity impact, high
The stale work callback writes through fields in the freed struct net and manipulates policy lists and hash state. As a kernel UAF, this is defensibly scored as high integrity impact due to potential memory corruption and control-flow exploitation.
A:HAvailability impact, high
The stale struct net dereference can crash or corrupt the kernel during workqueue execution. Kernel crashes and UAF-triggered failures are high availability impact.