linux-brain/virt/kvm
Sean Christopherson 9badc8549f KVM: Reject device ioctls from processes other than the VM's creator
commit ddba91801a upstream.

KVM's API requires thats ioctls must be issued from the same process
that created the VM.  In other words, userspace can play games with a
VM's file descriptors, e.g. fork(), SCM_RIGHTS, etc..., but only the
creator can do anything useful.  Explicitly reject device ioctls that
are issued by a process other than the VM's creator, and update KVM's
API documentation to extend its requirements to device ioctls.

Fixes: 852b6d57dc ("kvm: add device control API")
Cc: <stable@vger.kernel.org>
Signed-off-by: Sean Christopherson <sean.j.christopherson@intel.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-04-03 06:25:20 +02:00
..
arm KVM: Call kvm_arch_memslots_updated() before updating memslots 2019-03-23 14:35:31 +01:00
Kconfig License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
async_pf.c kvm,async_pf: Use swq_has_sleeper() 2017-09-15 16:57:11 +02:00
async_pf.h KVM: fix checkpatch.pl errors in kvm/async_pf.h 2015-06-19 17:16:25 +02:00
coalesced_mmio.c License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
coalesced_mmio.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
eventfd.c KVM: irqfd: fix race between EPOLLHUP and irq_bypass_register_consumer 2018-08-24 13:09:21 +02:00
irqchip.c KVM: use rcu access function for irq routing 2017-07-07 15:24:15 +02:00
kvm_main.c KVM: Reject device ioctls from processes other than the VM's creator 2019-04-03 06:25:20 +02:00
vfio.c vfio: New external user group/file match 2017-06-28 13:50:05 -06:00
vfio.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00