Description
In the Linux kernel, the following vulnerability has been resolved:

xfrm: Check for underflow in xfrm_state_mtu

Leo Lin reported OOB write issue in esp component:

xfrm_state_mtu() returns u32 but performs its arithmetic in unsigned
modulo-2^32 space using an attacker-influenced "header_len + authsize +
net_adj" subtracted from a small "mtu" argument. A nobody user can
install an IPv4 ESP tunnel SA with a large authentication key
(XFRMA_ALG_AUTH_TRUNC, e.g. hmac(sha512), 64-byte key, 64-byte trunc),
configure a small interface MTU (68 bytes), and set XFRMA_TFCPAD to a
large value. When a single UDP datagram is then sent through the
tunnel, xfrm_state_mtu() underflows to a near-2^32 value, and
esp_output() consumes it as a signed int via:

padto = min(x->tfcpad, xfrm_state_mtu(x, mtu_cached))
esp.tfclen = padto - skb->len (assigned to int)

esp.tfclen ends up negative (e.g. -207). It is sign-extended to size_t
when passed to memset() inside esp_output_fill_trailer(), producing a
~16 EB write of zeroes at skb_tail_pointer(skb). KASAN logs it as
"Write of size 18446744073709551537 at addr ffff888...".

Check for underflow and return 1. This causes the sendmsg attempt to
fail with ENETUNREACH.
Published: 2026-07-19
Score: 7.8 High
EPSS: < 1% Very Low
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

In the Linux kernel’s IPsec (xfrm) subsystem, the xfrm_state_mtu function computes the Ethernet‑layer maximum transmission unit using unsigned 32‑bit arithmetic. When an attacker supplies a large ESP authentication key, a very small MTU, and an unusually large tfcpad value, the calculation underflows to a value near 2^32. This value is then used as a signed integer in esp_output_fill_trailer, causing memset to be passed a very large size (~16 EB). The result is an out‑of‑bounds write that corrupts kernel memory and typically aborts the process, producing a denial‑of‑service condition. The vulnerability is a classical uncontrolled write (CWE‑787) and is not directly an escalation primitive, but the resulting memory corruption can trigger a kernel crash that affects the entire system.

Affected Systems

All releases of the mainline Linux kernel that contain the vulnerable xfrm_state_mtu code are affected; no specific version constraints were listed. The flaw resides in the core xfrm subsystem that processes ESP traffic, so any kernel built from the upstream source with this code is potentially susceptible. Security‑sensitive environments that allow local users to configure IPsec tunnels are therefore exposed.

Risk and Exploitability

The CVSS score of 7.8 indicates high severity, while the EPSS score of <1 % shows a low current exploitation likelihood. The vulnerability requires local access to configure an ESP tunnel with the specific offset parameters, making it relevant mainly for multi‑tenant or shared consoles where untrusted users can create network interfaces. While the assault cannot directly raise privileges, the kernel memory corruption can lead to a system crash and reboot, constituting a denial‑of‑service vector.

Generated by OpenCVE AI on August 4, 2026 at 06:15 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Update the Linux kernel to a release that includes the xfrm_state_mtu underflow check
  • Disable or restrict the creation of IPv4 ESP tunnels for untrusted users or enforce firewall rules that block ESP traffic
  • Ensure that interfaces used for ESP tunnels have MTU values larger than 68 bytes and that the XFRMA_TFCPAD parameter is set to a reasonable limit

Generated by OpenCVE AI on August 4, 2026 at 06:15 UTC.

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Ubuntu USN Ubuntu USN USN-8593-1 Linux kernel vulnerabilities
Ubuntu USN Ubuntu USN USN-8603-1 Linux kernel (Azure) vulnerabilities
Ubuntu USN Ubuntu USN USN-8618-1 Linux kernel vulnerabilities
History

Wed, 22 Jul 2026 12:15:00 +0000

Type Values Removed Values Added
Weaknesses CWE-787
References
Metrics threat_severity

None

threat_severity

Important


Mon, 20 Jul 2026 14:45:00 +0000

Type Values Removed Values Added
Metrics cvssV3_1

{'score': 7.8, 'vector': 'CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H'}


Sun, 19 Jul 2026 15:30:00 +0000

Type Values Removed Values Added
Description In the Linux kernel, the following vulnerability has been resolved: xfrm: Check for underflow in xfrm_state_mtu Leo Lin reported OOB write issue in esp component: xfrm_state_mtu() returns u32 but performs its arithmetic in unsigned modulo-2^32 space using an attacker-influenced "header_len + authsize + net_adj" subtracted from a small "mtu" argument. A nobody user can install an IPv4 ESP tunnel SA with a large authentication key (XFRMA_ALG_AUTH_TRUNC, e.g. hmac(sha512), 64-byte key, 64-byte trunc), configure a small interface MTU (68 bytes), and set XFRMA_TFCPAD to a large value. When a single UDP datagram is then sent through the tunnel, xfrm_state_mtu() underflows to a near-2^32 value, and esp_output() consumes it as a signed int via: padto = min(x->tfcpad, xfrm_state_mtu(x, mtu_cached)) esp.tfclen = padto - skb->len (assigned to int) esp.tfclen ends up negative (e.g. -207). It is sign-extended to size_t when passed to memset() inside esp_output_fill_trailer(), producing a ~16 EB write of zeroes at skb_tail_pointer(skb). KASAN logs it as "Write of size 18446744073709551537 at addr ffff888...". Check for underflow and return 1. This causes the sendmsg attempt to fail with ENETUNREACH.
Title xfrm: Check for underflow in xfrm_state_mtu
First Time appeared Linux
Linux linux Kernel
CPEs cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
Vendors & Products Linux
Linux linux Kernel
References

Subscriptions

Linux Linux Kernel
cve-icon MITRE

Status: PUBLISHED

Assigner: Linux

Published:

Updated: 2026-08-05T12:38:09.114Z

Reserved: 2026-07-19T07:54:57.026Z

Link: CVE-2026-64009

cve-icon Vulnrichment

No data.

cve-icon NVD

No data.

cve-icon Redhat

Severity : Important

Publid Date: 2026-07-19T00:00:00Z

Links: CVE-2026-64009 - Bugzilla

cve-icon OpenCVE Enrichment

Updated: 2026-08-04T06:30:05Z

Weaknesses