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: <81f7adde-49ad-6d74-edf4-ad7011716540@ucloud.cn>
Date:   Fri, 1 Mar 2019 22:36:47 +0800
From:   wenxu <wenxu@...oud.cn>
To:     Ido Schimmel <idosch@...lanox.com>,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>
Cc:     "davem@...emloft.net" <davem@...emloft.net>,
        "dsahern@...il.com" <dsahern@...il.com>, mlxsw <mlxsw@...lanox.com>
Subject: Re: [PATCH net-next] net: ipv4: Fix NULL pointer dereference in route
 lookup

On 2019/3/1 下午9:38, Ido Schimmel wrote:
> When calculating the multipath hash for input routes the flow info is
> not available and therefore should not be used.
>
> Fixes: 24ba14406c5c ("route: Add multipath_hash in flowi_common to make user-define hash")
> Signed-off-by: Ido Schimmel <idosch@...lanox.com>
> Cc: wenxu <wenxu@...oud.cn>
> ---
>  net/ipv4/route.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/net/ipv4/route.c b/net/ipv4/route.c
> index 7cf4c8305071..e3ac458b5d8b 100644
> --- a/net/ipv4/route.c
> +++ b/net/ipv4/route.c
> @@ -1820,7 +1820,7 @@ static void ip_multipath_l3_keys(const struct sk_buff *skb,
>  int fib_multipath_hash(const struct net *net, const struct flowi4 *fl4,
>  		       const struct sk_buff *skb, struct flow_keys *flkeys)
>  {
> -	u32 multipath_hash = fl4->flowi4_multipath_hash;
> +	u32 multipath_hash = fl4 ? fl4->flowi4_multipath_hash : 0;
>  	struct flow_keys hash_keys;
>  	u32 mhash;
>  

Acked-by: wenxu <wenxu@...oud.cn>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ