From: Miklos Szeredi <miklos@szeredi.hu>
To: akpm@linux-foundation.org, hch@infradead.org, serue@us.ibm.com,
viro@zeniv.linux.org.uk
Cc: linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [patch 00/11] mount ownership and unprivileged mount syscall (v9)
Date: Mon, 17 Mar 2008 21:00:53 +0100 [thread overview]
Message-ID: <20080317200053.447640802@szeredi.hu> (raw)
Andrew, Al,
Please consider adding this series to your trees.
I've been using these patches for a while on my laptop to mount fuse
filesystems as user, without any suid-root helpers. The setup is as
follows:
- link /proc/mounts to /etc/mtab
- patch util-linux-ng with http://lkml.org/lkml/2008/1/16/103
- remove suid from mount, umount and fusermount
- add a line to /etc/fstab to bind mount ~/mnt onto itself owned by the user
- add 'fs.types.fuse.usermount_safe = 1' to /etc/sysctl.conf
Apart from '/dev/sda2' being replaced with '/dev/root' in 'mount' and
'df' outputs, I haven't experienced any problems.
Thanks,
Miklos
v8 -> v9
- new patch: copy mount ownership when cloning the mount namespace
v7 -> v8
- extend documentation of allow_usermount sysctl tunable
- describe new unprivileged mounting in fuse.txt
v6 -> v7:
- add '/proc/sys/fs/types/<type>/usermount_safe' tunable (new patch)
- do not make FUSE safe by default, describe possible problems
associated with unprivileged FUSE mounts in patch header
- return EMFILE instead of EPERM, if maximum user mount count is exceeded
- rename option 'nomnt' -> 'nosubmnt'
- clean up error propagation in dup_mnt_ns
- update util-linux-ng patch
v5 -> v6:
- update to latest -mm
- preliminary util-linux-ng support (will post right after this series)
v4 -> v5:
- fold back Andrew's changes
- fold back my update patch:
o use fsuid instead of ruid
o allow forced unpriv. unmounts for "safe" filesystems
o allow mounting over special files, but not over symlinks
o set nosuid and nodev based on lack of specific capability
- patch header updates
- new patch: on propagation inherit owner from parent
- new patch: add "no submounts" mount flag
v3 -> v4:
- simplify interface as much as possible, now only a single option
("user=UID") is used to control everything
- no longer allow/deny mounting based on file/directory permissions,
that approach does not always make sense
v1 -> v3:
- add mount flags to set/clear mnt_flags individually
- add "usermnt" mount flag. If it is set, then allow unprivileged
submounts under this mount
- make max number of user mounts default to 1024, since now the
usermnt flag will prevent user mounts by default
--
next reply other threads:[~2008-03-17 20:03 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-03-17 20:00 Miklos Szeredi [this message]
2008-03-17 20:00 ` [patch 01/11] unprivileged mounts: add user mounts to the kernel Miklos Szeredi
2008-03-17 20:00 ` [patch 02/11] unprivileged mounts: allow unprivileged umount Miklos Szeredi
2008-03-17 20:00 ` [patch 03/11] unprivileged mounts: propagate error values from clone_mnt Miklos Szeredi
2008-03-17 20:00 ` [patch 04/11] unprivileged mounts: account user mounts Miklos Szeredi
2008-03-17 20:00 ` [patch 05/11] unprivileged mounts: allow unprivileged bind mounts Miklos Szeredi
2008-03-17 20:00 ` [patch 06/11] unprivileged mounts: allow unprivileged mounts Miklos Szeredi
2008-03-17 20:01 ` [patch 07/11] unprivileged mounts: add sysctl tunable for "safe" property Miklos Szeredi
2008-03-17 20:01 ` [patch 08/11] unprivileged mounts: make fuse safe Miklos Szeredi
2008-03-17 20:01 ` [patch 09/11] unprivileged mounts: propagation: inherit owner from parent Miklos Szeredi
2008-03-17 20:01 ` [patch 10/11] unprivileged mounts: add "no submounts" flag Miklos Szeredi
2008-03-17 20:01 ` [patch 11/11] unprivileged mounts: copy mount ownership on namespace cloning Miklos Szeredi
2008-03-17 22:51 ` [patch 00/11] mount ownership and unprivileged mount syscall (v9) James Morris
2008-03-18 11:33 ` Miklos Szeredi
2008-03-18 23:04 ` James Morris
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20080317200053.447640802@szeredi.hu \
--to=miklos@szeredi.hu \
--cc=akpm@linux-foundation.org \
--cc=hch@infradead.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=serue@us.ibm.com \
--cc=viro@zeniv.linux.org.uk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox