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] [day] [month] [year] [list]
Date:   Tue, 2 Nov 2021 12:36:37 +0100
From:   Christian Brauner <christian.brauner@...ntu.com>
To:     Daniel Borkmann <daniel@...earbox.net>,
        Miklos Szeredi <miklos@...redi.hu>
Cc:     Lorenz Bauer <lmb@...udflare.com>,
        Al Viro <viro@...iv.linux.org.uk>,
        Alexei Starovoitov <ast@...nel.org>,
        Andrii Nakryiko <andrii@...nel.org>,
        Miklos Szeredi <mszeredi@...hat.com>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org,
        network dev <netdev@...r.kernel.org>,
        bpf <bpf@...r.kernel.org>,
        Christian Brauner <christian@...uner.io>
Subject: Re: [PATCH bpf-next v3 2/4] libfs: support RENAME_EXCHANGE in
 simple_rename()

On Tue, Nov 02, 2021 at 11:11:02AM +0100, Daniel Borkmann wrote:
> On 11/2/21 10:25 AM, Miklos Szeredi wrote:
> > On Thu, 28 Oct 2021 at 11:48, Lorenz Bauer <lmb@...udflare.com> wrote:
> > > 
> > > Allow atomic exchange via RENAME_EXCHANGE when using simple_rename.
> > > This affects binderfs, ramfs, hubetlbfs and bpffs.
> > 
> > Ramfs and hugetlbfs are generic enough; those seem safe.
> > 
> > Binderfs: I have no idea what this does; binderfs_rename() should

Fwiw, allows dynamic creation and removal of Android binder ipc
devices. Each mount is a separate instance and it's mountable inside
unprivileged containers. Since Android 12 default how binder devices are
managed. Also makes it possibe to run Android in unprivileged
containers.

> > probably error out on RENAME_EXCHANGE for now, or an explicit ack from
> > the maintainers.
> 
> Thanks for the review, Miklos! Adding Christian to Cc wrt binderfs ... full context
> for all patches: https://lore.kernel.org/bpf/20211028094724.59043-1-lmb@cloudflare.com/

Yep, I saw that. Seems good.

> probably error out on RENAME_EXCHANGE for now, or an explicit ack from
> the maintainers.

I don't think there is any issue in allowing binderfs to support this.
Binderfs files are always device nodes. Allowing them to be atomically
renamed shouldn't be a problem. So:

Acked-by: Christian Brauner <christian.brauner@...ntu.com>

Christian

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ