cbcvebase.
CVE-2024-36933
published 2024-05-30

CVE-2024-36933: In the Linux kernel, the following vulnerability has been resolved: nsh: Restore skb->{protocol,data,mac_header} for outer header in nsh_gso_segment(). syzbot…

PriorityP421medium5.5CVSS 3.1
AVLACLPRLUINSUCNINAH
EPSS
0.29%
20.8th percentile
In the Linux kernel, the following vulnerability has been resolved: nsh: Restore skb->{protocol,data,mac_header} for outer header in nsh_gso_segment(). syzbot triggered various splats (see [0] and links) by a crafted GSO packet of VIRTIO_NET_HDR_GSO_UDP layering the following protocols: ETH_P_8021AD + ETH_P_NSH + ETH_P_IPV6 + IPPROTO_UDP NSH can encapsulate IPv4, IPv6, Ethernet, NSH, and MPLS. As the inner protocol can be Ethernet, NSH GSO handler, nsh_gso_segment(), calls skb_mac_gso_segment() to invoke inner protocol GSO handlers. nsh_gso_segment() does the following for the original skb before calling skb_mac_gso_segment() 1. reset skb->network_header 2. save the original skb->{mac_heaeder,mac_len} in a local variable 3. pull the NSH header 4. resets skb->mac_header 5. set up skb->mac_len and skb->protocol for the inner protocol. and does the following for the segmented skb 6. set ntohs(ETH_P_NSH) to skb->protocol 7. push the NSH header 8. restore skb->mac_header 9. set skb->mac_header + mac_len to skb->network_header 10. restore skb->mac_len There are two problems in 6-7 and 8-9. (a) After 6 & 7, skb->data points to the NSH header, so the outer header (ETH_P_8021AD in this case) is stripped when skb is sent out of netdev. Also, if NSH is encapsulated by NSH + Ethernet (so NSH-Ethernet-NSH), skb_pull() in the first nsh_gso_segment() will make skb->data point to the middle of the outer NSH or Ethernet header because the Ethernet header is not pulled by the second nsh_gso_segment(). (b) While restoring skb->{mac_header,network_header} in 8 & 9, nsh_gso_segment() does not assume that the data in the linear buffer is shifted. However, udp6_ufo_fragment() could shift the data and change skb->mac_header accordingly as demonstrated by syzbot. If this happens, even the restored skb->mac_header points to the middle of the outer header. It seems nsh_gso_segment() has never worked with outer headers so far. At the end of nsh_gso_segment(), the outer header m

Affected

31 ranges· showing 25
VendorProductVersion rangeFixed in
debiandebian_linux
debianlinux< linux 6.1.94-1 (bookworm)linux 6.1.94-1 (bookworm)
linuxlinux
linuxlinux>= c411ed854584a71b0e86ac3019b60e4789d88086 < a7c2c3c1caabcb4a3d6c47284c397507aaf54fe9a7c2c3c1caabcb4a3d6c47284c397507aaf54fe9
linuxlinux>= c411ed854584a71b0e86ac3019b60e4789d88086 < 46134031c20fd313d03b90169d64b2e05ca6b65c46134031c20fd313d03b90169d64b2e05ca6b65c
linuxlinux>= c411ed854584a71b0e86ac3019b60e4789d88086 < bbccf0caef2fa917d6d0692385a06ce3c262a216bbccf0caef2fa917d6d0692385a06ce3c262a216
linuxlinux>= c411ed854584a71b0e86ac3019b60e4789d88086 < 5a4603fbc285752d19e4b415466db18ef3617e4a5a4603fbc285752d19e4b415466db18ef3617e4a
linuxlinux>= c411ed854584a71b0e86ac3019b60e4789d88086 < 37ed6f244ec5bda2e90b085084e322ea55d0aaa237ed6f244ec5bda2e90b085084e322ea55d0aaa2
linuxlinux>= c411ed854584a71b0e86ac3019b60e4789d88086 < 696d18bb59727a2e0526c0802a812620be1c9340696d18bb59727a2e0526c0802a812620be1c9340
linuxlinux>= c411ed854584a71b0e86ac3019b60e4789d88086 < 29a07f2ee4d273760c2acbfc756e29eccd82470a29a07f2ee4d273760c2acbfc756e29eccd82470a
linuxlinux>= c411ed854584a71b0e86ac3019b60e4789d88086 < 4b911a9690d72641879ea6d13cce1de31d346d794b911a9690d72641879ea6d13cce1de31d346d79
linuxlinux_kernel
linuxlinux_kernel
linuxlinux_kernel
linuxlinux_kernel
linuxlinux_kernel
linuxlinux_kernel
linuxlinux_kernel>= 0 < 5.10.218-15.10.218-1
linuxlinux_kernel>= 0 < 6.1.94-16.1.94-1
linuxlinux_kernel>= 0 < 6.8.11-16.8.11-1
linuxlinux_kernel>= 0 < 6.8.11-16.8.11-1
linuxlinux_kernel>= 0 < 5.4.0-192.2125.4.0-192.212
linuxlinux_kernel>= 0 < 5.15.0-118.1285.15.0-118.128
linuxlinux_kernel>= 0 < 6.8.0-40.406.8.0-40.40
linuxlinux_kernel>= 4.14 < 4.19.3144.19.314

CVSS provenance

nvdv3.15.5MEDIUMCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
osv7.8HIGH
vendor_ubuntu7.8HIGH
vendor_debian5.5MEDIUM
vendor_redhat5.5MEDIUM
Stop checking back — get the weekly exploitation signal.

Every Monday: what got weaponized or added to CISA KEV in the last seven days — each CVE cross-linked to its PoC, Nuclei template, and detection rule. Free, one email a week, unsubscribe in one click.