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:   Fri, 26 May 2017 14:24:05 -0400 (EDT)
From:   David Miller <davem@...emloft.net>
To:     xiaolou4617@...il.com
Cc:     netdev@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] net: llc: add lock_sock in llc_ui_bind to avoid a race
 condition

From: Lin Zhang <xiaolou4617@...il.com>
Date: Thu, 25 May 2017 14:07:18 +0800

> There is a race condition in llc_ui_bind if two or more processes/threads 
> try to bind a same socket.
> 
> If more processes/threads bind a same socket success that will lead to 
> two problems, one is this action is not what we expected, another is 
> will lead to kernel in unstable status or oops(in my simple test case, 
> cause llc2.ko can't unload).
> 
> The current code is test SOCK_ZAPPED bit to avoid a process to 
> bind a same socket twice but that is can't avoid more processes/threads 
> try to bind a same socket at the same time.
> 
> So, add lock_sock in llc_ui_bind like others, such as llc_ui_connect.
> 
> Signed-off-by: Lin Zhang <xiaolou4617@...il.com>

Applied, thank you.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ