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]
Date:   Thu, 1 Dec 2022 17:21:10 +0200
From:   Leonid Komaryanskiy <lkomaryanskiy@...il.com>
To:     Ido Schimmel <idosch@...sch.org>, netdev@...r.kernel.org
Cc:     dmytro_firsov@...m.com, petrm@...dia.com, davem@...emloft.net,
        kuznet@....inr.ac.ru, yoshfuji@...ux-ipv6.org
Subject: Re: ip_forward notification for driver

Ido Schimmel, thank you for your advice.
We checked netevents (NETEVENT_IPV4_MPATH_HASH_UPDATE and
NETEVENT_IPV4_FWD_UPDATE_PRIORITY_UPDATE) but unfortunately, netevents
notifier doesn't trigger at all in case of changing value in
/proc/sys/net/ipv4/ip_forward. We see, that these events come in the
case of modifying /proc/sys/net/ipv4/fib_multipath_hash_policy, but
not for ip_forward. Shell we prepare an upstream patch with notifier
for ip_forward modify netevent?

On Thu, Nov 10, 2022 at 10:15 AM Ido Schimmel <idosch@...sch.org> wrote:
>
> On Thu, Nov 10, 2022 at 09:51:35AM +0200, Leonid Komaryanskiy wrote:
> > I'm working on L3 routing offload for switch device and have a
> > question about ip_forwarding. I want to disable/enable forwarding on
> > the hardware side according to changing value in
> > /proc/sys/net/ipv4/ip_forward. As I see, inet_netconf_notify_devconf
> > just sends rtnl_notify for userspace. Could I ask you for advice, on
> > how can I handle updating value via some notifier or some other Linux
> > mechanism in driver?
>
> You can look into netevents. See NETEVENT_IPV4_MPATH_HASH_UPDATE and
> NETEVENT_IPV4_FWD_UPDATE_PRIORITY_UPDATE, for example.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ