From 005e27e3b3086a65499d81923551be68e8c3400a Mon Sep 17 00:00:00 2001 From: George Melikov Date: Tue, 31 Jan 2017 21:24:23 +0300 Subject: OpenZFS 7019 - zfsdev_ioctl skips secpolicy when FKIOCTL is set Authored by: Alex Wilson Reviewed by: Robert Mustacchi Reviewed by: Richard Lowe Reviewed by: Matthew Ahrens Approved by: Dan McDonald Reviewed-by: Brian Behlendorf Ported-by: George Melikov OpenZFS-issue: https://www.illumos.org/issues/7019 OpenZFS-commit: https://github.com/openzfs/openzfs/commit/45b1747 Closes #5709 --- module/zfs/zfs_ioctl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/module/zfs/zfs_ioctl.c b/module/zfs/zfs_ioctl.c index 8ae4300f5..8aa69231a 100644 --- a/module/zfs/zfs_ioctl.c +++ b/module/zfs/zfs_ioctl.c @@ -24,7 +24,7 @@ * Portions Copyright 2011 Martin Matuska * Copyright 2015, OmniTI Computer Consulting, Inc. All rights reserved. * Portions Copyright 2012 Pawel Jakub Dawidek - * Copyright (c) 2012, Joyent, Inc. All rights reserved. + * Copyright (c) 2014, 2016 Joyent, Inc. All rights reserved. * Copyright 2016 Nexenta Systems, Inc. All rights reserved. * Copyright (c) 2014, Joyent, Inc. All rights reserved. * Copyright (c) 2011, 2015 by Delphix. All rights reserved. @@ -6291,7 +6291,7 @@ zfsdev_ioctl(struct file *filp, unsigned cmd, unsigned long arg) } - if (error == 0 && !(flag & FKIOCTL)) { + if (error == 0) { cookie = spl_fstrans_mark(); error = vec->zvec_secpolicy(zc, innvl, CRED()); spl_fstrans_unmark(cookie); -- cgit v1.2.3