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: <1265032590.2848.40.camel@edumazet-laptop>
Date:	Mon, 01 Feb 2010 14:56:30 +0100
From:	Eric Dumazet <eric.dumazet@...il.com>
To:	Luca Tettamanti <kronos.it@...il.com>
Cc:	Alexey Dobriyan <adobriyan@...il.com>,
	linux-kernel@...r.kernel.org, netdev@...r.kernel.org,
	David Miller <davem@...emloft.net>
Subject: Re: [PATCH] af_key: fix netns ops ordering on module load/unload

Le lundi 01 février 2010 à 14:50 +0100, Luca Tettamanti a écrit :
> On Sat, Jan 30, 2010 at 1:53 PM, Alexey Dobriyan <adobriyan@...il.com> wrote:

> > [PATCH] af_key: fix netns ops ordering on module load/unload
> >
> > 1. After sock_register() returns, it's possible to create sockets,
> >   even if module still not initialized fully (blame generic module code
> >   for that!)
> > 2. Consequently, pfkey_create() can be called with pfkey_net_id still not
> >   initialized which will BUG_ON in net_generic():
> >        kernel BUG at include/net/netns/generic.h:43!
> > 3. During netns shutdown, netns ops should be unregistered after
> >   key manager unregistered because key manager calls can be triggered
> >   from xfrm_user module:
> >
> >        general protection fault: 0000 [#1] PREEMPT SMP DEBUG_PAGEALLOC
> >        pfkey_broadcast+0x111/0x210 [af_key]
> >        pfkey_send_notify+0x16a/0x300 [af_key]
> >        km_state_notify+0x41/0x70
> >        xfrm_flush_sa+0x75/0x90 [xfrm_user]
> > 4. Unregister netns ops after socket ops just in case and for symmetry.
> >
> > Reported by Luca Tettamanti.
> >
> > Signed-off-by: Alexey Dobriyan <adobriyan@...il.com>
> 
> Tested-by: Luca Tettamanti <kronos.it@...il.com>

Signed-off-by: Eric Dumazet <eric.dumazet@...il.com>



--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ