summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/vmw_pvscsi.c
diff options
context:
space:
mode:
authorGobinda Charan Maji <gobinda.cemk07@gmail.com>2015-05-27 03:39:38 +0200
committerRusty Russell <rusty@rustcorp.com.au>2015-05-28 04:02:09 +0200
commit28b8d0c8f560300836dff352348e513cdf328e50 (patch)
tree1386c9e820f553b034a29219a9fc8349b533c258 /drivers/scsi/vmw_pvscsi.c
parentmodule: Rework module_addr_{min,max} (diff)
downloadlinux-28b8d0c8f560300836dff352348e513cdf328e50.tar.xz
linux-28b8d0c8f560300836dff352348e513cdf328e50.zip
sysfs: tightened sysfs permission checks
There were some inconsistency in restriction to VERIFY_OCTAL_PERMISSIONS(). Previously the test was "User perms >= group perms >= other perms". The permission field of User, Group or Other consists of three bits. LSB is EXECUTE permission, MSB is READ permission and the middle bit is WRITE permission. But logically WRITE is "more privileged" than READ. Say for example, permission value is "0430". Here User has only READ permission whereas Group has both WRITE and EXECUTE permission. So, the checks could be tightened and the tests are separated to USER_READABLE >= GROUP_READABLE >= OTHER_READABLE, USER_WRITABLE >= GROUP_WRITABLE and OTHER_WRITABLE is not permitted. Signed-off-by: Gobinda Charan Maji <gobinda.cemk07@gmail.com> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'drivers/scsi/vmw_pvscsi.c')
0 files changed, 0 insertions, 0 deletions