mirror_zfs/module/os/freebsd/zfs
Allan Jude 595d3ac2ed
Allow mounting snapshots in .zfs/snapshot as a regular user
Rather than doing a terrible credential swapping hack, we just
check that the thing being mounted is a snapshot, and the mountpoint
is the zfsctl directory, then we allow it.

If the mount attempt is from inside a jail, on an unjailed dataset
(mounted from the host, not by the jail), the ability to mount the
snapshot is controlled by a new per-jail parameter: zfs.mount_snapshot

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Co-authored-by: Ryan Moeller <ryan@iXsystems.com>
Signed-off-by: Ryan Moeller <ryan@iXsystems.com>
Signed-off-by: Allan Jude <allan@klarasystems.com>
Sponsored-by: Modirum MDPay
Sponsored-by: Klara Inc.
Closes #13758
2022-11-03 11:53:24 -07:00
..
abd_os.c FreeBSD: use zero_region instead of allocating a dedicated page 2022-05-04 11:46:37 -07:00
arc_os.c Cleanup: Specify unsignedness on things that should not be signed 2022-09-27 16:42:41 -07:00
crypto_os.c FreeBSD: Improve crypto_dispatch() handling 2022-06-17 15:38:51 -07:00
dmu_os.c Remove bcopy(), bzero(), bcmp() 2022-03-15 15:13:42 -07:00
event_os.c FreeBSD: add knlist_init_sx() for exclusive locks 2022-09-06 09:48:57 -07:00
hkdf.c Remove bcopy(), bzero(), bcmp() 2022-03-15 15:13:42 -07:00
kmod_core.c FreeBSD: Replace legacy make_dev() interface usage 2022-09-08 10:40:18 -07:00
spa_os.c FreeBSD: Fix uninitialized pointer read in spa_import_rootpool() 2022-09-20 14:43:03 -07:00
sysctl_os.c Cleanup: 64-bit kernel module parameters should use fixed width types 2022-10-13 10:03:29 -07:00
vdev_file.c Cleanup: 64-bit kernel module parameters should use fixed width types 2022-10-13 10:03:29 -07:00
vdev_geom.c Improve too large physical ashift handling 2022-09-08 10:30:53 -07:00
vdev_label_os.c Replace dead opensolaris.org license link 2022-07-11 14:16:13 -07:00
zfs_acl.c acl: use uintptr_t for ace walker cookies 2022-11-03 09:51:34 -07:00
zfs_ctldir.c FreeBSD: stop passing LK_INTERLOCK to VOP_LOCK 2022-09-19 17:17:27 -07:00
zfs_debug.c Cleanup: Specify unsignedness on things that should not be signed 2022-09-27 16:42:41 -07:00
zfs_dir.c Support idmapped mount 2022-10-19 11:17:09 -07:00
zfs_file_os.c FreeBSD: handle V_PCATCH 2022-09-20 15:22:32 -07:00
zfs_ioctl_compat.c FreeBSD compile fix 2022-07-28 14:19:41 -07:00
zfs_ioctl_os.c libzfs: On FreeBSD, use MNT_NOWAIT with getfsstat 2021-06-08 07:36:43 -06:00
zfs_racct.c module: zfs: fix unused, remove argsused 2021-12-23 09:42:47 -08:00
zfs_vfsops.c Allow mounting snapshots in .zfs/snapshot as a regular user 2022-11-03 11:53:24 -07:00
zfs_vnops_os.c zfs_rename: support RENAME_* flags 2022-10-28 09:49:20 -07:00
zfs_znode.c Support idmapped mount 2022-10-19 11:17:09 -07:00
zio_crypt.c Cleanup: Address Clang's static analyzer's unused code complaints 2022-10-14 13:37:54 -07:00
zvol_os.c FreeBSD: add kqfilter support for zvol cdev 2022-09-06 09:49:33 -07:00