]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/commit - fs/block_dev.c
UBUNTU: SAUCE: (namespace) block_dev: Check permissions towards block device inode...
authorSeth Forshee <seth.forshee@canonical.com>
Wed, 7 Oct 2015 19:49:47 +0000 (14:49 -0500)
committerSeth Forshee <seth.forshee@canonical.com>
Tue, 5 Sep 2017 12:33:35 +0000 (07:33 -0500)
commit47aae6808e810aafd39d6bfc52cf3e6e2cbe4a5c
tree1cb9f0516fd09018262f27b032f26e8b51f5f6bf
parentcb2179f5ec6b317b9c1f90b97c7faf6a16fb2dbf
UBUNTU: SAUCE: (namespace) block_dev: Check permissions towards block device inode when mounting

Unprivileged users should not be able to mount block devices when
they lack sufficient privileges towards the block device inode.
Update blkdev_get_by_path() to validate that the user has the
required access to the inode at the specified path. The check
will be skipped for CAP_SYS_ADMIN, so privileged mounts will
continue working as before.

Acked-by: Serge Hallyn <serge.hallyn@canonical.com>
Signed-off-by: Seth Forshee <seth.forshee@canonical.com>
fs/block_dev.c