lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 9 Sep 2014 12:39:44 -0700
From:	Andy Lutomirski <luto@...capital.net>
To:	"Eric W. Biederman" <ebiederm@...ssion.com>
Cc:	"Michael Kerrisk (man-pages)" <mtk.manpages@...il.com>,
	lkml <linux-kernel@...r.kernel.org>,
	"linux-man@...r.kernel.org" <linux-man@...r.kernel.org>,
	Linux Containers <containers@...ts.linux-foundation.org>,
	richard -rw- weinberger <richard.weinberger@...il.com>,
	"Serge E. Hallyn" <serge@...lyn.com>
Subject: Re: For review: user_namespace(7) man page

On Tue, Sep 9, 2014 at 12:26 PM, Andy Lutomirski <luto@...capital.net> wrote:
> On Tue, Sep 9, 2014 at 9:05 AM, Eric W. Biederman <ebiederm@...ssion.com> wrote:
>>
>> We may also want to discuss the specific restrictions on chroot.
>>
>> The text about chroot at least gives people a strong hint that the
>> chroot rules are affected by user namespaces.
>>
>> The restrictions that we have settled on to avoid chroot being a problem
>> are the creator of a user namespace must not be chrooted in their
>> current mount namespace, and the creator of the user namespace must not
>> be threaded.
>>
>> Andy can you check me on this it looks like unshare is currently buggy
>> in that it will allow a threaded application to create a user namespace.
>
> I think it's this code in unshare:
>
>     /*
>      * If unsharing a user namespace must also unshare the thread.
>      */
>     if (unshare_flags & CLONE_NEWUSER)
>         unshare_flags |= CLONE_THREAD | CLONE_FS;
>
> I suppose that this should be documented.
>
> CLONE_FS prevents the chroot from leaking out of the namespace.  (But
> see the other thread that I'm about to start...)

Never mind.  I thought I saw a bug, but I was wrong.

--Andy
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ