All of lore.kernel.org
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
Cc: audit@vger.kernel.org, linux-security-module@vger.kernel.org
Subject: Re: [PATCH 1/4] landlock: Distinguish namespace creation and entry denials
Date: Tue, 17 Nov 2026 10:29:22 +0000	[thread overview]
Message-ID: <sashiko-outbox-218622@kernel.org> (raw)
In-Reply-To: <20261117102110.2524197-2-mic@digikod.net>

> Landlock reports denied namespace creation and entry with the same
> internal request type.  Before commit 08471914d6bb ("ns: allocate the
> namespace id before the namespace_init hook"), denied creation carried
> ID zero and could be distinguished from entry by ID alone.  That commit
> moved ID allocation before namespace_init(), so creation now carries the
> ID of an unreachable new namespace while entry carries the existing
> target ID.  Namespace IDs are object context, not operation
> discriminators.
> 
> Split the request type into creation and entry.  Keep the two namespace
> values together before capability; this renumbers the unreleased
> capability request in raw and typed trace context.  Report
> namespace_op=create or namespace_op=enter immediately after blockers in
> namespace audit records and trace event text.  Placing the operation
> before namespace_type and namespace_id lets consumers establish the
> semantics before interpreting the following namespace context,
> especially whether namespace_id is the creation-time value or identifies
> an existing entry target.
> 
> Keep namespace.use as the policy blocker: the new value only describes
> the semantic hook context and does not add a policy control.
> 
> The creation value covers namespace_init(), including clone(2),
> clone3(2), unshare(2), open_tree(2), and fsmount(2) paths.  The entry
> value covers namespace_install(), currently reached through setns(2).
> 
> Cc: Günther Noack <gnoack@google.com>
> Fixes: 15dd86021b57 ("landlock: Enforce namespace use restrictions")
> Signed-off-by: Mickaël Salaün <mic@digikod.net>

Sashiko has reviewed this patch and found no issues.

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20261117102110.2524197-1-mic@digikod.net?part=1


  reply	other threads:[~2026-11-17 10:29 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-17 10:21 [PATCH 0/4] Landlock: Fix namespace and capability denials Mickaël Salaün
2026-11-17 10:21 ` [PATCH 1/4] landlock: Distinguish namespace creation and entry denials Mickaël Salaün
2026-11-17 10:29   ` sashiko-bot [this message]
2026-11-17 10:21 ` [PATCH 2/4] landlock: Add capability objects to denial tracing Mickaël Salaün
2026-11-17 10:27   ` sashiko-bot
2026-11-17 10:21 ` [PATCH 3/4] selftests/landlock: Test namespace denial operations Mickaël Salaün
2026-11-17 10:24   ` sashiko-bot
2026-11-17 10:21 ` [PATCH 4/4] landlock: Document " Mickaël Salaün
2026-11-17 10:24   ` sashiko-bot

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=sashiko-outbox-218622@kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=audit@vger.kernel.org \
    --cc=linux-security-module@vger.kernel.org \
    --cc=sashiko-reviews@lists.linux.dev \
    /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 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.