From: "Serge E. Hallyn" <serge@hallyn.com>
To: Tejun Heo <tj@kernel.org>
Cc: "Serge Hallyn" <serge.hallyn@ubuntu.com>,
Containers <containers@lists.linux-foundation.org>,
"Eric W. Biederman" <ebiederm@xmission.com>,
lkml <linux-kernel@vger.kernel.org>,
"Victor Marmol" <vmarmol@google.com>,
"Stéphane Graber" <stgraber@ubuntu.com>,
"Rohit Jnagal" <jnagal@google.com>
Subject: Re: [RFC PATCH 1/2] devices cgroup: allow can_attach() if ns_capable
Date: Mon, 4 Nov 2013 21:51:35 +0000 [thread overview]
Message-ID: <20131104215135.GA26190@mail.hallyn.com> (raw)
In-Reply-To: <CAOS58YPEKtEiZWsn-8u6OPr-UsyQp=XR+ecGmXyOdT0JnYAmsA@mail.gmail.com>
Quoting Tejun Heo (tj@kernel.org):
> Hello, Serge.
>
> On Tue, Jul 23, 2013 at 3:28 PM, Serge Hallyn <serge.hallyn@ubuntu.com> wrote:
> > On Tue, Jul 23, 2013 at 02:04:26PM -0500, Serge Hallyn wrote:
> > > If task A is uid 1000 on the host, and creates task B as uid X in a new
> > > user namespace, then task A, still being uid 1000 on the host, is
> > > privileged with respect to B and his namespace - i.e.
> > > ns_capable(B->userns, CAP_SYS_ADMIN) is true.
>
> >> Well, that also is the exact type of priv delegation we're moving away
> >> from, so....
> >
> > I think that's unreasonable, but I guess I'll have to go reread the
> > old thread.
>
> Yeah, please do. I think the case is pretty strong for disallowing
> delegation of cgroup directories to !root (or whatever CAP it should
> be) users. It's inherently unsafe for some controllers and ends up
> leaking kernel implementation details into regular binaries thus
> cementing those leaked details as APIs, which is a giant no-no.
Hi Tejun,
So to come back to this... At plumbers, I believe you were not present
at the 'let me contain that for you' session. There the "delegation is
not safe" topic came up. When pressed, the only example that came up
was (IIRC) having to do with an rt scheduling issue which, all agreed,
was a bug in the implementation which should be fixed, rather than a valid
reason to say that delegation of cgroups should be fundamentally not supported.
Do you have a list of such issues which you see with delegation? That is,
cases where, if ownership of a subtree is granted to a non-root user,
that user can affect tasks owned by other users who are in other
cgroups?
-serge
next prev parent reply other threads:[~2013-11-04 21:51 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-23 18:16 [RFC PATCH 1/2] devices cgroup: allow can_attach() if ns_capable Serge Hallyn
2013-07-23 18:18 ` [RFC PATCH 2/2] capabilities: allow nice if we are privileged Serge Hallyn
2013-07-24 8:07 ` Eric W. Biederman
2013-07-23 18:30 ` [RFC PATCH 1/2] devices cgroup: allow can_attach() if ns_capable Tejun Heo
2013-07-23 18:38 ` Serge Hallyn
2013-07-23 18:50 ` Tejun Heo
2013-07-23 19:04 ` Serge Hallyn
2013-07-23 19:12 ` Tejun Heo
2013-07-23 19:28 ` Serge Hallyn
2013-07-23 19:39 ` Tejun Heo
2013-11-04 21:51 ` Serge E. Hallyn [this message]
2013-11-04 22:06 ` Tejun Heo
2013-10-23 0:41 ` Serge E. Hallyn
2013-10-24 10:57 ` Tejun Heo
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=20131104215135.GA26190@mail.hallyn.com \
--to=serge@hallyn.com \
--cc=containers@lists.linux-foundation.org \
--cc=ebiederm@xmission.com \
--cc=jnagal@google.com \
--cc=linux-kernel@vger.kernel.org \
--cc=serge.hallyn@ubuntu.com \
--cc=stgraber@ubuntu.com \
--cc=tj@kernel.org \
--cc=vmarmol@google.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;
as well as URLs for NNTP newsgroup(s).