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: <CANn89iJjVwaHOUXDVyaPOHjpkpY+EowKHcVubzbCT=T6ZBvMcw@mail.gmail.com>
Date: Fri, 18 Oct 2024 15:51:12 +0200
From: Eric Dumazet <edumazet@...gle.com>
To: Kuniyuki Iwashima <kuniyu@...zon.com>
Cc: "David S. Miller" <davem@...emloft.net>, Jakub Kicinski <kuba@...nel.org>, 
	Paolo Abeni <pabeni@...hat.com>, David Ahern <dsahern@...nel.org>, 
	Kuniyuki Iwashima <kuni1840@...il.com>, netdev@...r.kernel.org
Subject: Re: [PATCH v1 net-next 03/11] ipv4: Don't allocate ifa for 0.0.0.0 in inet_rtm_newaddr().

On Fri, Oct 18, 2024 at 3:23 AM Kuniyuki Iwashima <kuniyu@...zon.com> wrote:
>
> When we pass 0.0.0.0 to __inet_insert_ifa(), it frees ifa and returns 0.
>
> We can do this check much earlier for RTM_NEWADDR even before allocating
> struct in_ifaddr.
>
> Let's move the validation to
>
>   1. inet_insert_ifa() for ioctl()
>   2. inet_rtm_newaddr() for RTM_NEWADDR
>
> Now, we can remove the same check in find_matching_ifa().
>
> Signed-off-by: Kuniyuki Iwashima <kuniyu@...zon.com>

Reviewed-by: Eric Dumazet <edumazet@...gle.com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ