Article View: linux.kernel.netdev
Article #10862[PATCH net 08/13] netfilter: bridge: use DEBUG_NET_WARN_ON_ONCE in nf_ct_bridge_refrag()
From: Pablo Neira Ayuso
Date: Wed, 04 Nov 2026 09:02
Date: Wed, 04 Nov 2026 09:02
42 lines
9862 bytes
9862 bytes
From: Laveesh Bansal <laveeshb@laveeshbansal.com>
nf_ct_bridge_refrag() warns when skb->protocol is neither IPv4 nor IPv6.
A vlan filtering bridge can get there with a vlan ethertype: if the
protocol of the tag of a frame differs from the vlan_protocol of the
bridge, br_allowed_ingress() moves the tag back into the packet after
NF_BR_PRE_ROUTING, where bridge conntrack has already defragmented it.
Anyone who can send fragments into a port of such a bridge can trigger the
warning, which takes the machine down with panic_on_warn. The packet is
dropped either way, so only warn on kernels built with CONFIG_DEBUG_NET.
This only avoids the warning. Such fragmented packets are still dropped.
syzbot reported the warning. It keeps triggering on CONFIG_DEBUG_NET
kernels until the vlan tag is handled, which is left for a follow-up:
https://syzkaller.appspot.com/bug?extid=a8ba738fe2db6b4bb27f
Fixes: 3c171f496ef5 ("netfilter: bridge: add connection tracking system")
Assisted-by: LLM
Signed-off-by: Laveesh Bansal <laveeshb@laveeshbansal.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
---
net/bridge/netfilter/nf_conntrack_bridge.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/bridge/netfilter/nf_conntrack_bridge.c b/net/bridge/netfilter/nf_conntrack_bridge.c
index b5444335b86f..8c83dc05114b 100644
--- a/net/bridge/netfilter/nf_conntrack_bridge.c
+++ b/net/bridge/netfilter/nf_conntrack_bridge.c
@@ -358,7 +358,7 @@ nf_ct_bridge_refrag(struct sk_buff *skb, const struct nf_hook_state *state,
nf_br_ip6_fragment(state->net, state->sk, skb, &data, output);
break;
default:
- WARN_ON_ONCE(1);
+ DEBUG_NET_WARN_ON_ONCE(1);
return NF_DROP;
}
--
2.47.3
Technical Details
Message-ID:
<20261104090224.750548-9-pablo@netfilter.org>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-356310-linux-kernel-netdev=dewy.ruReferences:
<20261104090224.750548-1-pablo@netfilter.org>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-356310-linux-kernel-netdev=dewy.ru From: pablo@netfilter.org (Pablo Neira Ayuso) Newsgroups: linux.kernel.netdev Subject: [PATCH net 08/13] netfilter: bridge: use DEBUG_NET_WARN_ON_ONCE in nf_ct_bridge_refrag() Date: Wed, 4 Nov 2026 10:02:19 +0100 Organization: Usenet Network Message-ID: <20261104090224.750548-9-pablo@netfilter.org> References: <20261104090224.750548-1-pablo@netfilter.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Injection-Info: usenet.network; logging-data="3357526"; mail-complaints-to="abuse@usenet.network" Cancel-Lock: sha1:R9Vcnpg63oZVHdOaw6qPr/tAVZg= sha256:UhWszwslXMv0urQN3BhOLR+X6BpZbil/xXjiRkGgy58= sha1:RjX5cwKjsIGDjQ35pM9vtKxjeIA= sha256:rXg5LyL5EdGoL+t0i3fC0GowyDvken9AGL580djOFco= List-ID: <netdev.vger.kernel.org> X-Mailpost-Empty-Hdrs: X-Spam-Level X-Received: from localhost (localhost [127.0.0.1]) by mail.dewy.ru (Postfix) with ESMTP id 43968112B42; Wed, 4 Nov 2026 12:05:15 +0300 (MSK) X-Virus-Scanned: Debian amavisd-new at usenet.network X-Spam-Flag: NO X-Spam-Score: -3.15 X-Spam-Status: No, score=-3.15 tagged_above=-9999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HEADER_FROM_DIFFERENT_DOMAINS=0.249, MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no X-Authentication-Results: mail.dewy.ru (amavisd-new); dkim=pass (2048-bit key) header.d=netfilter.org X-Received: from mail.dewy.ru ([127.0.0.1]) by localhost (mail.dewy.ru [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id THUF7WaeOA9m; Wed, 4 Nov 2026 12:05:12 +0300 (MSK) X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.232.135.74; helo=sto.lore.kernel.org; envelope-from=netdev+bounces-356310-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> X-Authentication-Results: OpenDMARC; dmarc=none (p=none dis=none) header.from=netfilter.org X-Received: from sto.lore.kernel.org (sto.lore.kernel.org [172.232.135.74]) by mail.dewy.ru (Postfix) with ESMTPS id 032FE112B41; Wed, 4 Nov 2026 12:05:04 +0300 (MSK) X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92]) by sto.lore.kernel.org (Postfix) with ESMTP id 46D086066F0; Wed, 4 Nov 2026 09:03:37 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.remote-ip=127.0.0.1 X-ARC-Seal: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=fail; t=1793782979; b=iNx7ODBb7vIH3EpHHzTJfCdf5CvVekHHkgXjWTFVqPyKepuTWOJM0iPAB2CHCrQDYzJN kPmqJBSAT7E7Cqo0vKuKkX9nJUf/CAxzWPVGvOJYLgG24QYLWWXZHdlKqXM70XLf58IYt v7PihPod7E80BqBYof9yjsJk12RuwyKrZcL63GOjhUC0bDo3Z5pIPM5l5Cd1wZxXlFbly AtD9tBCQzF0ei5T7OWTV9Q5JCsofWc6egXnfGnU62pJQPRJC6ZNegd6J0rhuIHsjL9+k6 4vLs0S5GqcVsRe7fSZHPc6P0fDTw+JMi5wC4FfOvVppeUOEzsFolu21LpitHYQt0m/g== X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1793782979; h=X-Original-To:Received:DMARC-Filter:DKIM-Signature:Received:From:To: Cc:Subject:Date:Message-ID:X-Mailer:In-Reply-To:References: X-Mailing-List:List-Id:List-Post:List-Help:List-Subscribe: List-Unsubscribe:List-Owner:Precedence:MIME-Version: Content-Transfer-Encoding; bh=bRwI7uwCHVVt6T7DMLyhA8VEKQ0FrttDo22yhPZt5LE=; b=ifA/WdAU8P67RlHrF0sBVNVawDsnZW4EvR2IaP5E78RV+zWw0LhQQ1JYIG+zB/5FCMuh xjIqW6WJc7NVHlQ/ozU+imkFlmAMB1+mreMGSqy2rh2VCUrcEcODEENcmMSCSRQTNXVHy fLn3KzjpAoruPdQeUdeZOMX4wQ1ILQW0MnOQYpecNphmavtnzQOUDmTYg/FULd5/XHK0Y NaV691BG6rLt1uVdYQ5lvVtSnCIezFvwAR+9lGT20tfpRgdl6KUuxYzd9rA382PpSqub+ 8y7OgC29m+zf86D5o5A/9h6Cv6oHcMEhlPKgt1d8iD+yGOKFHtZdsEnrTmlTOy1WI2w== X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dkim=pass header.d=netfilter.org header.i=@netfilter.org header.a=rsa-sha256 header.s=2025 header.b=ERwVzww6; dmarc=none header.from=netfilter.org; spf=pass smtp.mailfrom=netfilter.org; arc=fail smtp.remote-ip=127.0.0.1 X-Received: from localhost.localdomain (localhost [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 2E83F6082BD3; Wed, 4 Nov 2026 09:02:59 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key, unprotected) header.d=netfilter.org header.i=@netfilter.org header.a=rsa-sha256 header.s=2025 header.b=ERwVzww6 X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=217.70.190.124 X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1793782978; b=b4wrmoTqeYQbyGk8vN0rgotBXKgekSi4XYjo2IvwbSIbPZsuJL6VqvJ8Qht/azwRGXPJ mLvmYuvEZtPGwE+YlmB4884fuufdyXmIUM5qMyCfycQxMDQUqwddRu8X7mJTJXGNKywog LnDc5e7Tr5c5b5n/VuY6nIH5f50k6e7yGpYHtGRYp2Y19aeRn/hUGLlbQ1nMzhO7Y/8UU BRovlpdo7n0THU9mw7eB3ByBxG5tVy/cB9XDGu/YWNc1j1S9O7W6IKSppRzoAwT7B2S3O WLY5Wvkg1v/xP/j4hlkv5as2XsBKCbs3HlwztRQxG0z4ul0lQebn3WBvwM1uIrk6XaQ== X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1793782978; h=DMARC-Filter:DKIM-Signature:Received:From:To:Cc:Subject:Date: Message-ID:X-Mailer:In-Reply-To:References:MIME-Version: Content-Transfer-Encoding:X-Spam-Status:X-Spam-Checker-Version; bh=bRwI7uwCHVVt6T7DMLyhA8VEKQ0FrttDo22yhPZt5LE=; b=YPxKW93Oi8rouehgnibxmml+UrutGF2HKpEIWbBIc6Ex2FKOqcGjMnDbMXRkjYcLY60E H0PZJZDp1Ju4lQs6WQDcpfT5rW5ZnCD/noQa5OFObgY+fI04W+Fj6xkbM4jb9psAGk5UB R8cpngA2FPwHn1N039G15GA7vN3UN/EJBmQG/nBK86ZQig63ZkLTaSsktSSp7XL2RR9mO DZxJylX3ZZB6eE6D6itGqTGY9lRjtLWKuKEbXgqWmt4qP41JrcgXloTC1y0s7qKzm4ZDa uc8IjJgShEhmC3AYSvA8JopLgxIbH6AOXSiEmeo1Ccw8rJOksBwqhkORxGbgJ1z8PaA== X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none header.from=netfilter.org; spf=pass smtp.mailfrom=netfilter.org; dkim=pass header.d=netfilter.org header.i=@netfilter.org header.a=rsa-sha256 header.s=2025 header.b=ERwVzww6; arc=none smtp.remote-ip=217.70.190.124 X-Received: from mail.netfilter.org (mail.netfilter.org [217.70.190.124]) (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 4E4A6606D804; Wed, 4 Nov 2026 09:02:45 +0000 (UTC) X-DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 4E4A6606D804 X-Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=netfilter.org X-Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=netfilter.org X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=netfilter.org; s=2025; t=1793782963; bh=bRwI7uwCHVVt6T7DMLyhA8VEKQ0FrttDo22yhPZt5LE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ERwVzww6iR6P6s5bjkUKbLFdZTpr97P79pcliAuw899dDOSm8RH0pRnOCBsc4PjJs uBttg2EpXalahmZjxPgNRisAMKcdBGV5zq3ml58DCs5+PAeVdk1bN2TeDtWRXU/7dJ hkBjORxQq4XA6p1WFxttJvWCERyhFydwEh4+72SKRaSmJb8QOOsg7+vNUqtcqQBqRD sycrCg9Dom6mru5gLVg2WPR2Urai/jF5DcUfn6iDy4QW74PWnSSYVRdzDZh3DZ3PnJ lwzMfhfBKY8Ekxlx7paHWH+S7+e5AbveVGlQC6A4cA5mNAayV1mYltJ7MO0ubvb/zF ALpZ5/pMsa0LQ== X-Received: from localhost.localdomain (mail-agni [217.70.190.124]) by mail.netfilter.org (Postfix) with ESMTPSA id 39C066007D; Wed, 4 Nov 2026 10:02:43 +0100 (CET) X-Cc: davem@davemloft.net, netdev@vger.kernel.org, kuba@kernel.org, pabeni@redhat.com, edumazet@kernel.org, horms@kernel.org, fw@strlen.de, ja@ssi.bg X-Mailer: git-send-email 2.47.3 X-In-Reply-To: <20261104090224.750548-1-pablo@netfilter.org> X-Mailing-List: netdev@vger.kernel.org X-List-Post: <mailto:netdev@vger.kernel.org> X-List-Help: <mailto:netdev+help@vger.kernel.org> X-List-Subscribe: <mailto:netdev+subscribe@vger.kernel.org> X-List-Unsubscribe: <mailto:netdev+unsubscribe@vger.kernel.org> X-List-Owner: <mailto:netdev+owner@vger.kernel.org> X-Precedence: list