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: <20100313002706.013614301@kvm.kroah.org>
Date:	Fri, 12 Mar 2010 16:25:42 -0800
From:	Greg KH <gregkh@...e.de>
To:	linux-kernel@...r.kernel.org, stable@...nel.org
Cc:	stable-review@...nel.org, torvalds@...ux-foundation.org,
	akpm@...ux-foundation.org, alan@...rguk.ukuu.org.uk,
	Michael Neuling <mikey@...ling.org>,
	WANG Cong <xiyou.wangcong@...il.com>,
	Anton Blanchard <anton@...ba.org>,
	Oleg Nesterov <oleg@...hat.com>,
	James Morris <jmorris@...ei.org>,
	Serge Hallyn <serue@...ibm.com>,
	Benjamin Herrenschmidt <benh@...nel.crashing.org>,
	Jouni Malinen <j@...fi>
Subject: [009/145] fs/exec.c: fix initial stack reservation

2.6.32-stable review patch.  If anyone has any objections, please let me know.

----------------
From: Michael Neuling <mikey@...ling.org>

commit a17e18790a8c47113a73139d54a375dc9ccd8f08 upstream.

803bf5ec259941936262d10ecc84511b76a20921 ("fs/exec.c: restrict initial
stack space expansion to rlimit") attempts to limit the initial stack to
20*PAGE_SIZE.  Unfortunately, in attempting ensure the stack is not
reduced in size, we ended up not changing the stack at all.

This size reduction check is not necessary as the expand_stack call does
this already.

This caused a regression in UML resulting in most guest processes being
killed.

Signed-off-by: Michael Neuling <mikey@...ling.org>
Reviewed-by: KOSAKI Motohiro <kosaki.motohiro@...fujitsu.com>
Acked-by: WANG Cong <xiyou.wangcong@...il.com>
Cc: Anton Blanchard <anton@...ba.org>
Cc: Oleg Nesterov <oleg@...hat.com>
Cc: James Morris <jmorris@...ei.org>
Cc: Serge Hallyn <serue@...ibm.com>
Cc: Benjamin Herrenschmidt <benh@...nel.crashing.org>
Cc: Jouni Malinen <j@...fi>
Signed-off-by: Andrew Morton <akpm@...ux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@...ux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@...e.de>

---
 fs/exec.c |    1 -
 1 file changed, 1 deletion(-)

--- a/fs/exec.c
+++ b/fs/exec.c
@@ -638,7 +638,6 @@ int setup_arg_pages(struct linux_binprm
 	 * will align it up.
 	 */
 	rlim_stack = rlimit(RLIMIT_STACK) & PAGE_MASK;
-	rlim_stack = min(rlim_stack, stack_size);
 #ifdef CONFIG_STACK_GROWSUP
 	if (stack_size + stack_expand > rlim_stack)
 		stack_base = vma->vm_start + rlim_stack;


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ