OSDN Git Service

virt: vbox: Sanity-check parameter types for hgcm-calls coming from userspace
authorHans de Goede <hdegoede@redhat.com>
Thu, 4 Apr 2019 12:39:09 +0000 (14:39 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 25 Apr 2019 19:52:40 +0000 (21:52 +0200)
commitcf4f2ad6b87dda2dbe0573b1ebeb0273f8d4aac6
tree6d6f2399b6caefb9b2ebf7177652fb3d4150698b
parent0b0509508beff65c1d50541861bc0d4973487dc5
virt: vbox: Sanity-check parameter types for hgcm-calls coming from userspace

Userspace can make host function calls, called hgcm-calls through the
/dev/vboxguest device.

In this case we should not accept all hgcm-function-parameter-types, some
are only valid for in kernel calls.

This commit adds proper hgcm-function-parameter-type validation to the
ioctl for doing a hgcm-call from userspace.

Cc: stable@vger.kernel.org
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/virt/vboxguest/vboxguest_core.c