CVE-2025-38097 espintcp: remove encap socket caching to avoid reference leak
- Published
- Updated
- Exploit status
- No public exploit known
- CISA SSVC
- No known exploitation · automatable: no · technical impact: total
- Technology
- Linux KernelUbuntuDebian
Description
In the Linux kernel, the following vulnerability has been resolved:
espintcp: remove encap socket caching to avoid reference leak
The current scheme for caching the encap socket can lead to reference
leaks when we try to delete the netns.
The reference chain is: xfrm_state -> enacp_sk -> netns
Since the encap socket is a userspace socket, it holds a reference on
the netns. If we delete the espintcp state (through flush or
individual delete) before removing the netns, the reference on the
socket is dropped and the netns is correctly deleted. Otherwise, the
netns may not be reachable anymore (if all processes within the ns
have terminated), so we cannot delete the xfrm state to drop its
reference on the socket.
This patch results in a small (~2% in my tests) performance
regression.
A GC-type mechanism could be added for the socket cache, to clear
references if the state hasn't been used "recently", but it's a lot
more complex than just not caching the socket.
Upgrade path
12 packages: 9 fixed, 2 with no fix yet.
| Package | Affected | Fixed in | Status |
|---|---|---|---|
| cbl-mariner kernel(CBL-Mariner 2.0) | All versions | No fix listed | No fix yet |
| Microsoft cbl2 kernel 5.15.202.1-1 | All versions | No fix listed | No fix yet |
| debian/linux(Debian 12) | < 6.1.147-1; = 6.1.27-1; = 6.1.37-1; = 6.1.38-1 +38 more | 6.1.147-1 | Fixed |
| debian/linux(Debian 13) | < 6.12.32-1 | 6.12.32-1 | Fixed |
| debian/linux(Debian 14) | < 6.12.32-1 | 6.12.32-1 | Fixed |
| Linux kernel | < 5.10.270; < 5.15.221; < 6.1.141; < 6.6.93 +22 more | 5.10.270, 5.15.221, 6.1.141, 6.6.93, 6.12.31, 6.14.9, 6.15, 9cbca30102028f9ad3d2098f935c4368f581fd07, 74fd327767fb784c5875cf7c4ba1217f26020943, 9673ca00e6c5503069dc98780e2e89db0e663c16, 028363685bd0b7a19b4a820f82dd905b1dc83999, b58a295d10065960bcb9d60cb8ca6ead9837cd27, e4cde54b46a87231c77256a633be1bef62687d69, e32bafd08ee35feacd47b05cc5bfe9cd9659cd25 | Fixed |
| ubuntu/linux(Ubuntu 22.04) | < 5.15.0-202.212 | 5.15.0-202.212 | Fixed |
| ubuntu/linux(Ubuntu 24.04) | < 6.8.0-100.100 | 6.8.0-100.100 | Fixed |
| ubuntu/linux-kvm(Ubuntu 22.04) | < 5.15.0-1111.116 | 5.15.0-1111.116 | Fixed |
| ubuntu/linux-raspi(Ubuntu 22.04) | < 5.15.0-1113.116 | 5.15.0-1113.116 | Fixed |
| ubuntu/linux-raspi(Ubuntu 24.04) | < 6.8.0-1047.51 | 6.8.0-1047.51 | Fixed |
| debian linux | = 11.0 | No fix listed | Versions listed |
Affected products
| Product | Affected versions | Fixed in |
|---|---|---|
| cbl-mariner kernel(CBL-Mariner:2.0) | All versions | No fix listed |
| Microsoft cbl2 kernel 5.15.202.1-1 | All versions | No fix listed |
| debian/linux(Debian:12) | < 6.1.147-1 | 6.1.147-1 |
| debian/linux(Debian:12) | = 6.1.106-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.106-2 | No fix listed |
| debian/linux(Debian:12) | = 6.1.106-3 | No fix listed |
| debian/linux(Debian:12) | = 6.1.112-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.115-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.119-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.123-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.124-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.128-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.129-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.133-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.135-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.137-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.139-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.140-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.27-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.37-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.38-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.38-2 | No fix listed |
| debian/linux(Debian:12) | = 6.1.38-2~bpo11+1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.38-3 | No fix listed |
| debian/linux(Debian:12) | = 6.1.38-4 | No fix listed |
Show 53 more
| Product | Affected versions | Fixed in |
|---|---|---|
| debian/linux(Debian:12) | = 6.1.38-4~bpo11+1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.52-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.55-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.55-1~bpo11+1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.64-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.66-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.67-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.69-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.69-1~bpo11+1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.76-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.76-1~bpo11+1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.82-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.85-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.90-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.90-1~bpo11+1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.94-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.94-1~bpo11+1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.98-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.99-1 | No fix listed |
| debian/linux(Debian:13) | < 6.12.32-1 | 6.12.32-1 |
| debian/linux(Debian:14) | < 6.12.32-1 | 6.12.32-1 |
| Linux kernel | >= e27cca96cd68fa2c6814c90f9a1cfd36bb68c593, < e32bafd08ee35feacd47b05cc5bfe9cd9659cd25 | e32bafd08ee35feacd47b05cc5bfe9cd9659cd25 |
| Linux kernel | >= e27cca96cd68fa2c6814c90f9a1cfd36bb68c593, < 9673ca00e6c5503069dc98780e2e89db0e663c16 | 9673ca00e6c5503069dc98780e2e89db0e663c16 |
| Linux kernel | >= e27cca96cd68fa2c6814c90f9a1cfd36bb68c593, < e4cde54b46a87231c77256a633be1bef62687d69 | e4cde54b46a87231c77256a633be1bef62687d69 |
| Linux kernel | >= e27cca96cd68fa2c6814c90f9a1cfd36bb68c593, < b58a295d10065960bcb9d60cb8ca6ead9837cd27 | b58a295d10065960bcb9d60cb8ca6ead9837cd27 |
| Linux kernel | >= e27cca96cd68fa2c6814c90f9a1cfd36bb68c593, < 9cbca30102028f9ad3d2098f935c4368f581fd07 | 9cbca30102028f9ad3d2098f935c4368f581fd07 |
| Linux kernel | >= e27cca96cd68fa2c6814c90f9a1cfd36bb68c593, < 74fd327767fb784c5875cf7c4ba1217f26020943 | 74fd327767fb784c5875cf7c4ba1217f26020943 |
| Linux kernel | >= e27cca96cd68fa2c6814c90f9a1cfd36bb68c593, < 028363685bd0b7a19b4a820f82dd905b1dc83999 | 028363685bd0b7a19b4a820f82dd905b1dc83999 |
| Linux kernel | = 5.6 | No fix listed |
| Linux kernel | < 5.10.270 | 5.10.270 |
| Linux kernel | < 5.15.221 | 5.15.221 |
| Linux kernel | < 6.1.141 | 6.1.141 |
| Linux kernel | < 6.6.93 | 6.6.93 |
| Linux kernel | < 6.12.31 | 6.12.31 |
| Linux kernel | < 6.14.9 | 6.14.9 |
| Linux kernel | < 6.15 | 6.15 |
| Linux kernel | >= 5.6, < 6.1.141 | 6.1.141 |
| Linux kernel | >= 6.2, < 6.6.93 | 6.6.93 |
| Linux kernel | >= 6.7, < 6.12.31 | 6.12.31 |
| Linux kernel | >= 6.13, < 6.14.9 | 6.14.9 |
| Linux kernel | = 6.15-rc1 | No fix listed |
| Linux kernel | = 6.15-rc2 | No fix listed |
| Linux kernel | = 6.15-rc3 | No fix listed |
| Linux kernel | = 6.15-rc4 | No fix listed |
| Linux kernel | = 6.15-rc5 | No fix listed |
| Linux kernel | = 6.15-rc6 | No fix listed |
| Linux kernel | = 6.15-rc7 | No fix listed |
| debian linux | = 11.0 | No fix listed |
| ubuntu/linux(Ubuntu:22.04) | < 5.15.0-202.212 | 5.15.0-202.212 |
| ubuntu/linux-kvm(Ubuntu:22.04) | < 5.15.0-1111.116 | 5.15.0-1111.116 |
| ubuntu/linux-raspi(Ubuntu:22.04) | < 5.15.0-1113.116 | 5.15.0-1113.116 |
| ubuntu/linux(Ubuntu:24.04) | < 6.8.0-100.100 | 6.8.0-100.100 |
| ubuntu/linux-raspi(Ubuntu:24.04) | < 6.8.0-1047.51 | 6.8.0-1047.51 |
References
- MSRC Security Update Guide vendor-advisory
- Release Notes vendor-advisory
- Debian Security Tracker CVE-2025-38097 vendor-advisory
- git.kernel.org
- git.kernel.org
- git.kernel.org patch
- git.kernel.org patch
- git.kernel.org patch
- git.kernel.org patch
- git.kernel.org patch
- lists.debian.org mailing-list third-party-advisory
- Ubuntu CVE tracker vendor-advisory
- USN-7769-1 vendor-advisory
- USN-7770-1 vendor-advisory
- USN-7771-1 vendor-advisory
- USN-7769-2 vendor-advisory
- USN-7769-3 vendor-advisory
- USN-7789-1 vendor-advisory
- USN-7789-2 vendor-advisory
- USN-8028-1 vendor-advisory
- USN-8028-2 vendor-advisory
- USN-8031-1 vendor-advisory
- USN-8028-3 vendor-advisory
- USN-8028-4 vendor-advisory
- USN-8028-5 vendor-advisory
- USN-8031-2 vendor-advisory
- USN-8028-6 vendor-advisory
- USN-8031-3 vendor-advisory
- USN-8052-1 vendor-advisory
- USN-8028-7 vendor-advisory
- USN-8028-8 vendor-advisory
- USN-8052-2 vendor-advisory
- USN-8074-1 vendor-advisory
- USN-8074-2 vendor-advisory
- USN-8126-1 vendor-advisory
- USN-8962-1 vendor-advisory
- USN-8961-1 vendor-advisory
- USN-8963-1 vendor-advisory
- www.cve.org
- USN-9029-1 vendor-advisory
- ENISA EUVD EUVD-2025-19766 third-party-advisory