mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Bryan Donlan" <bdonlan@gmail.com>
To: "Serge E. Hallyn" <serue@us.ibm.com>
Cc: mtk.manpages@gmail.com, ebiederm@xmission.com,
	lkml <linux-kernel@vger.kernel.org>,
	linux-man@vger.kernel.org, clg@fr.ibm.com, herbert@13thfloor.at,
	dev@sw.ru, "Subrata Modak" <subrata@linux.vnet.ibm.com>,
	"David Howells" <dhowells@redhat.com>
Subject: Re: Could you write some CLONE_NEWUSER?
Date: Thu, 4 Dec 2008 15:18:35 -0500	[thread overview]
Message-ID: <3e8340490812041218l7b4633fev5126f25a5d33076c@mail.gmail.com> (raw)
In-Reply-To: <20081204190430.GA16026@us.ibm.com>

On Thu, Dec 4, 2008 at 2:04 PM, Serge E. Hallyn <serue@us.ibm.com> wrote:
> Quoting Michael Kerrisk (mtk.manpages@googlemail.com):
>> Hi Serge,
>>
>> Thanks for CCing me on recent CLONE_NEWUSER patches.
>>
>> Would you be will to write some documentation for this flag?  (It's
>> the only remaining undocumented flag in clone(2).)  Plain text would
>> be fine -- I'll integrate it into the man page with suitable macros.
>
> Well here is a start.  David, writing this actually reminded me that
> the per-user keys still aren't per-namespace.  Did you say you were
> looking at that, or should I send a patch (starting at
> security/keys/key.c:key_user_lookup())?
>
> Eric, if you get a second, could you please review?
>
> thanks,
> -serge
>
>
> CLONE_NEWUSER
>        Start the child in a new user namespace.
>
>        User namespaces are very incomplete.  When complete, they
>        will implement hierarchical userid namespaces designed to
>        be safely used without privilege.  User namespaces are
>        unnamed, but for the sake of this explanation we will give
>        them a single-letter ID.  Let us refer to userid 500 in user
>        namespace B  as (B, 500).  Assume a process owned by (B, 500)
>        passes CLONE_NEWUSER to clone(2).  A new user namespace, C,
>        will be created.  The new task will be owned by user
>        (C, 0).  No userid in user namespace C will be able to
>        gain more access than (B, 500) could obtain.  User (C, 500)
>        will be protected from (C, 501) as usual.  Files created
>        by (C, 501) are owned by both (C, 501) and (B, 500), so
>        (B, 500) owns all files created in user namespace C.  Likewise
>        (B, 500) can kill and ptrace any processes owned by (C, 501).

This is something more of a general question than one about this
manpage, but how will files owned by user namespaces be represented on
the underlying filesystem? Since (C, 501) will be meaningless after a
reboot at the latest, it makes little sense to persist them...

  reply	other threads:[~2008-12-04 20:18 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-12-04 15:20 Michael Kerrisk
2008-12-04 15:34 ` Serge E. Hallyn
2008-12-04 15:41   ` Michael Kerrisk
2008-12-04 19:04 ` Serge E. Hallyn
2008-12-04 20:18   ` Bryan Donlan [this message]
2008-12-04 22:33     ` Serge E. Hallyn

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=3e8340490812041218l7b4633fev5126f25a5d33076c@mail.gmail.com \
    --to=bdonlan@gmail.com \
    --cc=clg@fr.ibm.com \
    --cc=dev@sw.ru \
    --cc=dhowells@redhat.com \
    --cc=ebiederm@xmission.com \
    --cc=herbert@13thfloor.at \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-man@vger.kernel.org \
    --cc=mtk.manpages@gmail.com \
    --cc=serue@us.ibm.com \
    --cc=subrata@linux.vnet.ibm.com \
    /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

all inboxes | Powered by JetHome®