Linux Container Development
 help / color / mirror / Atom feed
From: Serge Hallyn <serge.hallyn-GeWIH/nMZzLQT0dZR+AlfA@public.gmane.org>
To: Janne Karhunen <janne.karhunen-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Cc: containers-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org,
	"Eric W. Biederman"
	<ebiederm-aS9lmoZGLiVWk0Htik3J/w@public.gmane.org>
Subject: Re: [PATCH 2/4] fs: allow dev accesses in userns in controlled situations
Date: Tue, 19 Mar 2013 10:37:40 -0500	[thread overview]
Message-ID: <20130319153740.GA21908@sergelap> (raw)
In-Reply-To: <CAE=Ncradvs_twWT8b6NQz85dm-Y8ayTH7NFv=i0vjYXpRBW9sg-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>

Quoting Janne Karhunen (janne.karhunen-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org):
> On Fri, Mar 15, 2013 at 4:20 PM, Serge Hallyn <serge.hallyn-GeWIH/nMZzLQT0dZR+AlfA@public.gmane.org> wrote:
> 
> >> We will do that by marking the mount as MNT_NODEV_NS instead of
> >> MNT_NODEV. This is because if the mount operation explicitly asked for
> >> nodev, we ought to respect it. MNT_NODEV_NS will forbid accesses if the
> >> task is not on a device cgroup. If it is, we will rely on the control
> >> rules in devcg to intermediate the access an tell us what those tasks
> >> can or cannot do.
> >
> > Well the devcg was meant to be a temporary stopgap solution until we
> > have device namespaces, and this seems to entrench them further, but
> > it does make sense.
> 
> Just out of interest, what would such device namespace actually
> do other than switch the device access on/off according to callers
> namespace?

It could also support mapping of <type>:maj:min inside namespace to
a different device on host.  In most cases we probably don't actually
want that, but it's an interesting enough thing to be worth thinking
through.

> 'Device namespace' Cells whitepaper [1]  talks about seems to be
> saying they also implemented a callback for some drivers (only

oh, thanks, haven't read that one, will have to.

> init_ns accessible ioctl?) to support their 'foreground/background'
> use case. While this is certainly one use case, it's certainly nothing
> generic.
> 
> 1. http://www.cs.columbia.edu/~nieh/pubs/sosp2011_cells.pdf
> 
> 
> --
> Janne

  parent reply	other threads:[~2013-03-19 15:37 UTC|newest]

Thread overview: 35+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-15  9:13 [PATCH 0/4] fix depvpts in user namespaces Glauber Costa
     [not found] ` <1363338823-25292-1-git-send-email-glommer-bzQdu9zFT3WakBO8gow8eQ@public.gmane.org>
2013-03-15  9:13   ` [PATCH 1/4] dev_cgroup: keep track of which cgroup is the root cgroup Glauber Costa
     [not found]     ` <1363338823-25292-2-git-send-email-glommer-bzQdu9zFT3WakBO8gow8eQ@public.gmane.org>
2013-03-15 14:07       ` Serge Hallyn
2013-03-15 19:27       ` Aristeu Rozanski
     [not found]     ` <20130315140743.GC3782@sergelap>
2013-03-15 14:43       ` Glauber Costa
     [not found]       ` <514333A2.5060408@parallels.com>
     [not found]         ` <514333A2.5060408-bzQdu9zFT3WakBO8gow8eQ@public.gmane.org>
2013-03-15 14:55           ` Serge Hallyn
2013-03-15  9:13   ` [PATCH 2/4] fs: allow dev accesses in userns in controlled situations Glauber Costa
     [not found]     ` <1363338823-25292-3-git-send-email-glommer-bzQdu9zFT3WakBO8gow8eQ@public.gmane.org>
2013-03-15 14:20       ` Serge Hallyn
     [not found]     ` <20130315142045.GD3782@sergelap>
2013-03-19 15:32       ` Janne Karhunen
     [not found]         ` <CAE=Ncradvs_twWT8b6NQz85dm-Y8ayTH7NFv=i0vjYXpRBW9sg-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2013-03-19 15:37           ` Serge Hallyn [this message]
2013-03-19 16:52             ` Janne Karhunen
     [not found]               ` <CAE=NcrYeKQYqkPsB9FG5PpYd2VTqmTszfpY39aRJqR=vsXfa7w-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2013-03-19 17:27                 ` Serge Hallyn
2013-03-19 18:08                   ` Janne Karhunen
     [not found]                     ` <CAE=NcraBvk_hwCd9BgASpDBkmEB+fg-kKwAPbT7bQeFRbq5DSg-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2013-03-19 19:15                       ` Serge Hallyn
2013-03-19 23:29                 ` Eric W. Biederman
2013-03-15  9:13   ` [PATCH 3/4] fs: allow mknod in user namespaces Glauber Costa
2013-03-15  9:13   ` [PATCH 4/4] devpts: fix usage " Glauber Costa
2013-03-15 10:26   ` [PATCH 0/4] fix depvpts " Eric W. Biederman
     [not found]     ` <87boalt0vi.fsf-aS9lmoZGLiVWk0Htik3J/w@public.gmane.org>
2013-03-15 12:01       ` Glauber Costa
2013-03-15 14:00       ` Serge Hallyn
     [not found]     ` <20130315140040.GB3782@sergelap>
2013-03-15 14:42       ` Glauber Costa
     [not found]       ` <5143333E.1040100@parallels.com>
     [not found]         ` <5143333E.1040100-bzQdu9zFT3WakBO8gow8eQ@public.gmane.org>
2013-03-15 15:21           ` Serge Hallyn
2013-03-15 15:26             ` Glauber Costa
     [not found]             ` <51433DBE.9020109@parallels.com>
     [not found]               ` <51433DBE.9020109-bzQdu9zFT3WakBO8gow8eQ@public.gmane.org>
2013-03-15 15:58                 ` Serge Hallyn
2013-03-15 21:02                 ` Eric W. Biederman
     [not found]               ` <20130315155822.GA30652@sergelap>
2013-03-15 16:01                 ` Glauber Costa
     [not found]               ` <87txoce5qy.fsf@xmission.com>
     [not found]                 ` <87txoce5qy.fsf-aS9lmoZGLiVWk0Htik3J/w@public.gmane.org>
2013-03-18  3:20                   ` Serge Hallyn
     [not found]                 ` <20130318032052.GA5958@sergelap>
2013-03-18 21:23                   ` Eric W. Biederman
     [not found] ` <1363338823-25292-5-git-send-email-glommer@parallels.com>
     [not found]   ` <1363338823-25292-5-git-send-email-glommer-bzQdu9zFT3WakBO8gow8eQ@public.gmane.org>
2013-03-15 14:45     ` [PATCH 4/4] devpts: fix usage " Serge Hallyn
     [not found] ` <1363338823-25292-4-git-send-email-glommer@parallels.com>
     [not found]   ` <20130315143741.GE3782@sergelap>
2013-03-15 14:49     ` [PATCH 3/4] fs: allow mknod " Glauber Costa
     [not found]     ` <51433511.1020808@parallels.com>
     [not found]       ` <51433511.1020808-bzQdu9zFT3WakBO8gow8eQ@public.gmane.org>
2013-03-15 15:14         ` Serge Hallyn
     [not found]   ` <1363338823-25292-4-git-send-email-glommer-bzQdu9zFT3WakBO8gow8eQ@public.gmane.org>
2013-03-15 14:37     ` Serge Hallyn
2013-03-15 18:03     ` Vasily Kulikov
2013-03-15 20:43     ` Eric W. Biederman
     [not found]   ` <87a9q4gzs1.fsf@xmission.com>
     [not found]     ` <87a9q4gzs1.fsf-aS9lmoZGLiVWk0Htik3J/w@public.gmane.org>
2013-03-16  0:23       ` Serge 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=20130319153740.GA21908@sergelap \
    --to=serge.hallyn-gewih/nmzzlqt0dzr+alfa@public.gmane.org \
    --cc=containers-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org \
    --cc=ebiederm-aS9lmoZGLiVWk0Htik3J/w@public.gmane.org \
    --cc=janne.karhunen-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.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