linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [RFC PATCH 0/3] Seccomp non-preemptible notifier
@ 2021-02-20  9:04 Sargun Dhillon
  2021-02-20  9:05 ` [RFC PATCH 1/3] seccomp: Refactor notification handler to prepare for new semantics Sargun Dhillon
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Sargun Dhillon @ 2021-02-20  9:04 UTC (permalink / raw)
  To: Kees Cook, LKML, Linux Containers
  Cc: Sargun Dhillon, Mauricio Vásquez Bernal, Rodrigo Campos,
	Tycho Andersen, Giuseppe Scrivano

This patchset addresses a race condition we've dealt with recently with
seccomp. Specifically programs interrupting syscalls while they're in
progress. This was exacerbated by Golang's recent adoption of "async
preemption", in which they try to interrupt any syscall that's been
running for more than 10ms during GC. During certain syscalls, it's
non-trivial to write them in a reetrant manner in userspace (mount).

This has a couple semantic changes, and relaxes a check on seccomp_data.
I can deal with these, but this was a first cut. I also expect that the
patch would be squashed down, but it's split out for easier review.

Sargun Dhillon (3):
  seccomp: Refactor notification handler to prepare for new semantics
  seccomp: Add wait_killable semantic to seccomp user notifier
  selftests/seccomp: Add test for wait killable notifier

 include/uapi/linux/seccomp.h                  | 10 +++
 kernel/seccomp.c                              | 63 +++++++++++++------
 tools/testing/selftests/seccomp/seccomp_bpf.c | 60 ++++++++++++++++++
 3 files changed, 114 insertions(+), 19 deletions(-)

-- 
2.25.1


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

end of thread, other threads:[~2021-02-26 17:01 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-20  9:04 [RFC PATCH 0/3] Seccomp non-preemptible notifier Sargun Dhillon
2021-02-20  9:05 ` [RFC PATCH 1/3] seccomp: Refactor notification handler to prepare for new semantics Sargun Dhillon
2021-02-20  9:05 ` [RFC PATCH 2/3] seccomp: Add wait_killable semantic to seccomp user notifier Sargun Dhillon
2021-02-26 16:57   ` Rodrigo Campos
2021-02-20  9:05 ` [RFC PATCH 3/3] selftests/seccomp: Add test for wait killable notifier Sargun Dhillon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).