summaryrefslogtreecommitdiff
path: root/fs
diff options
context:
space:
mode:
authorKusanagi Kouichi <slash@ac.auone-net.jp>2013-01-28 11:33:31 +0000
committerJosef Bacik <jbacik@fusionio.com>2013-02-20 09:37:27 -0500
commit82b22ac8f651aebbf0149cbbbd5808f07753b09c (patch)
treee05ed50f2bba8279d397ea7dc87e65b7e6d5f83d /fs
parentfe5fafbebd7e648aa6cb0a419dc812188b4d4ac8 (diff)
Btrfs: Check CAP_DAC_READ_SEARCH for BTRFS_IOC_INO_PATHS
CAP_DAC_READ_SEARCH overrides read and search permission check on file and directory. It seems fit for BTRFS_IOC_INO_PATHS. Signed-off-by: Kusanagi Kouichi <slash@ac.auone-net.jp> Signed-off-by: Josef Bacik <jbacik@fusionio.com>
Diffstat (limited to 'fs')
-rw-r--r--fs/btrfs/ioctl.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/btrfs/ioctl.c b/fs/btrfs/ioctl.c
index 744aabf11ce5..1b554b47e814 100644
--- a/fs/btrfs/ioctl.c
+++ b/fs/btrfs/ioctl.c
@@ -3290,7 +3290,7 @@ static long btrfs_ioctl_ino_to_path(struct btrfs_root *root, void __user *arg)
struct inode_fs_paths *ipath = NULL;
struct btrfs_path *path;
- if (!capable(CAP_SYS_ADMIN))
+ if (!capable(CAP_DAC_READ_SEARCH))
return -EPERM;
path = btrfs_alloc_path();