On Wed, Dec 6, 2023 at 3:28 AM Andrii Nakryiko <andrii.nakryiko@xxxxxxxxx> wrote: > > On Tue, Dec 5, 2023 at 8:31 AM Christian Brauner <brauner@xxxxxxxxxx> wrote: > > > > On Fri, Dec 01, 2023 at 09:47:29AM +0000, Jie Jiang wrote: >> ... > > Sorry, I was asked to take a quick look at this. The patchset looks fine > > overall but it will interact with Andrii's patchset which makes bpffs > > mountable inside a user namespace (with caveats). > > > > At that point you need additional validation in bpf_parse_param(). The > > simplest thing would probably to just put this into this series or into > > @Andrii's series. It's basically a copy-pasta from what I did for tmpfs > > (see below). > > > > I plan to move this validation into the VFS so that {g,u}id mount > > options are validated consistenly for any such filesystem. There is just > > some unpleasantness that I have to figure out first. > > Thank you very much for the suggestions and discussions. I uploaded the v2 version of this patch to include the checks as you suggested. > > @Andrii, with the {g,u}id mount option it means that userns root can > > ... > [...]