Revert "exec: avoid RLIMIT_STACK races with prlimit()"
authorKees Cook <keescook@chromium.org>
Tue, 12 Dec 2017 19:28:38 +0000 (11:28 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 20 Dec 2017 09:10:22 +0000 (10:10 +0100)
commit2dea756b487547788c1f28439fbc3df270e6bf30
tree59b301f31c8b9cb660a7150b13d5d0e6d990e46c
parent0aa5d007ba673bc35378422b0c2b2b797da69424
Revert "exec: avoid RLIMIT_STACK races with prlimit()"

commit 779f4e1c6c7c661db40dfebd6dd6bda7b5f88aa3 upstream.

This reverts commit 04e35f4495dd560db30c25efca4eecae8ec8c375.

SELinux runs with secureexec for all non-"noatsecure" domain transitions,
which means lots of processes end up hitting the stack hard-limit change
that was introduced in order to fix a race with prlimit(). That race fix
will need to be redesigned.

Reported-by: Laura Abbott <labbott@redhat.com>
Reported-by: Tomáš Trnka <trnka@scm.com>
Signed-off-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/exec.c