Article View: linux.kernel.netdev
Article #12943Re: [PATCH] netfilter: nft_dynset: reject DELETE op when set lacks ->delete
From: Florian Westphal
Date: Mon, 09 Nov 2026 02:34
Date: Mon, 09 Nov 2026 02:34
32 lines
8709 bytes
8709 bytes
Noah Weinberger <NoahWeinberger2003@proton.me> wrote: > Hello, > > nft_dynset_init() checks that the referenced set implements ->update, > but for NFT_DYNSET_OP_DELETE the packet path calls set->ops->delete > unconditionally. Today the only set type with ->update (nft_set_hash) > also implements ->delete, so the call is always valid - but any future > set type implementing ->update without ->delete turns a rule evaluation > into a NULL function call. > > Reject the DELETE op at init time when ->delete is missing, next to the > existing ->update check. > > Affected version/commit: mainline fa4ad798f6f681031775266044ba1b0cf3c670bd (v7.4-rc1, 2026-11-07), net/netfilter/nft_dynset.c:98-101 (eval), 209-217 (init). > Longstanding asymmetry. > > This was found during an assisted (AI-supported) static source review of > mainline fa4ad798f6f681031775266044ba1b0cf3c670bd (v7.4-rc1, 2026-11-07); every code path cited below was re-verified by the > reporter against that tree. The patch below has NOT been compiled and has > NOT been runtime tested, and no reproducer was produced - the triggering > conditions are described above instead. Please treat this as a report for > verification rather than a battle-tested fix. This would have been fine 1 year ago but we no longer have resources and time to reproduce and verify such "fixes". Ask your LLM for a reproducer, run it, show a minimal backtrace. We have LLMs too and we can use them to create enough usless and time-consuming tasks as-is. I have a db of +1k reports just like this one.
Technical Details
Message-ID:
<avExLOsc3ZWRF5hh@strlen.de>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-358975-linux-kernel-netdev=dewy.ruReferences:
<5aybqcVfq3WxYdpbT0Ea6bEWamp-4x10J9FF_5La7SSXJ57a4j176x_t3zUW8Ii2r84MsPX8xx_vNashO2PRWvuO9yNsaxS8YV_4TLc-QHU=@proton.me>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-358975-linux-kernel-netdev=dewy.ru From: fw@strlen.de (Florian Westphal) Newsgroups: linux.kernel.netdev Subject: Re: [PATCH] netfilter: nft_dynset: reject DELETE op when set lacks ->delete Date: Mon, 9 Nov 2026 03:34:20 +0100 Organization: Usenet Network Message-ID: <avExLOsc3ZWRF5hh@strlen.de> References: <5aybqcVfq3WxYdpbT0Ea6bEWamp-4x10J9FF_5La7SSXJ57a4j176x_t3zUW8Ii2r84MsPX8xx_vNashO2PRWvuO9yNsaxS8YV_4TLc-QHU=@proton.me> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: usenet.network; logging-data="253971"; mail-complaints-to="abuse@usenet.network" Cancel-Lock: sha1:QdEDv0YxUdJmwuZUxypM0DC2jFM= sha256:MoNTSzCHAFuVqVa2X63dPaUm73RAMK/FXUKQWr1XL6A= sha1:JpUsAqczkN5AuCZWA/kVb+dGdLQ= sha256:S7V3OIGQuYe6IcqvA8ZuE+zXWf9Ox1gl1jhHjYdnoMo= 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 BC32F1136A3; Mon, 9 Nov 2026 05:36:36 +0300 (MSK) X-Virus-Scanned: Debian amavisd-new at usenet.network X-Spam-Flag: NO X-Spam-Score: -2.951 X-Spam-Status: No, score=-2.951 tagged_above=-9999 required=6.31 tests=[DCC_REPUT_70_89=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] 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 AA2uYbRBaASW; Mon, 9 Nov 2026 05:36:33 +0300 (MSK) X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.234.253.10; helo=sea.lore.kernel.org; envelope-from=netdev+bounces-358975-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 sea.lore.kernel.org (sea.lore.kernel.org [172.234.253.10]) by mail.dewy.ru (Postfix) with ESMTPS id 9000E11369B; Mon, 9 Nov 2026 05:36:28 +0300 (MSK) X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92]) by sea.lore.kernel.org (Postfix) with ESMTP id 0BA3A67C6E; Mon, 9 Nov 2026 02:34:33 +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=1794191672; b=4sWp3DfIStKxiqR7LiG6KX5+dTiU/ZsXcnPzbX0wkwihfVZunH6VxMEUYmv9Nx/FMCss zVkLMVnJV3rfLwYNIqhUwegPhO7HegOsu9ez4Fw8WQQHahi5tYT1/jUQQGD1F8bmrDWGS ZnrC6/uTodlDw5drinOZm6YjfRObM2J8UPtKMzxhnOMd2iJuW64tJw1wcvkJqGplbLBet Km+5YHwLfS4MuOmmw4O2i5gq0F1RzrqOhAu+L9QDJkmd/WkFQHpGF1K1PXBoD/EALFdh2 tSdEagcU/r85Iy4WlWgsmiW9wXmzcfvjvX5RPazOyiTyCi3MLB+K/sRO3JEGGKwHGKg== X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1794191672; 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=yaOg5jE0A5OJDKzqYaU0N0tlT5DHTRA+lI5J6+ouIOE=; b=Eljcs9rWWTq2D7klfy3Kx6Nr0L1OiQ6nzpZhAmHLtZ71ZO1cAdKV2KSXZO22iH41DUBq FD3j+DrVP8wKuZRyBYD0r4fAJXL3dXsLMUvkqJ9nJwycXDukv/BlyAx4Q12j5N6gLX4PY zZazVa1c8aHSMSyMvyuTEtTj/XSsECY9BEqT/iVO2wopJsf3iNpadhXcIGdsJYtQ6Wqph xCXiXdG6UxhMn9WM6sTSmHFhNPwSm/BfnaBTvAg1TyVBoPx/Iw8hdv3SyfH5T/KxDBIRa FKHrJLxUU+eunX5GEJ3Be4zG03jW51T3dwVyOuDBh0/Gk8zj0LxvwCsoEvIqFK0ZuKg== 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 138D3606A330; Mon, 9 Nov 2026 02:34:32 +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=1794191671; b=RZ91KOAttDddoPtFLfLyyaR2bZT9KfeXqt93O20AjUr0soLMYik64+9rVF9Jzi2YR6xU 1CIUXLNLLdnP9E7JPQwq2LKptlWEgXjIUB2IH2rsfbWm+aOyNQlElSpvs8yrR8cv8jmf6 COXXRwd0y8wUNIaBB9Yp2xt4WNfzFH3zC8FiAszVy45a4CUpcbo8biV/zwh9sft6/FH4x U/CoMPD6+rdx6Skm/nIP3xTF99VxLVfnnkanvvshc6FujUiO2aTJm1nw+Nwb6JVavuGPd 83BGPb6Vl+rxX0lbG5JP2zTp7Mvc5w6DGzojh2Ff/tQ5JDK4q7H0VFVt5DAVw/PwDug== X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1794191671; h=DMARC-Filter:Received:Date:From:To:Cc:Subject:Message-ID:References: MIME-Version:Content-Type:Content-Disposition:In-Reply-To; bh=yaOg5jE0A5OJDKzqYaU0N0tlT5DHTRA+lI5J6+ouIOE=; b=nwZPjPLXDN7xqFFUeMtnPKpN/CV1VMBC0Aym+xSLfYJ2b7XtTEH89ukbHfJJIQNoj1Nq 5GnBxGipOLxUvPZUU5tEDPSaY+heeOqYzHDANy8uVBMHKVEMbh0UkiJrd6RKHHvT+zoB3 xxGd/w3AKaWnBRxxxDkOTaIZH7RKJbP0/FIIXQ+VMIy8yERmVBVU+59wkTVt8iEmfgsaF YBE622xFKZjUDMJ7XIrq/pie83EptzDTvkzPFATgvuNkTbJMvrUKTUJmYIMkhOdamQnkj 3Ji85ga3sBt1XhLqyUyDEd2hKrciFtx1fRHOk+ebmwXz6v4VcbteeQMTZhpIwyWiH7w== 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 9E9DE606A320; Mon, 9 Nov 2026 02:34:29 +0000 (UTC) X-DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 9E9DE606A320 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 3DB7160490; Mon, 09 Nov 2026 03:34:21 +0100 (CET) X-Cc: "pablo@netfilter.org" <pablo@netfilter.org>, "kadlec@netfilter.org" <kadlec@netfilter.org>, "netfilter-devel@vger.kernel.org" <netfilter-devel@vger.kernel.org>, "netdev@vger.kernel.org" <netdev@vger.kernel.org>, "linux-kernel@vger.kernel.org" <linux-kernel@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: <5aybqcVfq3WxYdpbT0Ea6bEWamp-4x10J9FF_5La7SSXJ57a4j176x_t3zUW8Ii2r84MsPX8xx_vNashO2PRWvuO9yNsaxS8YV_4TLc-QHU=@proton.me>