CVE-2024-35884
Severity CVSS v4.0:
Pending analysis
Type:
Unavailable / Other
Publication date:
19/05/2024
Last modified:
23/12/2025
Description
In the Linux kernel, the following vulnerability has been resolved:<br />
<br />
udp: do not accept non-tunnel GSO skbs landing in a tunnel<br />
<br />
When rx-udp-gro-forwarding is enabled UDP packets might be GROed when<br />
being forwarded. If such packets might land in a tunnel this can cause<br />
various issues and udp_gro_receive makes sure this isn&#39;t the case by<br />
looking for a matching socket. This is performed in<br />
udp4/6_gro_lookup_skb but only in the current netns. This is an issue<br />
with tunneled packets when the endpoint is in another netns. In such<br />
cases the packets will be GROed at the UDP level, which leads to various<br />
issues later on. The same thing can happen with rx-gro-list.<br />
<br />
We saw this with geneve packets being GROed at the UDP level. In such<br />
case gso_size is set; later the packet goes through the geneve rx path,<br />
the geneve header is pulled, the offset are adjusted and frag_list skbs<br />
are not adjusted with regard to geneve. When those skbs hit<br />
skb_fragment, it will misbehave. Different outcomes are possible<br />
depending on what the GROed skbs look like; from corrupted packets to<br />
kernel crashes.<br />
<br />
One example is a BUG_ON[1] triggered in skb_segment while processing the<br />
frag_list. Because gso_size is wrong (geneve header was pulled)<br />
skb_segment thinks there is "geneve header size" of data in frag_list,<br />
although it&#39;s in fact the next packet. The BUG_ON itself has nothing to<br />
do with the issue. This is only one of the potential issues.<br />
<br />
Looking up for a matching socket in udp_gro_receive is fragile: the<br />
lookup could be extended to all netns (not speaking about performances)<br />
but nothing prevents those packets from being modified in between and we<br />
could still not find a matching socket. It&#39;s OK to keep the current<br />
logic there as it should cover most cases but we also need to make sure<br />
we handle tunnel packets being GROed too early.<br />
<br />
This is done by extending the checks in udp_unexpected_gso: GSO packets<br />
lacking the SKB_GSO_UDP_TUNNEL/_CSUM bits and landing in a tunnel must<br />
be segmented.<br />
<br />
[1] kernel BUG at net/core/skbuff.c:4408!<br />
RIP: 0010:skb_segment+0xd2a/0xf70<br />
__udp_gso_segment+0xaa/0x560
Impact
Base Score 3.x
5.50
Severity 3.x
MEDIUM
Vulnerable products and versions
| CPE | From | Up to |
|---|---|---|
| cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* | 5.6 (including) | 5.10.215 (excluding) |
| cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* | 5.11 (including) | 5.15.154 (excluding) |
| cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* | 5.16 (including) | 6.1.85 (excluding) |
| cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* | 6.2 (including) | 6.6.26 (excluding) |
| cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* | 6.7 (including) | 6.8.5 (excluding) |
| cpe:2.3:o:linux:linux_kernel:6.9:rc1:*:*:*:*:*:* | ||
| cpe:2.3:o:linux:linux_kernel:6.9:rc2:*:*:*:*:*:* | ||
| cpe:2.3:o:debian:debian_linux:10.0:*:*:*:*:*:*:* |
To consult the complete list of CPE names with products and versions, see this page
References to Advisories, Solutions, and Tools
- https://git.kernel.org/stable/c/3001e7aa43d6691db2a878b0745b854bf12ddd19
- https://git.kernel.org/stable/c/3391b157780bbedf8ef9f202cbf10ee90bf6b0f8
- https://git.kernel.org/stable/c/35fe0e0b5c00bef7dde74842a2564c43856fbce4
- https://git.kernel.org/stable/c/3d010c8031e39f5fa1e8b13ada77e0321091011f
- https://git.kernel.org/stable/c/d12245080cb259d82b34699f6cd4ec11bdb688bd
- https://git.kernel.org/stable/c/d49ae15a5767d4e9ef8bbb79e42df1bfebc94670
- https://git.kernel.org/stable/c/3001e7aa43d6691db2a878b0745b854bf12ddd19
- https://git.kernel.org/stable/c/3391b157780bbedf8ef9f202cbf10ee90bf6b0f8
- https://git.kernel.org/stable/c/35fe0e0b5c00bef7dde74842a2564c43856fbce4
- https://git.kernel.org/stable/c/3d010c8031e39f5fa1e8b13ada77e0321091011f
- https://git.kernel.org/stable/c/d12245080cb259d82b34699f6cd4ec11bdb688bd
- https://git.kernel.org/stable/c/d49ae15a5767d4e9ef8bbb79e42df1bfebc94670
- https://lists.debian.org/debian-lts-announce/2024/06/msg00017.html



