Article View: linux.kernel.netdev
Article #16205Re: [RFC net-next v2 00/18] net: introduce ipxlat stateless IPv4/IPv6 translation
From: Ralf Lici
Date: Sat, 14 Nov 2026 09:47
Date: Sat, 14 Nov 2026 09:47
61 lines
11414 bytes
11414 bytes
On Fri, 06 Nov 2026 22:17:57 +0800, Xavier HSINYUAN <XavierHsinyuan@outlook.com> wrote: > Hi Ralf, > Hi Xavier, > Thanks for your v2 series! > Thanks for the review. > Here is a question about netfilter hooks in ipxlat-lwt. In RFC v1, > netdev-based ipxlat allows POST_ROUTING rules to be applied for > original-family before translation. Currently LWT path translates first > and does not check nf_hooks_lwtunnel to optionally run original-family > POST_ROUTING before translation. > > Is this difference intentional since it keeps LWT path simple and leave > such cases to netdev path, or would an optional pre-translation pass in > LWT path also be worth considering? > Actually v2 has no netdevice attachment any more, the LWT is the only harness in this series. Aside from that, yes, the difference you describe follows from the v2 contract. The selecting route terminates original-family processing, so that family only sees PRE_ROUTING (received) or LOCAL_OUT (local), and FORWARD/POST_ROUTING/LOCAL_IN run in the translated family only. That is indeed the first open question in the cover letter. Looking into it again, there seems to be two concrete problems with that contract: - original-family conntrack entries are created at the entry hook and never confirmed, so stateful rules in that family see replies as new or invalid and a conventional ct state established firewall drops them; - SNAT in the original family before translation is not possible, which rules out NAT44 in front of a CLAT and the NAPT66-based NAT64 recipe from the v1 documentation. So I do not consider the current behaviour settled. nf_hooks_lwtunnel is one way to add an original-family exit hook, and seg6 is a good precedent for the hook placement. I am less sure about the gate itself because it is global, cannot be switched off again, and is off by default, so the default configuration would keep the problem. Two alternatives I am evaluating are calling the exit hook unconditionally, and moving the translation point to the LWT xmit stage so the original family completes its normal path. I will come back with a concrete proposal and a per-hook table. Which setup do you have in mind: SNAT before translation, filtering, or accounting? -- Ralf Lici Mandelbit Srl
Technical Details
Message-ID:
<20261114094722.114623-1-ralf@mandelbit.com>Path:
mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srl.newsdeef.eu!news.mb-net.net!open-news-network.org!2.eu.feeder.erje.net!feeder.erje.net!feeder2.feed.ams11.usenet.farm!feed.usenet.farm!feeder.usenetexpress.com!tr3.eu1.usenetexpress.com!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-363163-linux-kernel-netdev=dewy.ruReferences:
<TYTPR01MB11000E65B4D5C27C27D7414B4CA762@TYTPR01MB11000.jpnprd01.prod.outlook.com>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srl.newsdeef.eu!news.mb-net.net!open-news-network.org!2.eu.feeder.erje.net!feeder.erje.net!feeder2.feed.ams11.usenet.farm!feed.usenet.farm!feeder.usenetexpress.com!tr3.eu1.usenetexpress.com!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-363163-linux-kernel-netdev=dewy.ru From: ralf@mandelbit.com (Ralf Lici) Newsgroups: linux.kernel.netdev Subject: Re: [RFC net-next v2 00/18] net: introduce ipxlat stateless IPv4/IPv6 translation Date: Sat, 14 Nov 2026 10:47:21 +0100 Organization: Usenet Network Message-ID: <20261114094722.114623-1-ralf@mandelbit.com> References: <TYTPR01MB11000E65B4D5C27C27D7414B4CA762@TYTPR01MB11000.jpnprd01.prod.outlook.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Injection-Info: usenet.network; logging-data="1543643"; mail-complaints-to="abuse@usenet.network" Cancel-Lock: sha1:S81Yi+pe3xkqzNeW/Id4bwUJd0c= sha256:yaM8BJEhC/KUustI6OoyM4f8BRy5zDEijiXEUeoNQzw= sha1:etbtwJuHPiYhadi55LOkptrQWfg= sha256:lM5euuwRXIuH3N1BDd8Q4cveA1UZmZLO0lYrnXPYD88= 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 5A0E6114798; Sat, 14 Nov 2026 12:48:20 +0300 (MSK) X-Virus-Scanned: Debian amavisd-new at usenet.network X-Spam-Flag: NO X-Spam-Score: -0.676 X-Spam-Status: No, score=-0.676 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, SORTED_RECIPS=2.474, 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=mandelbit.com 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 oUW-oFWtR3V8; Sat, 14 Nov 2026 12:48: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-363163-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> X-Authentication-Results: OpenDMARC; dmarc=none (p=none dis=none) header.from=mandelbit.com X-Received: from sto.lore.kernel.org (sto.lore.kernel.org [172.232.135.74]) by mail.dewy.ru (Postfix) with ESMTPS id 5FF63114796; Sat, 14 Nov 2026 12:48:01 +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 B3F7D6119E3; Sat, 14 Nov 2026 09:47:50 +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=1794649665; b=teMTgDi/mlIpBvA0QzsMy0mhEIztuMcGW7RFnp2RiMb881xLsOv0DOQYTTTrdtS7rcJx OWgmr71zsGl2/x2tQal59N67z1vKDIzsKeGqXTfUMQSHOwSs4YEikEmFHbvcJ/Pnn6SEl EaOLqDM5+HdV+EaOMMLewNzZlkGFQ+efCOqo39aYR516g2vnunJpjwl7feZoyRngHv/Xd /WUfHwfKtbzW8kjqqCufaUb21FiK60rzfoNREJayEvBaJhHG6PMdxBiMHoVWx/PFvTl6V YCERBFRg8Y8LEUE/JGwZkXbfrNCyjKnRkQsTInPxaLe1EJ97VI/qbeqL7HEaeu/f60Q== X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1794649665; h=X-Original-To:Received:DMARC-Filter:Received:DKIM-Signature: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:X-Rspamd-Queue-Id; bh=PTY1o7j7L5nX7oMObMEPbTXGH2Y/CuCX5bnofZ59I48=; b=5DkwBWiSn9rviO5uajG4I0ceS5MLuZ7GDa5ZvyM4LPJmZU+lrrEb8MBRNlwI6K5FxWh1 VayYQR8vUMgFTl0p30PlJr5Rmo77uHg34Mm8u+AvkfW36NnKUfy7cMweFIey9leR/OLpR powSjt1db0pN0XPrlGQhDHC8hSDZjlBO8s+XkbdMBoqyHTDr7dm4iWoCMbSUAbguyZTir dE2rpA2m3u9q/idNS+05Ftm4defvgx8jC9GC8ns8AL5iOo3LfWxDwxv+QrerSKQdmE1kt 3P4A+521s4/MEhPKU9o/1AcbdQilCieLrNFFtj/WzBxF41UiPMX4xjGzITKJKy/n1FQ== X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dkim=pass header.d=mandelbit.com header.i=@mandelbit.com header.a=rsa-sha256 header.s=MBO0001 header.b=s6oNpMlq; dmarc=none header.from=mandelbit.com; spf=pass smtp.mailfrom=mandelbit.com; 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 003EE606A33B; Sat, 14 Nov 2026 09:47:45 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key, unprotected) header.d=mandelbit.com header.i=@mandelbit.com header.a=rsa-sha256 header.s=MBO0001 header.b=s6oNpMlq X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=195.10.208.40 X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1794649659; b=wmyYsAiKE1akr/rg93tZCl5V6DZpMxBr4ADlNptqJ753sCJQYZISYzPjoZfyu76es4L/ y4hrRDhhSJ2zBGbsrVtlBIYZmXTVtB751eALVgd9Fq89YmBhTzqqKMIuL3CWgXsj+HPxV TeGFRPoNfbxdD85lFsjFymqa4WLWHsM/35bc+y9wDhy9EZpDdDL495NJZJJUsOuRNTuwq 7vHXwXwaJxW0V4LGAOpbmgubLQOndVmTOm0fk7ANXPBS/VIm60EQGiShQ4mfSstZj8Ko1 4BGD3REtzgd3YeYzdPuBC036Xh3xCooW8XKnCt/vtLAnymS0Za5G2dXAQ/3FDkB5BRg== X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1794649659; h=DMARC-Filter:Received:DKIM-Signature:From:To:Cc:Subject:Date: Message-ID:X-Mailer:In-Reply-To:References:MIME-Version: Content-Transfer-Encoding:X-Rspamd-Queue-Id; bh=PTY1o7j7L5nX7oMObMEPbTXGH2Y/CuCX5bnofZ59I48=; b=Nhy099poo/5z1DA+hatWu18ugCAA/gypR+LVPdk8tuFsVcdXql8OH1ECNktpX/Sf26Pd h15VhHYbW7Dlf3LAys+WyM1oM7MMKpbeetX4rU4n4EzbjypuczLTxVt5Y11vgA8wXTmT5 l+Tsm1Ls5j/jKdm4Na7TC7GlZ16K4iNcqleXt5HBz4ay8t+iAWGIEeuxjiSu11rApKkjV AQlpR6c8zvjFgiGz1PhEb095Z0ctb6qCfaLTEB1xXqkQnNYPaas5FYffw1U3pZbaBDKOL NqgqBcBX6ukvOMVe+sB5EDUDns5PKtarSQhueI0W/jKdQz/viVr8N5fDaFYukrJ60Nw== X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none header.from=mandelbit.com; spf=pass smtp.mailfrom=mandelbit.com; dkim=pass header.d=mandelbit.com header.i=@mandelbit.com header.a=rsa-sha256 header.s=MBO0001 header.b=s6oNpMlq; arc=none smtp.remote-ip=195.10.208.40 X-Received: from mout-b-210.mailbox.org (mout-b-210.mailbox.org [195.10.208.40]) (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 F302E606A327; Sat, 14 Nov 2026 09:47:37 +0000 (UTC) X-DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org F302E606A327 X-Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=mandelbit.com X-Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=mandelbit.com X-Received: from smtp1.mailbox.org (smtp1.mailbox.org [IPv6:2001:67c:2050:b231:465::1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519MLKEM768 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-b-210.mailbox.org (Postfix) with ESMTPS id 4jRTnL2sTRzFqbv; Sat, 14 Nov 2026 10:47:34 +0100 (CET) X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mandelbit.com; s=MBO0001; t=1794649654; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=PTY1o7j7L5nX7oMObMEPbTXGH2Y/CuCX5bnofZ59I48=; b=s6oNpMlqY5TOV7G82Irnq1EDMUVG13acT8vn2wqkq1tMD7NBwCQRx2xY/R9xsQL1kHxWvo sxKMJfS/rFD7Gr3id9jDnz7lsZ7oNmec1Z4YaatiCh9rTkAaOs9VcfFBcNy+TABu+AuTCr HI3Tasu6gs8gwNWPGct2JI3PWuRbBcIKgCZ6a1BZxkE7RWy7ZyQGCmTw8gswsfQClQc5H8 v0Qb6LjjzAcimuTnD0/6+t1F66yjkXy40FSmqpUsgLC7N+oMLbSY+Q71VvBP2juKT8zzP1 OyiDIX+cZPNak7kGmmRilFxc+YjoEu9CXRmeueLh8PAuEvu/E03D4qEmQSV4QA== X-Authentication-Results: outgoing_mbo_mout; dkim=none; spf=pass (outgoing_mbo_mout: domain of ralf@mandelbit.com designates 2001:67c:2050:b231:465::1 as permitted sender) smtp.mailfrom=ralf@mandelbit.com X-Cc: antonio@mandelbit.com, bgalvani@redhat.com, coreteam@netfilter.org, davem@davemloft.net, dsahern@kernel.org, dxld@darkboxed.org, edumazet@kernel.org, fw@strlen.de, horms@kernel.org, idosch@nvidia.com, kuba@kernel.org, linux-kernel@vger.kernel.org, netdev@vger.kernel.org, netfilter-devel@vger.kernel.org, pabeni@redhat.com, pablo@netfilter.org, phil@nwl.cc, toke@kernel.org, xavierhsinyuan@outlook.com X-Mailer: git-send-email 2.56.0 X-In-Reply-To: <TYTPR01MB11000E65B4D5C27C27D7414B4CA762@TYTPR01MB11000.jpnprd01.prod.outlook.com> 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-Rspamd-Queue-Id: 4jRTnL2sTRzFqbv