lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <a535cbab-ecdd-4179-9f00-1960228f8175@blackwall.org>
Date: Thu, 12 Jun 2025 13:30:58 +0300
From: Nikolay Aleksandrov <razor@...ckwall.org>
To: Petr Machata <petrm@...dia.com>, "David S. Miller" <davem@...emloft.net>,
 Eric Dumazet <edumazet@...gle.com>, Jakub Kicinski <kuba@...nel.org>,
 Paolo Abeni <pabeni@...hat.com>, David Ahern <dsahern@...il.com>,
 netdev@...r.kernel.org
Cc: Simon Horman <horms@...nel.org>, Ido Schimmel <idosch@...dia.com>,
 mlxsw@...dia.com, YOSHIFUJI Hideaki <yoshfuji@...ux-ipv6.org>
Subject: Re: [PATCH net-next 07/14] net: ipv6: ip6mr: Fix in/out netdev to
 pass to the FORWARD chain

On 6/9/25 23:50, Petr Machata wrote:
> The netfilter hook is invoked with skb->dev for input netdevice, and
> vif_dev for output netdevice. However at the point of invocation, skb->dev
> is already set to vif_dev, and MR-forwarded packets are reported with
> in=out:
> 
>   # ip6tables -A FORWARD -j LOG --log-prefix '[forw]'
>   # cd tools/testing/selftests/net/forwarding
>   # ./router_multicast.sh
>   # dmesg | fgrep '[forw]'
>   [ 1670.248245] [forw]IN=v5 OUT=v5 [...]
> 
> For reference, IPv4 MR code shows in and out as appropriate.
> Fix by caching skb->dev and using the updated value for output netdev.
> 
> Fixes: 7bc570c8b4f7 ("[IPV6] MROUTE: Support multicast forwarding.")
> Signed-off-by: Petr Machata <petrm@...dia.com>
> Reviewed-by: Ido Schimmel <idosch@...dia.com>
> ---
> 
> Notes:
>      This never worked correctly, hence going through net-next.
> ---
> CC: YOSHIFUJI Hideaki <yoshfuji@...ux-ipv6.org>
> 
>   net/ipv6/ip6mr.c | 3 ++-
>   1 file changed, 2 insertions(+), 1 deletion(-)
> 

Reviewed-by: Nikolay Aleksandrov <razor@...ckwall.org>


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ