All of lore.kernel.org
 help / color / mirror / Atom feed
* [RESEND][PATCH 0/3] exec: Pin stack limit during exec
@ 2018-02-14 20:06 ` Kees Cook
  0 siblings, 0 replies; 12+ messages in thread
From: Kees Cook @ 2018-02-14 20:06 UTC (permalink / raw)
  To: Andrew Morton
  Cc: Kees Cook, Linus Torvalds, Michal Hocko, Ben Hutchings,
	Willy Tarreau, Hugh Dickins, Oleg Nesterov, Jason A. Donenfeld,
	Rik van Riel, Laura Abbott, Greg KH, Andy Lutomirski, linux-mm,
	linux-arch, linux-kernel, kernel-hardening

Attempts to solve problems with the stack limit changing during exec
continue to be frustrated[1][2]. In addition to the specific issues around
the Stack Clash family of flaws, Andy Lutomirski pointed out[3] other
places during exec where the stack limit is used and is assumed to be
unchanging. Given the many places it gets used and the fact that it can be
manipulated/raced via setrlimit() and prlimit(), I think the only way to
handle this is to move away from the "current" view of the stack limit and
instead attach it to the bprm, and plumb this down into the functions that
need to know the stack limits. This series implements the approach.

Neither I nor 0-day have found issues with this series, so I'd like to
get it into -mm for further testing.

Thanks!

-Kees

[1] 04e35f4495dd ("exec: avoid RLIMIT_STACK races with prlimit()")
[2] 779f4e1c6c7c ("Revert "exec: avoid RLIMIT_STACK races with prlimit()"")
[3] to security@kernel.org, "Subject: existing rlimit races?"

^ permalink raw reply	[flat|nested] 12+ messages in thread
* [PATCH 0/3] exec: Pin stack limit during exec
@ 2018-01-09 20:23 Kees Cook
  2018-01-09 20:23   ` Kees Cook
  0 siblings, 1 reply; 12+ messages in thread
From: Kees Cook @ 2018-01-09 20:23 UTC (permalink / raw)
  To: Andrew Morton
  Cc: Kees Cook, Linus Torvalds, Michal Hocko, Ben Hutchings,
	Willy Tarreau, Hugh Dickins, Oleg Nesterov, Jason A. Donenfeld,
	Rik van Riel, Laura Abbott, Greg KH, Andy Lutomirski, linux-mm,
	linux-arch, linux-kernel, kernel-hardening

Attempts to solve problems with the stack limit changing during exec             continue to be frustrated[1][2]. In addition to the specific issues              around the Stack Clash family of flaws, Andy Lutomirski pointed out[3]
other places during exec where the stack limit is used and is assumed
to be unchanging. Given the many places it gets used and the fact that
it can be manipulated/raced via setrlimit() and prlimit(), I think the
only way to handle this is to move away from the "current" view of the
stack limit and instead attach it to the bprm, and plumb this down into
the functions that need to know the stack limits. This series implements
the approach. I'd be curious to hear feedback on alternatives.

Thanks!

-Kees

[1] 04e35f4495dd ("exec: avoid RLIMIT_STACK races with prlimit()")
[2] 779f4e1c6c7c ("Revert "exec: avoid RLIMIT_STACK races with prlimit()"")
[3] to security@kernel.org, "Subject: existing rlimit races?"

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2018-02-20 13:46 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-02-14 20:06 [RESEND][PATCH 0/3] exec: Pin stack limit during exec Kees Cook
2018-02-14 20:06 ` Kees Cook
2018-02-14 20:06 ` [PATCH 1/3] exec: Pass stack rlimit into mm layout functions Kees Cook
2018-02-14 20:06   ` Kees Cook
2018-02-14 20:06 ` [PATCH 2/3] exec: Introduce finalize_exec() before start_thread() Kees Cook
2018-02-14 20:06   ` Kees Cook
2018-02-14 20:06 ` [PATCH 3/3] exec: Pin stack limit during exec Kees Cook
2018-02-14 20:06   ` Kees Cook
2018-02-20 13:46 ` [RESEND][PATCH 0/3] " Michal Hocko
2018-02-20 13:46   ` Michal Hocko
  -- strict thread matches above, loose matches on Subject: below --
2018-01-09 20:23 [PATCH " Kees Cook
2018-01-09 20:23 ` [PATCH 1/3] exec: Pass stack rlimit into mm layout functions Kees Cook
2018-01-09 20:23   ` Kees Cook

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.