aboutsummaryrefslogtreecommitdiff
path: root/lib/test_fortify/write_overflow-memcpy.c
diff options
context:
space:
mode:
authorNiklas Cassel <[email protected]>2021-08-11 11:05:18 +0000
committerJens Axboe <[email protected]>2021-08-24 10:12:36 -0600
commitead3b768bb51259e3a5f2287ff5fc9041eb6f450 (patch)
tree341b117d7d9debcf01e9a49975ed498d28e3e2c9 /lib/test_fortify/write_overflow-memcpy.c
parent158ee7b65653d9f841823c249014c2d0dfdeeb8f (diff)
blk-zoned: allow zone management send operations without CAP_SYS_ADMIN
Zone management send operations (BLKRESETZONE, BLKOPENZONE, BLKCLOSEZONE and BLKFINISHZONE) should be allowed under the same permissions as write(). (write() does not require CAP_SYS_ADMIN). Additionally, other ioctls like BLKSECDISCARD and BLKZEROOUT only check if the fd was successfully opened with FMODE_WRITE. (They do not require CAP_SYS_ADMIN). Currently, zone management send operations require both CAP_SYS_ADMIN and that the fd was successfully opened with FMODE_WRITE. Remove the CAP_SYS_ADMIN requirement, so that zone management send operations match the access control requirement of write(), BLKSECDISCARD and BLKZEROOUT. Fixes: 3ed05a987e0f ("blk-zoned: implement ioctls") Signed-off-by: Niklas Cassel <[email protected]> Reviewed-by: Damien Le Moal <[email protected]> Reviewed-by: Aravind Ramesh <[email protected]> Reviewed-by: Adam Manzanares <[email protected]> Reviewed-by: Himanshu Madhani <[email protected]> Reviewed-by: Johannes Thumshirn <[email protected]> Cc: [email protected] # v4.10+ Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Jens Axboe <[email protected]>
Diffstat (limited to 'lib/test_fortify/write_overflow-memcpy.c')
0 files changed, 0 insertions, 0 deletions