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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Y39me56NhhPYewYK@shredder>
Date:   Thu, 24 Nov 2022 14:41:31 +0200
From:   Ido Schimmel <idosch@...sch.org>
To:     Jonas Gorski <jonas.gorski@...il.com>
Cc:     Network Development <netdev@...r.kernel.org>,
        David Ahern <dsahern@...nel.org>
Subject: Re: RTM_DELROUTE not sent anymore when deleting (last) nexthop of
 routes in 6.1

On Thu, Nov 24, 2022 at 10:20:00AM +0100, Jonas Gorski wrote:
> Hello,
> 
> when an IPv4 route gets removed because its nexthop was deleted, the
> kernel does not send a RTM_DELROUTE netlink notifications anymore in
> 6.1. A bisect lead me to 61b91eb33a69 ("ipv4: Handle attempt to delete
> multipath route when fib_info contains an nh reference"), and
> reverting it makes it work again.
> 
> It can be reproduced by doing the following and listening to netlink
> (e.g. via ip monitor)
> 
> ip a a 172.16.1.1/24 dev veth1
> ip nexthop add id 100 via 172.16.1.2 dev veth1
> ip route add 172.16.101.0/24 nhid 100
> ip nexthop del id 100
> 
> where the nexthop del will trigger a RTM_DELNEXTHOP message, but no
> RTM_DELROUTE, but the route is gone afterwards anyways.

I tried the reproducer and I get the same notifications in ip monitor
regardless of whether 61b91eb33a69 is reverted or not.

Looking at the code and thinking about it, I don't think we ever
generated RTM_DELROUTE notifications when IPv4 routes were flushed (to
avoid a notification storm).

Are you running an upstream kernel?

Thanks

> 
> Doing the same thing with IPv6 still works as expected
> 
> ip a a 2001:db8:91::1/64 dev veth1
> ip nexthop add id 100 via 2001:db8:91::2 dev veth1
> ip route add 2001:db8:101::/64 nhid 100
> ip nexthop del id 100
> 
> Here the kernel will send out both the RTM_DELNEXTHOP and the
> RTM_DELROUTE netlink messages.
> 
> Unfortunately my net-foo is not good enough to propose a fix.
> 
> Best regards
> Jonas

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ