CVE Catalog

CVE-2025-38097

HighCVSS 7.8
Published: Updated: Translated: NVD NIST

Exploitation Probability (EPSS)

Low risk
0.17%

7th percentile - higher than 7% of all known CVEs

Summary

In the Linux kernel's ESPINTCP mechanism, caching the encapsulation socket (encap_sk) can lead to reference leaks. When the xfrm state is deleted before the network namespace (netns) is removed, the socket reference is correctly released. However, if the netns is removed first, the xfrm state cannot be deleted, causing a socket reference leak and preventing netns deletion.

Risk Assessment

The vulnerability can prevent proper deletion of network namespaces, leading to kernel resource leaks and potential memory exhaustion.

Recommendation

Apply the Linux kernel patch that removes the encapsulation socket caching to prevent reference leaks.

Other vulnerabilities in Linux kernel

See all
Original NVD description (English source)

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.

Vulnerability data from NVD (NIST) · CISA KEV · EPSS