Article View: linux.kernel.netdev
Article #26900Re: [PATCH v4] netfilter: nft_ct: reject shared conntrack extension updates
From: Florian Westphal
Date: Fri, 04 Dec 2026 11:12
Date: Fri, 04 Dec 2026 11:12
18 lines
7871 bytes
7871 bytes
zhuorao yang <alex000young@gmail.com> wrote: > An unconfirmed conntrack is mutable and assumes exclusive skb ownership. > Cloned skbs can otherwise reach nft_ct extension paths concurrently and > call nf_ct_ext_add() on the same ct->ext. Since nf_ct_ext_add() uses > krealloc(), this can free and replace one allocation while another CPU > still uses it. > > Reject packets that reference a shared unconfirmed conntrack before any > nft_ct extension allocation is attempted. This covers helper, expect, > timeout, and event-cache extensions without adding a lock to the generic > helper API. Nak. Playing whack-a-mole with stunts like this is getting us nowhere. There are dozen of similar bugs like this all over conntrack. It'll take time to rewrite the core assumptions cleanly. Changes in dozen different places is not the way to go.
Technical Details
Message-ID:
<axKgC3hPW2ZYI3Gn@strlen.de>Path:
mbox-mo1.pugleaf.net!news-fra.pugleaf.net!feed-eu-txt.newsdeef.eu!feed-eu-ch.newsdeef.eu!srl.newsdeef.eu!news.mb-net.net!open-news-network.org!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-377296-linux-kernel-netdev=dewy.ruReferences:
<179636957458.3305.6694386152606528641@kernel.org> <20261204073358.67941-1-alex000young@gmail.com>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-fra.pugleaf.net!feed-eu-txt.newsdeef.eu!feed-eu-ch.newsdeef.eu!srl.newsdeef.eu!news.mb-net.net!open-news-network.org!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-377296-linux-kernel-netdev=dewy.ru From: fw@strlen.de (Florian Westphal) Newsgroups: linux.kernel.netdev Subject: Re: [PATCH v4] netfilter: nft_ct: reject shared conntrack extension updates Date: Fri, 4 Dec 2026 12:12:18 +0100 Organization: Usenet Network Message-ID: <axKgC3hPW2ZYI3Gn@strlen.de> References: <179636957458.3305.6694386152606528641@kernel.org> <20261204073358.67941-1-alex000young@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: usenet.network; logging-data="2748671"; mail-complaints-to="abuse@usenet.network" Cancel-Lock: sha1:RQrbm1Gm0lD39GXCJkoFD32Aic0= sha256:HOEsnK4uHhuxnKJqYVmgqkVUoq0A+xFoNujQB0l3dvk= sha1:rbNunh0RCiFy/iX9wPvoRIItjK8= sha256:lJq+M7CyFb/lGC3wLQ8cgQs4HEhzY+rsMSCzyTdAIt4= Content-Disposition: inline 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 319FC117BC2; Fri, 4 Dec 2026 14:13:14 +0300 (MSK) X-Virus-Scanned: Debian amavisd-new at usenet.network X-Spam-Flag: NO X-Spam-Score: -3.299 X-Spam-Status: No, score=-3.299 tagged_above=-9999 required=6.31 tests=[HEADER_FROM_DIFFERENT_DOMAINS=0.001, MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no 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 WqQOQHCiNDro; Fri, 4 Dec 2026 14:13:11 +0300 (MSK) X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.105.105.114; helo=tor.lore.kernel.org; envelope-from=netdev+bounces-377296-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> X-Authentication-Results: OpenDMARC; dmarc=none (p=none dis=none) header.from=strlen.de X-Received: from tor.lore.kernel.org (tor.lore.kernel.org [172.105.105.114]) by mail.dewy.ru (Postfix) with ESMTPS id 54CA5117B99; Fri, 4 Dec 2026 14:13:05 +0300 (MSK) X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92]) by tor.lore.kernel.org (Postfix) with ESMTP id 9C3712AC6C; Fri, 4 Dec 2026 11:12:41 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1 X-ARC-Seal: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=pass; t=1796382748; b=ohl0i8bg8jm54kq7eghlqD91VlDlqN2DU1uBnw4tR9cqMr7bZIZloO0k2LvoW+Qdg2Na qeBLW7DY5FCOfwp6lZQz1K+1Tf0/ZRczRi6crFFIdG4B1zW3/BwYpc8jACba6OZDJfdk5 7r0AmzN54VglvnC2JDRqJeXECtDYz8NbgiNMvhr2KTZq/xuiowokjs0m1KVXpBTzxamHf G7gNp5yxtFtq2DCxOvkMKRYdg4Ac35p4jjpM+39OuHSnKc0kNJdp7Z1jZV1ry3Xb9+VLm 5Mtc9xUeAxP/aVlRUPlv6KTtFafS+ldq5Piuw38jP5oOHgaMeeJm0FXe3O41s8KdS+w== X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796382748; h=X-Original-To:Received:DMARC-Filter:Received:Date:From:To:Cc:Subject: Message-ID:References:X-Mailing-List:List-Id:List-Post:List-Help: List-Subscribe:List-Unsubscribe:List-Owner:Precedence:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; bh=mfAVc+3CbTVCkNdhjqTLtSa6ujIvz6+ke4v3fIuIVx4=; b=DFUd01Fm3e5UZa6X40KxNJV3l8CRvM/km/Vv5ZReBxDfV9e/0MTHmLj6bRbwTVLhz2qW SQhOcRcJB1qMIvk3xJeZKhKxnqK3OGpoKGSkCxlr989pistY88Lc/UXJgOJjq4VmsRtxx 7h4uG6HCvUzIKE1+3H/etosSQpuULztJ6GW40mSmLwBmC9Uj1IQd45Ok0hbNcdwDFhGN+ zC21Lbqa36XQGXM0h13KMQ65gU3zy8IxqqI/T5upWDSTEJ2Q/L/uBZqWxYHH+ogKIxLzB oPm5FQJefeLcaVNQePsSR1C49lHXGzk6xYgd7xMHaSHktJIyjkHZNLJkDGpwA5AI9+g== X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=none header.from=strlen.de; spf=pass smtp.mailfrom=strlen.de; arc=pass header.oldest-pass=0 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 B9E41606A693; Fri, 4 Dec 2026 11:12:28 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=91.216.245.30 X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796382748; b=JB7zFuq6N6IQONdKAvDuMbNLvVt1/gqs4xQNgC+MRx3+Z3RXgF+W61s3NYw7/peHeLve YV7+h5ZibmrxL1X/TXSHZ3DukVPKTR77BKkKnTVeo9mZEYvRo6tEW+wFpUWCZnx04BlvL 51wuuX6kbmbokJuHnRUB5Fdp1sF8WzuIun/in1vYU/DsYATn20uK83I2K06pFlyrCSjUP 8QNh/fbvrF1E/IE9qdao6/tBa1aYrllDMFmlQ8BRhwE2Ra4Xsb0PgepDr5MsImcGug8Zr ZHU+FizTLhIEV4mtLasS5F3XqUIiJL46N5YwpxrvVKT7pYOlq3Y0zTwa3L9csY1R2lg== X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796382748; h=DMARC-Filter:Received:Date:From:To:Cc:Subject:Message-ID:References: MIME-Version:Content-Type:Content-Disposition:In-Reply-To; bh=mfAVc+3CbTVCkNdhjqTLtSa6ujIvz6+ke4v3fIuIVx4=; b=gCDpB06+ptVbZFiyfiir6a00LcIRK0qANbgyqlGUVh0WXm3nBfTbU2yqHteotvo4Fnp6 JVcGkOlrqqJDCP1KQrltloL7Vls57bzJrddTyOI3xkNLCHZIGPTyHnjphpze8bWO4bCzU 3HqHlwG42wEnLx2xcEnZIuOFj8ZOrQ+483tQRpaX1cklPHHNwJiVSQy4B9RE9OsxGwE7p RIslG6nyJLuA3W88HtIqpo/B3UmzN8CvUZ6WX0SWvqs9hBIFt4ndgVakR0zvl7ZyEkMcf /Qb2rCvH5EAuZNKiBpAyBEjVIlfq/9Qmg3iSyDO8AF9g/wRycFEauSkdniP9e2RRILA== X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none header.from=strlen.de; spf=pass smtp.mailfrom=strlen.de; arc=none smtp.remote-ip=91.216.245.30 X-Received: from Chamillionaire.breakpoint.cc (Chamillionaire.breakpoint.cc [91.216.245.30]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 46D87606A336; Fri, 4 Dec 2026 11:12:26 +0000 (UTC) X-DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 46D87606A336 X-Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=strlen.de X-Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=strlen.de X-Received: by Chamillionaire.breakpoint.cc (Postfix, from userid 1003) id 1092A60255; Fri, 04 Dec 2026 12:12:19 +0100 (CET) X-Cc: pablo@netfilter.org, davem@davemloft.net, edumazet@kernel.org, kuba@kernel.org, pabeni@redhat.com, willemb@google.com, netfilter-devel@vger.kernel.org, coreteam@netfilter.org, netdev@vger.kernel.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 X-In-Reply-To: <20261204073358.67941-1-alex000young@gmail.com>