fs: relax permissions for statmount()
authorChristian Brauner <brauner@kernel.org>
Mon, 24 Jun 2024 15:49:45 +0000 (11:49 -0400)
committerChristian Brauner <brauner@kernel.org>
Fri, 28 Jun 2024 07:53:30 +0000 (09:53 +0200)
commitf3107df39df123328a9d3c8f40c006834b37287d
tree31786fcfcaefe4b6dfe644b36486fa5d651b52b0
parentdd7cb142f467c4660698bcaa4a48c688b443ab81
fs: relax permissions for statmount()

It is sufficient to have capabilities in the owning user namespace of
the mount namespace to stat a mount regardless of whether it's reachable
or not.

Link: https://lore.kernel.org/r/bf5961d71ec479ba85806766b0d8d96043e67bba.1719243756.git.josef@toxicpanda.com
Signed-off-by: Christian Brauner <brauner@kernel.org>
fs/namespace.c