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] [day] [month] [year] [list]
Date:	Thu, 30 Jul 2015 16:00:06 -0700 (PDT)
From:	David Miller <davem@...emloft.net>
To:	sowmini.varadhan@...cle.com
Cc:	netdev@...r.kernel.org, linux-kernel@...r.kernel.org,
	edumazet@...gle.com, willemb@...gle.com, ebiederm@...ssion.com,
	alexander.h.duyck@...el.com, ast@...mgrid.com,
	hannes@...essinduktion.org, dborkman@...hat.com
Subject: Re: [PATCH v2 net] net: sk_clone_lock() should only do get_net()
 if the parent is not a kernel socket

From: Sowmini Varadhan <sowmini.varadhan@...cle.com>
Date: Thu, 30 Jul 2015 15:50:36 +0200

> 
> 
> The newsk returned by sk_clone_lock should hold a get_net()
> reference if, and only if, the parent is not a kernel socket
> (making this similar to sk_alloc()).
> 
> E.g,. for the SYN_RECV path, tcp_v4_syn_recv_sock->..inet_csk_clone_lock
> sets up the syn_recv newsk from sk_clone_lock. When the parent (listen)
> socket is a kernel socket (defined in sk_alloc() as having
> sk_net_refcnt == 0), then the newsk should also have a 0 sk_net_refcnt
> and should not hold a get_net() reference.
> 
> Fixes: 26abe14379f8 ("net: Modify sk_alloc to not reference count the
>       netns of kernel sockets.")
> Acked-by: Eric Dumazet <edumazet@...gle.com>
> Cc: Eric W. Biederman <ebiederm@...ssion.com>
> Signed-off-by: Sowmini Varadhan <sowmini.varadhan@...cle.com>
> ---
> v2: pulled patch #3 out of the RFC patch-set for RDS-TCP netns fixes; 
>     Added Fixes, Acked-by, Cc fields based on mailing list feedback
>     from Eric Dumazet.

Applied, thanks everyone.
--
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