Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1795154463; b=N9+tCmxccvBhJbHt3axl2jMlmHvoTwVOAkbEpASn3ZocDkuN2xU0Cr2d8xa1/eiMpu36 vKIUHi7tCjy2LQZb7Ju2VrNRllLhGK77KTgsOgH6TwSb86E1i/yxGh5HzWWnEwMQv7T/2 Yq2f3fBR+dMGE/6ckKo/8RT5ovmu3cDfNCFlx8w4B7AtYkcI25JWBiZq7v7Rn+puvUCVs GPX4mJ6w1M9yregTJx4HjeH07QLRc860/r1iqkWdHf5nsfPses38UrtyyN4zUYw/Sk5RV B+arUy2b0abnIqBupUXxjvm4EGSi6ROlQPNCTGTuc2+w9KrTJdCAX5cXMmgtNdWXKog== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1795154463; h=Received:DKIM-Signature:From:To:Cc:Subject:Date:Message-ID:X-Mailer: Reply-To:MIME-Version:Lines:X-Developer-Signature:X-Developer-Key: Content-Transfer-Encoding; bh=IzSqWOyyyTM0Ur9wjiaIMlGpbXRdgqu9no5l84mHpZ0=; b=tbEe5n57QVMxzXKdbrp7J6lZWI5OEqvnJsPWGdoFMqoq9Fx0V5SP1PlQur/BsE8ZmJyl +FXDLzSjzrbMss965U7yKntFFyX53xJlOYR6zMTKC3iRiO1CcNmsUFtKgDwQX4iyXFUhU Zdw2hHD6r+ufcSfu5isAHJTopK4W7wDDPZ3HA4xJUXaZWLSAFCnTPU9eYQxWZfDxG25c0 pqhpZiAw9K1vDVAQ7QjjJ5U9n24eSMvWMj8mS+xtDcNf6NrOnlYyAftffSbFI8o9Irduv uao6cRdbbcTMPA9LLSt2R3J/rUobPh9YSKhOUetkX+xSpb1+FO3eSb5k91xQ5JWUFTA== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b=b5KEmi0K; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 24573606A517 for ; Fri, 20 Nov 2026 06:01:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b=b5KEmi0K Received: by smtp.kernel.org (Postfix) with ESMTPSA id A04441F000C6; Fri, 20 Nov 2026 06:01:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1795154463; bh=IzSqWOyyyTM0Ur9wjiaIMlGpbXRdgqu9no5l84mHpZ0=; h=From:To:Cc:Subject:Date:Reply-To; b=b5KEmi0KBNy++KwxbuJ6Lgz8UGPt7yE7gjgQorgQbTNA3W8fea0fZGTG03akcuArA /4LIWQVhXiuJT+sv7RTuH8xbMoq6hHq+oEgJBYu/hr1UJJBRo5PfiWt0lz/6bhUqHX EXIsgys7dADhZQNfj3YtIY5a6pl7iQhE1IDHLd+c= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2026-99751: bpf: Fix skb_pull() BUG in __bpf_redirect_neigh() Date: Fri, 20 Nov 2026 06:52:17 +0100 Message-ID: <2026112021-CVE-2026-99751-09d6@gregkh> X-Mailer: git-send-email 2.56.1 Reply-To: , X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=5273; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=eWn9EpJRmB044KS8CIlXTK0v4eycpNSD0VvUNPj1R4A=; b=kA0DAAIRMUfUDdst+ykByyZiAGr/352g+MnLY9SISclv/DOQCFJiiiJm0MGSeUVSyZqI4jNpi YhdBAARAgAdFiEE9LYMxb94wiFKMT3LMUfUDdst+ykFAmr/350ACgkQMUfUDdst+ylFewCeKPzH ImZ4FcxYbuYVseOGv9VnODgAoM9w2x2AZYMxOJhUdqNYZg4bwj/k X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit From: Greg Kroah-Hartman Description =========== In the Linux kernel, the following vulnerability has been resolved: bpf: Fix skb_pull() BUG in __bpf_redirect_neigh() The issue: This is a follow-up to the short link-layer header fixes from Eric. After vlan pop_eth, a privileged SCHED_ACT BPF program can call bpf_skb_change_head(skb, 1, 0) and then bpf_redirect_neigh(). __bpf_redirect_neigh() calls skb_pull(skb, sizeof(*ethh)) after checking only that mac_header < network_header. Nothing verifies that the MAC header is long enough, that it is linear, or that the IP header the redirect goes on to read is linear either. A SCHED_ACT BPF program can do: bpf_skb_change_head(skb, 1, 0); bpf_redirect_neigh(lo, NULL, 0, 0); after vlan pop_eth. The skb then has mac_len == 1 and only one byte of linear data; skb_pull(ETH_HLEN) trips the skb->len < skb->data_len BUG in __skb_pull(): kernel BUG at ./include/linux/skbuff.h:2839! RIP: skb_pull+0x40/0x50 Call Trace: skb_do_redirect -> packet_xmit -> packet_sendmsg Kernel panic - not syncing: Fatal exception in interrupt The v4 and v6 paths read ip_hdr() and ipv6_hdr() as soon as the MAC header is gone. On the AF_PACKET frame below that leaves headlen == 0 after the pull, so the network header sits at skb->tail and the route lookup reads ip4h->protocol, ip4h->saddr and ip4h->daddr past the linear area. The Fix: Use skb_network_offset(), which is the MAC header span, instead of skb->mac_len. mac_len is zero for locally generated tc egress and netkit packets, while the span still rejects the one-byte header produced by pop_eth + bpf_skb_change_head(skb, 1, 0). The single check also covers the mac_header >= network_header test it replaces. Use pskb_may_pull() to make the Ethernet header linear before it is read or pulled, and to make the IP header linear in both the v4 and the v6 path before ip_hdr()/ipv6_hdr() is read. The header pointers are taken after the pull, since pskb_may_pull() may reallocate skb->head. Conditions to recreate the bug: On x86-64 with 4 KiB pages, enable CONFIG_PACKET, CONFIG_BPF_SYSCALL, CONFIG_NET_SCH_INGRESS, CONFIG_NET_CLS_MATCHALL, CONFIG_NET_ACT_VLAN and CONFIG_NET_ACT_BPF. Run as root with BPF loading, network administration and raw-packet privileges. Bring lo up and attach a SCHED_ACT program that calls bpf_skb_change_head(skb, 1, 0), then returns bpf_redirect_neigh(skb->ifindex, NULL, 0, 0): ip link set lo up tc qdisc add dev lo clsact tc filter add dev lo egress matchall action vlan pop_eth pipe \ action bpf object-file neigh_chghead.o section action Send an untagged ETH_P_IP frame of ETH_HLEN + 8192 bytes through an AF_PACKET/SOCK_RAW socket bound to lo, without PACKET_VNET_HDR or PACKET_QDISC_BYPASS. Use a unicast destination MAC. The sender's skb has a 14-byte linear Ethernet prefix and a fragmented payload; pop_eth removes that prefix and change_head restores only one linear byte. The unfixed neighbor redirect then tries to pull 14 bytes and BUGs. Sending the same frame without pop_eth and change_head leaves the IP header in the frags, which is the route lookup reading past skb->tail. The Linux kernel CVE team has assigned CVE-2026-99751 to this issue. Affected and fixed versions =========================== Issue introduced in 5.10 with commit b4ab31414970a7a03a5d55d75083f2c101a30592 and fixed in 6.12.118 with commit a725401dd629c6fdda47e3a02efed539ac0ed6d0 Issue introduced in 5.10 with commit b4ab31414970a7a03a5d55d75083f2c101a30592 and fixed in 6.18.64 with commit 2009032471be8b9622bf2496ce9c6b06a1015905 Issue introduced in 5.10 with commit b4ab31414970a7a03a5d55d75083f2c101a30592 and fixed in 7.3.5 with commit 890fd9c4e02bc9e477e6365fef4ac8c2262a3b3c Issue introduced in 5.10 with commit b4ab31414970a7a03a5d55d75083f2c101a30592 and fixed in 7.4-rc2 with commit 23503acb214cbefaf3945d05ab9667ff11ae3de9 Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community. Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at https://cve.org/CVERecord/?id=CVE-2026-99751 will be updated if fixes are backported, please check that for the most up to date information about this issue. Affected files ============== The file(s) affected by this issue are: net/core/filter.c Mitigation ========== The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits: https://git.kernel.org/stable/c/a725401dd629c6fdda47e3a02efed539ac0ed6d0 https://git.kernel.org/stable/c/2009032471be8b9622bf2496ce9c6b06a1015905 https://git.kernel.org/stable/c/890fd9c4e02bc9e477e6365fef4ac8c2262a3b3c https://git.kernel.org/stable/c/23503acb214cbefaf3945d05ab9667ff11ae3de9