qemu/block
Kevin Wolf 35b7f4abd5 block: Add BDRV_O_NO_SHARE for blk_new_open()
Normally, blk_new_open() just shares all permissions. This was fine
originally when permissions only protected against uses in the same
process because no other part of the code would actually get to access
the block nodes opened with blk_new_open(). However, since we use it for
file locking now, unsharing permissions becomes desirable.

Add a new BDRV_O_NO_SHARE flag that is used in blk_new_open() to unshare
any permissions that can be unshared.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Message-Id: <20210422164344.283389-2-kwolf@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
2021-04-30 12:27:48 +02:00
..
export
monitor
accounting.c
aio_task.c
amend.c
backup-top.c block/backup-top: drop .active 2021-04-30 12:27:48 +02:00
backup-top.h
backup.c
blkdebug.c
blklogwrites.c
blkreplay.c
blkverify.c
block-backend.c block: Add BDRV_O_NO_SHARE for blk_new_open() 2021-04-30 12:27:48 +02:00
block-copy.c
block-gen.h
bochs.c
cloop.c
commit.c block: bdrv_append(): don't consume reference 2021-04-30 12:27:47 +02:00
copy-on-read.c
copy-on-read.h
coroutines.h
create.c
crypto.c
crypto.h
curl.c
dirty-bitmap.c
dmg-bz2.c
dmg-lzfse.c
dmg.c
dmg.h
file-posix.c block: bdrv_reopen_multiple: refresh permissions on updated graph 2021-04-30 12:27:48 +02:00
file-win32.c
filter-compress.c
gluster.c
io_uring.c
io.c block: make bdrv_refresh_limits() to be a transaction action 2021-04-30 12:27:48 +02:00
iscsi-opts.c
iscsi.c
linux-aio.c
meson.build
mirror.c block: bdrv_append(): don't consume reference 2021-04-30 12:27:47 +02:00
nbd.c block/nbd: fix possible use after free of s->connect_thread 2021-04-13 15:35:12 +02:00
nfs.c
null.c
nvme.c
parallels-ext.c
parallels.c
parallels.h
preallocate.c
qapi-sysemu.c
qapi.c
qcow2-bitmap.c
qcow2-cache.c
qcow2-cluster.c
qcow2-refcount.c
qcow2-snapshot.c
qcow2-threads.c
qcow2.c
qcow2.h
qcow.c
qed-check.c
qed-cluster.c
qed-l2-cache.c
qed-table.c
qed.c
qed.h
quorum.c
raw-format.c
rbd.c
replication.c
sheepdog.c
snapshot.c
ssh.c
stream.c
throttle-groups.c
throttle.c
trace-events
trace.h
vdi.c
vhdx-endian.c
vhdx-log.c
vhdx.c
vhdx.h
vmdk.c
vpc.c
vvfat.c
win32-aio.c
write-threshold.c