CVE-2025-40173
kernel: net/ip6_tunnel: Prevent perpetual tunnel growth
Severity
ModerateRed Hat Product Security
CVSS 3.1
Review impact separately from score.
Published · November 12, 2025
Updated · July 30, 2026
Description
In the Linux kernel, the following vulnerability has been resolved:
net/ip6_tunnel: Prevent perpetual tunnel growth
Similarly to ipv4 tunnel, ipv6 version updates dev->needed_headroom, too. While ipv4 tunnel headroom adjustment growth was limited in commit 5ae1e9922bbd ("net: ip_tunnel: prevent perpetual headroom growth"), ipv6 tunnel yet increases the headroom without any ceiling.
Reflect ipv4 tunnel headroom adjustment limit on ipv6 version.
Credits to Francesco Ruggeri, who was originally debugging this issue and wrote local Arista-specific patch and a reproducer.
Statement
This patch fixes an issue where IPv6 tunnels could grow dev->needed_headroom without bounds, eventually causing out-of-range headroom expansions and corruption of skb metadata. A local user with the ability to create or configure IPv6 tunnels (CAP_NET_ADMIN) could trigger oversized allocations leading to kernel panic or memory corruption. For the CVSS the Privilege requirement is PR:H because only privileged networking operations (tunnel creation / management) can influence headroom calculations, and unprivileged users cannot trigger this behavior directly.
CVSS score applicability
The CVSS score(s) listed for this vulnerability do not reflect the associated product's status, and are included for informational purposes to better understand the severity of this vulnerability.
Mitigation
No mitigation is specified in collected source.
CVSS / CWE
CVSS 3.1 · 4.1CVSS:3.1/AV:L/AC:H/PR:H/UI:N/S:U/C:N/I:N/A:H
CWE-122 · Heap-based Buffer Overflow