summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/exported-sql-viewer.py
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2025-06-02 03:11:06 +0300
committerAl Viro <viro@zeniv.linux.org.uk>2025-06-07 08:37:24 +0300
commitc28f922c9dcee0e4876a2c095939d77fe7e15116 (patch)
tree97840ebb01c456fa8edef1485461d5e5ece96444 /tools/perf/scripts/python/exported-sql-viewer.py
parent7054674ee9b9c0c62c2a254243f876f577d36db2 (diff)
downloadlinux-c28f922c9dcee0e4876a2c095939d77fe7e15116.tar.xz
clone_private_mnt(): make sure that caller has CAP_SYS_ADMIN in the right userns
What we want is to verify there is that clone won't expose something hidden by a mount we wouldn't be able to undo. "Wouldn't be able to undo" may be a result of MNT_LOCKED on a child, but it may also come from lacking admin rights in the userns of the namespace mount belongs to. clone_private_mnt() checks the former, but not the latter. There's a number of rather confusing CAP_SYS_ADMIN checks in various userns during the mount, especially with the new mount API; they serve different purposes and in case of clone_private_mnt() they usually, but not always end up covering the missing check mentioned above. Reviewed-by: Christian Brauner <brauner@kernel.org> Reported-by: "Orlando, Noah" <Noah.Orlando@deshaw.com> Fixes: 427215d85e8d ("ovl: prevent private clone if bind mount is not allowed") Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'tools/perf/scripts/python/exported-sql-viewer.py')
0 files changed, 0 insertions, 0 deletions