HIGH Introduced in 4.15
flow_dissector Thoff Truncation
CVE-2026-98955
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:H
01Description
In the Linux kernel, the following vulnerability has been resolved: flow_dissector: avoid u16 truncation of skb->len when computing thoff __skb_flow_dissect() computes key_control->thoff using: key_control->thoff = min_t(u16, nhoff, skb ? skb->len : hlen); min_t(u16, ...) casts both arguments to u16 before comparing them. Whenever skb->len (or hlen) modulo 65536 is smaller than nhoff, the truncated length wins and thoff is set to a bogus small value, even when the dissection succeeded. For example, an IPv4/TCP frame with skb->len == 65540 and nhoff == 34 gets thoff == 4, so callers such as skb_probe_transport_header() point the transport header inside the Ethernet header. Such skbs are not exotic: - At the time of commit d0c081b49137 ("flow_dissector: properly cap thoff field"), AF_PACKET with PACKET_VNET_HDR could already build GSO skbs larger than 64KB (MTU checks are skipped for GSO, and alloc_skb_with_frags() accepted up to MAX_SKB_FRAGS (17) order-0 pages on top of the linear part). - BIG TCP now makes skbs larger than 64KB common. - The following patch makes tun_get_user() dissect IFF_TAP frames before eth_type_trans() pulls the Ethernet header, so a GSO frame carrying a 65522..65535 byte L3 packet will be dissected with skb->len in [65536, 65549]. Compare as u32 instead. If the resulting offset cannot be represented in the u16 key_control->thoff, cap it to U16_MAX and report the dissection as failed rather than silently returning a wrong transport offset. thoff is still set on failure, as some callers (such as eth_get_headlen()) use it regardless of the return value.
02KernelScan AI Analysis
Risk summary
A local attacker with CAP_NET_RAW or CAP_NET_ADMIN (obtainable in a user namespace) can craft oversized GSO packets that cause the flow dissector to compute a truncated transport header offset. This leads to out-of-bounds reads of kernel memory and kernel crashes, enabling information disclosure and denial of service. Container environments granting NET_ADMIN are particularly exposed.
Vulnerability analysis
The network packet analyzer calculates the transport header position by comparing the network header offset against the total packet length. Due to a 16-bit integer truncation, packets larger than 64 KB cause the length value to wrap around, making it appear smaller than the actual network header offset. This tricks the analyzer into recording an incorrect, too-small transport offset and reporting success. Later code then reads the transport header from the wrong location — inside the Ethernet header — which leads to out-of-bounds memory reads and kernel crashes. The fix performs the comparison using 32-bit integers, caps the offset at the maximum representable value, and treats oversized packets as dissection failures. Any local user who can create raw packet sockets or virtual network interfaces — capabilities obtainable inside a user namespace — can trigger this by sending oversized GSO frames.
Lifecycle
03Fix Versions
| Branch | Introduced | Fixed in | Patch commit |
|---|---|---|---|
| 4.14 | 4.14.16 | 4.15 | d44e66f5dd99 |
| 4.4 | 4.4.114 | 4.5 | 3f6000fdf8a5 |
| 4.9 | 4.9.79 | 4.10 | 2c2f82b696c5 |
| 5.10 | 4.15 | 5.10.273 | d9e08836d06c |
| 5.15 | 4.15 | 5.15.224 | 50d0cd575cab |
| 6.1 | 4.15 | 6.1.191 | 9993e6a0ac1b |
| 6.12 | 4.15 | 6.12.113 | 99bda1ecbd56 |
| 6.18 | 4.15 | 6.18.57 | — |
| 6.6 | 4.15 | 6.6.160 | 52efce4755a4 |
| 7.2 | 4.15 | 7.2.11 | — |
| mainline | 4.15 | 7.3 | — |
| cip/6.12 | 4.15 | 6.12.114-cip34 | 50d0cd575cab |
04CIP Kernels
State of the newest release of each Civil Infrastructure Platform SLTS tree, from CIP's own fix records.
| CIP tree | State |
|---|---|
| cip/6.12 | Fixed in 6.12.114-cip34 |
| cip/6.1 | Affected — no CIP fix yet (latest 6.1.190-cip62) |
| cip/6.1-rt | Affected — no CIP fix yet (latest 6.1.189-cip61-rt32) |
| cip/5.10 | Affected — no CIP fix yet (latest 5.10.272-cip79) |
| cip/5.10-rt | Affected — no CIP fix yet (latest 5.10.272-cip79-rt35) |
| cip/4.19 | Affected — no CIP fix yet (latest 4.19.325-cip137) |
| cip/4.19-rt | Affected — no CIP fix yet (latest 4.19.325-cip137-rt51) |
| cip/4.4 | Affected — no CIP fix yet (latest 4.4.302-cip116) |
| cip/4.4-rt | Affected — no CIP fix yet (latest 4.4.302-cip115-rt63) |