]> git.proxmox.com Git - mirror_ubuntu-zesty-kernel.git/commit
UBUNTU: SAUCE: overlayfs: Skip permission checking for trusted.overlayfs.* xattrs
authorSeth Forshee <seth.forshee@canonical.com>
Tue, 19 Jan 2016 19:12:02 +0000 (13:12 -0600)
committerTim Gardner <tim.gardner@canonical.com>
Mon, 20 Feb 2017 03:57:58 +0000 (20:57 -0700)
commit25b3313864fa084d241d0055a00fa5f799216770
tree0a89d114013f6c8cc75b95593821089e64d3c7ef
parentb79f99b5a3ab3b50fb2e3bd2db71196c2a2ea84d
UBUNTU: SAUCE: overlayfs: Skip permission checking for trusted.overlayfs.* xattrs

The original mounter had CAP_SYS_ADMIN in the user namespace
where the mount happened, and the vfs has validated that the user
has permission to do the requested operation. This is sufficient
for allowing the kernel to write these specific xattrs, so we can
bypass the permission checks for these xattrs.

To support this, export __vfs_setxattr_noperm and add an similar
__vfs_removexattr_noperm which is also exported. Use these when
setting or removing trusted.overlayfs.* xattrs.

BugLink: http://bugs.launchpad.net/bugs/1531747
BugLink: http://bugs.launchpad.net/bugs/1534961
BugLink: http://bugs.launchpad.net/bugs/1535150
Signed-off-by: Seth Forshee <seth.forshee@canonical.com>
fs/overlayfs/overlayfs.h
fs/xattr.c
include/linux/xattr.h