CVE-2025-21864

tcp: drop secpath at the same time as we currently drop dst

MEDIUM
5.5
CVSS Score
Published: March 12, 2025 at 09:42 AM UTC
Updated: October 15, 2026 at 02:17 AM UTC
4 products affected across 2 vendorsLinux KernelSIMATIC S7-1500 CPU 1518-4 Pn /dp MFP FirmwareSiplus S7-1500 CPU 1518-4 Pn /dp MFP Firmware

Using Linux by Linux?

Get instant alerts when new vulnerabilities affect Linux - before attackers find them.

Real-time alertsTrack your software stackFree plan available
Severity
MEDIUM5.5
Exploit prediction
EPSS 0.3%
SSVC
No known exploit

Description

In the Linux kernel, the following vulnerability has been resolved: tcp: drop secpath at the same time as we currently drop dst Xiumei reported hitting the WARN in xfrm6_tunnel_net_exit while running tests that boil down to: - create a pair of netns - run a basic TCP test over ipcomp6 - delete the pair of netns The xfrm_state found on spi_byaddr was not deleted at the time we delete the netns, because we still have a reference on it. This lingering reference comes from a secpath (which holds a ref on the xfrm_state), which is still attached to an skb. This skb is not leaked, it ends up on sk_receive_queue and then gets defer-free'd by skb_attempt_defer_free. The problem happens when we defer freeing an skb (push it on one CPU's defer_list), and don't flush that list before the netns is deleted. In that case, we still have a reference on the xfrm_state that we don't expect at this point. We already drop the skb's dst in the TCP receive path when it's no longer needed, so let's also drop the secpath. At this point, tcp_filter has already called into the LSM hooks that may require the secpath, so it should not be needed anymore. However, in some of those places, the MPTCP extension has just been attached to the skb, so we cannot simply drop all extensions.

Affected

Our own answer: ranges merged, affected separated from platform-only, with confidence and review flags.

5.19 ≤ v < 6.1.1306.13 ≤ v < 6.13.56.2 ≤ v < 6.6.806.7 ≤ v < 6.12.176.146.14 rc16.14 rc26.14 rc368822bdf76f10c3dc80609d4e2cdc1e847429086
Vendor states this is fixed in 69cafd9413084cd5012cf5d7c7ec6f3d493726d9 (fixed)
Vendor states this is fixed in 87858bbf21da239ace300d61dd209907995c0491 (fixed)
Vendor states this is fixed in 9b6412e6979f6f9e0632075f8f008937b5cd4efd (fixed)
Vendor states this is fixed in cd34a07f744451e2ecf9005bb7d24d0b2fb83656 (fixed)
Vendor states this is fixed in f1d5e6a5e468308af7759cf5276779d3155c5e98 (fixed)
Vendor states this is fixed in 5.19 (unaffected)
Vendor states this is fixed in 6.1.130 (unaffected)
Vendor states this is fixed in 6.12.17 (unaffected)
Vendor states this is fixed in 6.13.5 (unaffected)
Vendor states this is fixed in 6.14 (unaffected)
Vendor states this is fixed in 6.6.80 (unaffected)

References (10)

Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/69cafd9413084cd5012cf5d7c7ec6f3d493726d9
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/87858bbf21da239ace300d61dd209907995c0491
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/9b6412e6979f6f9e0632075f8f008937b5cd4efd
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/cd34a07f744451e2ecf9005bb7d24d0b2fb83656
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/f1d5e6a5e468308af7759cf5276779d3155c5e98
Source: af854a3a-2127-422b-91ae-364da2661108
https://lists.debian.org/debian-lts-announce/2025/05/msg00045.html
Source: 0b142b55-0307-4c5a-b3c9-f314f3fb7c5e
https://cert-portal.siemens.com/productcert/html/ssa-019113.html
Source: 0b142b55-0307-4c5a-b3c9-f314f3fb7c5e
https://cert-portal.siemens.com/productcert/html/ssa-082556.html

SSVC — Action Prioritization

SSVCNo known exploitNot automatablePartial impact

SSVC signals action urgency (what to patch first), separate from CVSS which measures severity.

CVSS

5.5MEDIUMCISA-ADP
Attack Vector
LOCAL
Complexity
LOW
Privileges
LOW
User Interaction
NONE
Scope
UNCHANGED
Confidentiality
NONE
Integrity
NONE
Availability
HIGH
Vector?

Quick Info

StatusMODIFIED
CWE
CWE-476

Get alerted

Stop reading CVE feeds looking for your own stack

Track the products you run and VulnTracker tells you when a new CVE affects them — with what is known about fixing it, and nothing about the rest.

Free plan, no card