CVE-2026-31516 Details
Description
In the Linux kernel, the following vulnerability has been resolved: xfrm: prevent policy_hthresh.work from racing with netns teardown 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.
A vulnerability in the Linux kernel's XFRM (IPsec) subsystem can lead to a use-after-free issue. When a new security policy database (SPD) information message is received, it can schedule a work item that processes policy hash table thresholds. If the network namespace is deleted before this work item is executed, it may access freed memory, causing potential instability or exploitation. Although the policy hash work is flushed during network namespace teardown, this synchronization does not extend to the policy threshold work, creating a race condition. The vulnerability affects the Linux kernel stable tree.
The vulnerability has been fixed in the Linux kernel. Users should upgrade to the latest version.
Metrics
CVSS 4.0 Severity and Vector Strings:
No CVSS 4.0 data is available for this CVE.
CVSS 3.x Severity and Vector Strings:
No data available for CVSS Version 2.0 on this CVE.
No SSVC data is available for this CVE.
References to Advisories, Solutions, and Tools
By selecting these links, you will be leaving this site. These are references gathered from the official CVE record and are not endorsed by Volerion.
| URL | Source(s) | Tag(s) |
|---|---|---|
| https://git.kernel.org/stable/c/29fe3a61bcdce398ee3955101c39f89c01a8a77e | kernel.org | Patch |
| https://git.kernel.org/stable/c/4e2e77843fef473ef47e322d52436d8308582a96 | kernel.org | Patch |
| https://git.kernel.org/stable/c/56ea2257b83ee29a543f158159e3d1abc1e3e4fe | kernel.org | Patch |
| https://git.kernel.org/stable/c/8854e9367465d784046362698731c1111e3b39b8 | kernel.org | Patch |
Weakness Enumeration
| CWE-ID | CWE Name | Source |
|---|---|---|
| CWE-362 | Concurrent Execution using Shared Resource with Improper Synchronization ('Race Condition') | [email protected] |
Affected Products
| Product | Versions |
|---|---|
| linux linux kernel | >= 3.18.1, < 6.12.80 >= 6.13, < 6.18.21 >= 6.19, < 6.19.11 3.18 - 7.0 rc1 7.0 rc2 7.0 rc3 7.0 rc4 7.0 rc5 7.0 rc6 7.0 rc7 |
CPE
Remediation
| |
Change History
4 change records found show changes
| Date | Action | Recorded By |
|---|---|---|
| Jun 17, 2026 | CVE Modified | kernel.org |
| Apr 28, 2026 | Initial Analysis | [email protected] |
| Apr 27, 2026 | CVE Modified | kernel.org |
| Apr 22, 2026 | New CVE Received | kernel.org |