linux-security-module.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Günther Noack" <gnoack@google.com>
To: "Mickaël Salaün" <mic@digikod.net>
Cc: "Casey Schaufler" <casey@schaufler-ca.com>,
	"Günther Noack" <gnoack3000@gmail.com>,
	"Paul Moore" <paul@paul-moore.com>,
	sergeh@kernel.org, "David Howells" <dhowells@redhat.com>,
	"Kees Cook" <keescook@chromium.org>,
	linux-security-module@vger.kernel.org,
	"Konstantin Meskhidze" <konstantin.meskhidze@huawei.com>,
	"Jann Horn" <jannh@google.com>,
	linux-kernel@vger.kernel.org,
	"Peter Newman" <peternewman@google.com>,
	"Andy Lutomirski" <luto@amacapital.net>,
	"Will Drewry" <wad@chromium.org>,
	"Jarkko Sakkinen" <jarkko@kernel.org>
Subject: Re: [RFC 1/2] landlock: Multithreading support for landlock_restrict_self()
Date: Thu, 12 Jun 2025 13:51:55 +0200	[thread overview]
Message-ID: <aEq_IAsYm2wFjA0c@google.com> (raw)
In-Reply-To: <20250602.ko3thoc7ooL4@digikod.net>

On Mon, Jun 02, 2025 at 08:45:06AM +0200, Mickaël Salaün wrote:
> On Fri, May 30, 2025 at 06:26:07PM +0200, Günther Noack wrote:
> >      As Jann pointed out in [1], the tasklist_lock and siglock are not sleepable
> >      and can't be used while waiting, which is why he proposed an approach where
> >      we retry in a loop until no new threads show up any more, while getting the
> >      existing threads stuck in the task_work as well (where they can't spawn new
> >      threads).
> 
> This looks good.  Too bad we need to block all threads.

OK, I'll take that route then.

In my understanding, if we are already blocking all threads, we might as well
use prepare_creds() in these threads again. -- It does not cost us much more to
collect these potential errors now.  Does that sound reasonable?

—Günther

  reply	other threads:[~2025-06-12 11:51 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-21 18:44 [RFC 0/2] landlock: Multithreaded policy enforcement Günther Noack
2025-02-21 18:44 ` [RFC 1/2] landlock: Multithreading support for landlock_restrict_self() Günther Noack
2025-02-27 20:53   ` Mickaël Salaün
2025-02-28 17:33     ` Günther Noack
2025-03-04 20:25       ` Mickaël Salaün
2025-03-10 13:04         ` Günther Noack
2025-03-11 14:32           ` Mickaël Salaün
2025-05-18  7:40             ` Günther Noack
2025-05-18 19:57               ` Mickaël Salaün
2025-05-30 13:16                 ` Günther Noack
2025-05-30 15:11                   ` Mickaël Salaün
2025-05-30 16:26                     ` Günther Noack
2025-05-30 16:52                       ` Casey Schaufler
2025-06-02  6:45                       ` Mickaël Salaün
2025-06-12 11:51                         ` Günther Noack [this message]
2025-05-27 14:26           ` Jann Horn
2025-02-21 18:44 ` [RFC 2/2] landlock: selftests for LANDLOCK_RESTRICT_SELF_TSYNC Günther Noack
2025-02-27 20:52 ` [RFC 0/2] landlock: Multithreaded policy enforcement Mickaël Salaün

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=aEq_IAsYm2wFjA0c@google.com \
    --to=gnoack@google.com \
    --cc=casey@schaufler-ca.com \
    --cc=dhowells@redhat.com \
    --cc=gnoack3000@gmail.com \
    --cc=jannh@google.com \
    --cc=jarkko@kernel.org \
    --cc=keescook@chromium.org \
    --cc=konstantin.meskhidze@huawei.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-security-module@vger.kernel.org \
    --cc=luto@amacapital.net \
    --cc=mic@digikod.net \
    --cc=paul@paul-moore.com \
    --cc=peternewman@google.com \
    --cc=sergeh@kernel.org \
    --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;
as well as URLs for NNTP newsgroup(s).