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:   Wed, 10 Mar 2021 09:22:16 -0800
From:   Casey Schaufler <casey@...aufler-ca.com>
To:     Mickaël Salaün <mic@...ikod.net>,
        Al Viro <viro@...iv.linux.org.uk>,
        James Morris <jmorris@...ei.org>,
        Serge Hallyn <serge@...lyn.com>
Cc:     Andy Lutomirski <luto@...capital.net>,
        Christian Brauner <christian.brauner@...ntu.com>,
        Christoph Hellwig <hch@....de>,
        David Howells <dhowells@...hat.com>,
        Dominik Brodowski <linux@...inikbrodowski.net>,
        Eric Biederman <ebiederm@...ssion.com>,
        John Johansen <john.johansen@...onical.com>,
        Kees Cook <keescook@...omium.org>,
        Kentaro Takeda <takedakn@...data.co.jp>,
        Tetsuo Handa <penguin-kernel@...ove.sakura.ne.jp>,
        kernel-hardening@...ts.openwall.com, linux-fsdevel@...r.kernel.org,
        linux-kernel@...r.kernel.org,
        linux-security-module@...r.kernel.org,
        Casey Schaufler <casey@...aufler-ca.com>
Subject: Re: [PATCH v1 0/1] Unprivileged chroot

On 3/10/2021 8:09 AM, Mickaël Salaün wrote:
> Hi,
>
> The chroot system call is currently limited to be used by processes with
> the CAP_SYS_CHROOT capability.  This protects against malicious
> procesess willing to trick SUID-like binaries.  The following patch
> allows unprivileged users to safely use chroot(2).

Mount namespaces have pretty well obsoleted chroot(). CAP_SYS_CHROOT is
one of the few fine grained capabilities. We're still finding edge cases
(e.g. ptrace) where no_new_privs is imperfect. I doesn't seem that there
is a compelling reason to remove the privilege requirement on chroot().

>
> This patch is a follow-up of a previous one sent by Andy Lutomirski some
> time ago:
> https://lore.kernel.org/lkml/0e2f0f54e19bff53a3739ecfddb4ffa9a6dbde4d.1327858005.git.luto@amacapital.net/
>
> This patch can be applied on top of v5.12-rc2 .  I would really
> appreciate constructive reviews.
>
> Regards,
>
> Mickaël Salaün (1):
>   fs: Allow no_new_privs tasks to call chroot(2)
>
>  fs/open.c | 64 ++++++++++++++++++++++++++++++++++++++++++++++++++++---
>  1 file changed, 61 insertions(+), 3 deletions(-)
>
>
> base-commit: a38fd8748464831584a19438cbb3082b5a2dab15

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ