diff options
author | Martin Natano <natano@cvs.openbsd.org> | 2016-10-11 07:02:47 +0000 |
---|---|---|
committer | Martin Natano <natano@cvs.openbsd.org> | 2016-10-11 07:02:47 +0000 |
commit | ee47009059623f31cebd95ff4e755100da541d0e (patch) | |
tree | d5dacb0aeab48e4af8e9f94457385cb57cd180b5 /sbin/newfs | |
parent | 7034220ec44fc906911233a84f6d28d2def05c61 (diff) |
Enable the noperm option for mount_mfs. mfs is ffs in sheeps clothing,
so we basically get this for free.
requested by espie
ok deraadt
Diffstat (limited to 'sbin/newfs')
-rw-r--r-- | sbin/newfs/newfs.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sbin/newfs/newfs.c b/sbin/newfs/newfs.c index 21145752b9a..7a914eea22f 100644 --- a/sbin/newfs/newfs.c +++ b/sbin/newfs/newfs.c @@ -1,4 +1,4 @@ -/* $OpenBSD: newfs.c,v 1.108 2016/07/25 15:30:36 krw Exp $ */ +/* $OpenBSD: newfs.c,v 1.109 2016/10/11 07:02:46 natano Exp $ */ /* $NetBSD: newfs.c,v 1.20 1996/05/16 07:13:03 thorpej Exp $ */ /* @@ -78,6 +78,7 @@ struct mntopt mopts[] = { MOPT_STDOPTS, MOPT_WXALLOWED, + MOPT_NOPERM, MOPT_ASYNC, MOPT_UPDATE, MOPT_FORCE, @@ -522,6 +523,8 @@ havelabel: args.export_info.ex_root = -2; if (mntflags & MNT_RDONLY) args.export_info.ex_flags = MNT_EXRDONLY; + if (mntflags & MNT_NOPERM) + mntflags |= MNT_NODEV | MNT_NOEXEC; switch (pid = fork()) { case -1: |