From: Leonard Lausen <leonard@lausen.nl>
To: netdev@vger.kernel.org
Cc: leonard@lausen.nl, David Ahern <dsahern@kernel.org>,
Ido Schimmel <idosch@nvidia.com>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@kernel.org>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Simon Horman <horms@kernel.org>,
Pablo Neira Ayuso <pablo@netfilter.org>,
Florian Westphal <fw@strlen.de>, Phil Sutter <phil@nwl.cc>,
Shuah Khan <shuah@kernel.org>,
Daniel Borkmann <daniel@iogearbox.net>,
netfilter-devel@vger.kernel.org, coreteam@netfilter.org,
linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH net v2 0/2] ipv6: honor prefix-length suppression in raw FIB lookups
Date: Sun, 15 Nov 2026 11:44:30 +0000 [thread overview]
Message-ID: <20261115114434.10343-2-leonard@lausen.nl> (raw)
Following Sashiko's automated review, v2 is limited to
suppress_prefixlength. The review identified that v1 evaluated
suppress_ifgroup before final multipath selection; I reproduced the
resulting disagreement between raw and ordinary lookups. Interface-group
suppression needs separate work and is left unchanged in this revision.
Prefix suppression is sufficient for the reported VPN failure: nftables
can otherwise return a main-table default that an ordinary lookup
suppresses before continuing to the VPN table. Strict reverse-path
filtering then drops replies arriving through the VPN.
Patch 1 adds a raw prefix-length check while preserving RTF_REJECT results
and leaving dst-based handling unchanged. Patch 2 extends nft_fib.sh with
six checks using its existing topology and counter helper.
Changes since v1:
- Drop raw suppress_ifgroup support and its tests. Table lookup can return
a different nexthop from the final multipath selection used by ordinary
routing and BPF, so suppression cannot safely use that initial device.
- Install the router's logging RPF rules after the suppression checks and
policy-rule cleanup. This prevents neighbour advertisements from being
logged and dropped during intentionally different reverse-route states.
- Add a blackhole nexthop-object case, which distinguishes rejection flags
in the lookup result from those in the FIB entry.
V1: https://lore.kernel.org/netdev/20261110131638.15004-3-leonard@lausen.nl/
Tested on the rebuilt v7.4-rc2-based kernel: all six added checks pass,
and the full nft_fib.sh run exits 0. A run with an eight-second delay also
passes, allowing neighbour discovery to complete. Separate probes confirm
that reject routes remain terminal and raw interface-group suppression
is unchanged.
OpenAI Codex assisted with investigation, reproduction, implementation,
tests and descriptions. The prompts asked it to investigate the
Wireguard VPN failure.
Leonard Lausen (2):
ipv6: honor prefix-length suppression in raw FIB lookups
selftests: netfilter: cover IPv6 FIB prefix suppression
net/ipv6/fib6_rules.c | 9 ++-
.../selftests/net/netfilter/nft_fib.sh | 63 ++++++++++++++++++-
2 files changed, 70 insertions(+), 2 deletions(-)
base-commit: 7475ea8b58616b33c04afb976cf0fbaad9dd63fb
--
2.55.0
next reply other threads:[~2026-11-15 11:46 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-15 11:44 Leonard Lausen [this message]
2026-11-15 11:44 ` [PATCH net v2 1/2] ipv6: honor prefix-length suppression in raw FIB lookups Leonard Lausen
2026-11-15 15:46 ` Ido Schimmel
2026-11-15 11:44 ` [PATCH net v2 2/2] selftests: netfilter: cover IPv6 FIB prefix suppression Leonard Lausen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261115114434.10343-2-leonard@lausen.nl \
--to=leonard@lausen.nl \
--cc=coreteam@netfilter.org \
--cc=daniel@iogearbox.net \
--cc=davem@davemloft.net \
--cc=dsahern@kernel.org \
--cc=edumazet@kernel.org \
--cc=fw@strlen.de \
--cc=horms@kernel.org \
--cc=idosch@nvidia.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=netfilter-devel@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=pablo@netfilter.org \
--cc=phil@nwl.cc \
--cc=shuah@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox