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: <20211007072752.257c3bcc@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com>
Date:   Thu, 7 Oct 2021 07:27:52 -0700
From:   Jakub Kicinski <kuba@...nel.org>
To:     David Ahern <dsahern@...il.com>,
        Mike Manning <mvrmanning@...il.com>
Cc:     Netdev <netdev@...r.kernel.org>,
        Saikrishna Arcot <sarcot@...rosoft.com>
Subject: Re: [PATCH] net: prefer socket bound to interface when not in VRF

On Thu, 7 Oct 2021 08:10:17 -0600 David Ahern wrote:
> On 10/7/21 8:07 AM, Jakub Kicinski wrote:
> > On Tue, 5 Oct 2021 14:03:42 +0100 Mike Manning wrote:  
> >> The commit 6da5b0f027a8 ("net: ensure unbound datagram socket to be
> >> chosen when not in a VRF") modified compute_score() so that a device
> >> match is always made, not just in the case of an l3mdev skb, then
> >> increments the score also for unbound sockets. This ensures that
> >> sockets bound to an l3mdev are never selected when not in a VRF.
> >> But as unbound and bound sockets are now scored equally, this results
> >> in the last opened socket being selected if there are matches in the
> >> default VRF for an unbound socket and a socket bound to a dev that is
> >> not an l3mdev. However, handling prior to this commit was to always
> >> select the bound socket in this case. Reinstate this handling by
> >> incrementing the score only for bound sockets. The required isolation
> >> due to choosing between an unbound socket and a socket bound to an
> >> l3mdev remains in place due to the device match always being made.
> >> The same approach is taken for compute_score() for stream sockets.
> >>
> >> Fixes: 6da5b0f027a8 ("net: ensure unbound datagram socket to be chosen when not in a VRF")
> >> Fixes: e78190581aff ("net: ensure unbound stream socket to be chosen when not in a VRF")
> >> Signed-off-by: Mike Manning <mmanning@...tta.att-mail.com>  
>
> Reviewed-by: David Ahern <dsahern@...nel.org>

Applied, thanks!

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ