Skip to content
Commit 6076f5f3 authored by Alessio Balsini's avatar Alessio Balsini Committed by Miklos Szeredi
Browse files

fuse: fix matching of FUSE_DEV_IOC_CLONE command

With commit f8425c93 ("fuse: 32-bit user space ioctl compat for fuse
device") the matching constraints for the FUSE_DEV_IOC_CLONE ioctl command
are relaxed, limited to the testing of command type and number.  As Arnd
noticed, this is wrong as it wouldn't ensure the correctness of the data
size or direction for the received FUSE device ioctl.

Fix by bringing back the comparison of the ioctl received by the FUSE
device to the originally generated FUSE_DEV_IOC_CLONE.

Fixes: f8425c93

 ("fuse: 32-bit user space ioctl compat for fuse device")
Reported-by: default avatarArnd Bergmann <arnd@kernel.org>
Signed-off-by: default avatarAlessio Balsini <balsini@android.com>
Signed-off-by: default avatarMiklos Szeredi <mszeredi@redhat.com>
parent aa6ff555
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment