From: Aleksa Sarai <cyphar@cyphar.com>
To: "Eric W. Biederman" <ebiederm@xmission.com>
Cc: linux-api@vger.kernel.org, Kees Cook <keescook@chromium.org>,
Andy Lutomirski <luto@amacapital.net>,
Will Drewry <wad@chromium.org>,
Linus Torvalds <torvalds@linux-foundation.org>,
Al Viro <viro@ZenIV.linux.org.uk>,
Michael Kerrisk <mtk.manpages@gmail.com>,
linux-man@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: Semantics of SECCOMP_MODE_STRICT?
Date: Wed, 30 Jun 2021 15:02:19 +1000 [thread overview]
Message-ID: <20210630050219.nwixaloqs5oq5juy@senku> (raw)
In-Reply-To: <87r1gkp9i7.fsf@disp2133>
[-- Attachment #1: Type: text/plain, Size: 1192 bytes --]
On 2021-06-29, Eric W. Biederman <ebiederm@xmission.com> wrote:
>
> I am the process of cleaning up the process exit path in the kernel, and
> as part of that I am looking at the callers of do_exit. A very
> interesting one is __seccure_computing_strict.
>
> Looking at the code is very clear that if a system call is attempted
> that is not in the table the thread attempting to execute that system
> call is terminated.
>
> Reading the man page for seccomp it says that the process is delivered
> SIGKILL.
>
> The practical difference is what happens for multi-threaded
> applications.
>
> What are the desired semantics for a multi-threaded application if one
> thread attempts to use a unsupported system call? Should the thread be
> terminated or the entire application?
>
> Do we need to fix the kernel, or do we need to fix the manpages?
My expectation is that the correct action should be the equivalent of
SECCOMP_RET_KILL(_THREAD) which kills the thread and is the current
behaviour (SECCOMP_RET_KILL_PROCESS is relatively speaking quite new).
--
Aleksa Sarai
Senior Software Engineer (Containers)
SUSE Linux GmbH
<https://www.cyphar.com/>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
next prev parent reply other threads:[~2021-06-30 5:13 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-29 22:54 Semantics of SECCOMP_MODE_STRICT? Eric W. Biederman
2021-06-30 5:02 ` Aleksa Sarai [this message]
2021-06-30 5:23 ` Kees Cook
2021-06-30 20:11 ` [PATCH] seccomp.2: Clarify that bad system calls kill the thread Eric W. Biederman
2021-06-30 23:06 ` Kees Cook
2021-08-10 2:07 ` Michael Kerrisk (man-pages)
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210630050219.nwixaloqs5oq5juy@senku \
--to=cyphar@cyphar.com \
--cc=ebiederm@xmission.com \
--cc=keescook@chromium.org \
--cc=linux-api@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-man@vger.kernel.org \
--cc=luto@amacapital.net \
--cc=mtk.manpages@gmail.com \
--cc=torvalds@linux-foundation.org \
--cc=viro@ZenIV.linux.org.uk \
--cc=wad@chromium.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox