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: <20181116191246.GN8742@gauss3.secunet.de>
Date:   Fri, 16 Nov 2018 20:12:46 +0100
From:   Steffen Klassert <steffen.klassert@...unet.com>
To:     Lennert Buytenhek <buytenh@...tstofly.org>
CC:     <herbert@...dor.apana.org.au>,
        Jean-Philippe Menil <jpmenil@...il.com>, <davem@...emloft.net>,
        <netdev@...r.kernel.org>, <kuznet@....inr.ac.ru>,
        <yoshfuji@...ux-ipv6.org>
Subject: Re: [BUG] xfrm: unable to handle kernel NULL pointer dereference

On Fri, Nov 16, 2018 at 08:48:00PM +0200, Lennert Buytenhek wrote:
> On Sat, Nov 10, 2018 at 08:34:34PM +0100, Jean-Philippe Menil wrote:
> 
> > we're seeing unexpected crashes from kernel 4.15 to 4.18.17, using
> > IPsec VTI interfaces, on several vpn hosts, since upgrade from 4.4.
> 
> I looked into this with Jean-Philippe, and it appears to be crashing
> on a NULL pointer dereference in the inlined xfrm_policy_check() call
> in vti_rcv_cb(), and specifically on the skb_dst(skb) dereference in
> __xfrm_policy_check2():
> 
> 	return  (!net->xfrm.policy_count[dir] && !skb->sp) ||
> 		(skb_dst(skb)->flags & DST_NOPOLICY) ||		<=====
> 		__xfrm_policy_check(sk, ndir, skb, family);
> 
> Commit 9e1437937807 ("xfrm: Fix NULL pointer dereference when
> skb_dst_force clears the dst_entry.") fixes a very similar problem on
> the output and forward paths, but our issue seems to be triggering on
> the input path.

Yes, this is the same problem. skb_dst_force() does not
really force a refcount anymore, it might clear the dst
pointer instead (maybe this function should be renamed).

Want to submit a fix? If not I'll go to fix that.

Thanks!

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ