From nobody Thu Oct 22 17:31:44 2026 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4j9Y9Y1ly6z6xP1g for ; Thu, 22 Oct 2026 17:31:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 4j9Y9X5Nrkz3Gl3 for ; Thu, 22 Oct 2026 17:31:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1792690304; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=MqOn5h9BvGIvTIPRM33tbjl/s1Pi45V39R28uVzJs7Q=; b=m0o2QWTHajAjH683DPjVMkDSeXyaAuo0Oz5OB0EyuFSGghdeX+fsRQMqL/QSxyDe1X2YOg jXZfQHCij+kWn1KjsjP7SyCt44KjcNmsf4tNP42V5d1hn3vFYM0TTJpEw6F3EeNifn5Q5r m4WKzfHo5f4uBkElqTzR9A9vvC+AsXWc2upSHFsN+7e+W+VX9RdYi6jf0VKJFEgkOIo9xu 8ZJLc5VsgSETwN+ht7NR0WYPdSdfG4qhTS5eofE/ioB3IXwP91yxnQi7Qtf0vjEIJjrzhG Sm6z+OLpKtth6X96PcN1yBl+RH61CWIKrVyc6YteV8ziV7JKfsFtXfQYZKqxfg== ARC-Seal: i=1; a=rsa-sha256; d=freebsd.org; s=dkim; cv=none; t=1792690304; b=LQ9vLaEgEA+Hncx10eg4c9vQnqH7kWcT5zeQ8t2dr2TzccwP8Fv5rlUs0F1Uj1NlJ9MkEH HRN98/IwtZMqDYHzWzCcyhJxUXKCmgDsZKfv4eHgRbuyVnAw3sqmMmJP39JnBRfTLn2lz4 wIjJBVCQMmqXvCoD52UY64qeKfDhynGXA6+HP1AMTJO2O75IxsJ069jhR5nz/n/YGhXOXr Z9xQ0ABqV1Lt9qWZi2ls1olf+w8SMGyvWOF/R9SwkwQHEmtIu5Rlmj8Qshu3D6PzKnIvjv PX6/hhi3wqCPRI4ngO2Z8w+gwfU/D3LoPuZ9dN3ZBe/g7dEj1BntqA3D+9vATg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1792690304; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=MqOn5h9BvGIvTIPRM33tbjl/s1Pi45V39R28uVzJs7Q=; b=xWx4syCM9c/Kp6iTNb5XqZe3fH+d/5KZ+GLJZqwYdUszKmab+VEer7AhiNLGP8LgvqF3g8 UT4Vm2bt2QyIlB6CtME9mdD3rmkPrRT4TblQca9/o0Vf/DFF+Ma6mJcxkjep3xD7N5xRX3 wdcBxt74wwdUW/gBBr4r1oxxIniFI3xL7Gbz4s4X9th+2vgZ9hYiuzTm+2kxs9h5qGmSWD r2fNMiS+q6vAiG2OdNkX0vbMQ+yUtD3onERR4HsQ1qV5t9ef1wutR1QfopuXuPBZBG/HhR byK2pIxemnu9HmBxi2PtxBqX2iXPX7RUxeezj2BAvPTDlLR021bgO9mEzZcPnA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4j9Y9X4gN0zsHw for ; Thu, 22 Oct 2026 17:31:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3d0bc by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 22 Oct 2026 17:31:44 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org Cc: Andrew Griffiths From: Mark Johnston Subject: git: b27830cc1085 - stable/15 - ipfilter: fix inverted range check on the lookup iterator unit List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org List-Id: Commit messages for all branches of the src repository List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: b27830cc108544bd5666f46fce839f61e84eba3f Auto-Submitted: auto-generated Date: Thu, 22 Oct 2026 17:31:44 +0000 Message-Id: <6ada4880.3d0bc.5a401445@gitrepo.freebsd.org> The branch stable/15 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=b27830cc108544bd5666f46fce839f61e84eba3f commit b27830cc108544bd5666f46fce839f61e84eba3f Author: Andrew Griffiths AuthorDate: 2026-09-06 20:44:35 +0000 Commit: Mark Johnston CommitDate: 2026-10-22 15:45:40 +0000 ipfilter: fix inverted range check on the lookup iterator unit ipf_lookup_iterate() validates iter.ili_unit with if (iter.ili_unit < IPL_LOGALL && iter.ili_unit > IPL_LOGMAX) or alternatively, if (iter.ili_unit < -1 && iter.ili_unit > 7) ipf_lookup_add(), ipf_lookup_delete(), ipf_lookup_stats() ipf_lookup_flush() validate with a || Submitted by calif.io for the OpenAI Patch The Planet program Signed-off-by: Andrew Griffiths Reviewed by: markj MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D59726 (cherry picked from commit cb035c19c3e76d547eb7d4bca1f1106b117c27a0) --- sys/netpfil/ipfilter/netinet/ip_lookup.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/netpfil/ipfilter/netinet/ip_lookup.c b/sys/netpfil/ipfilter/netinet/ip_lookup.c index a52dbef00166..b0fb2b09c325 100644 --- a/sys/netpfil/ipfilter/netinet/ip_lookup.c +++ b/sys/netpfil/ipfilter/netinet/ip_lookup.c @@ -663,7 +663,7 @@ ipf_lookup_iterate(ipf_main_softc_t *softc, void *data, int uid, void *ctx) if (err != 0) return (err); - if (iter.ili_unit < IPL_LOGALL && iter.ili_unit > IPL_LOGMAX) { + if (iter.ili_unit < IPL_LOGALL || iter.ili_unit > IPL_LOGMAX) { IPFERROR(50038); return (EINVAL); }