aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile.am4
-rw-r--r--README.md2
-rw-r--r--doc/Makefile.am2
-rw-r--r--doc/fusermount3.1 (renamed from doc/fusermount.1)12
-rw-r--r--doc/kernel.txt8
-rw-r--r--doc/mount.fuse.817
-rw-r--r--lib/mount.c8
-rw-r--r--test/util.py4
-rw-r--r--util/Makefile.am4
-rw-r--r--util/fusermount.c10
-rwxr-xr-xutil/init_script2
11 files changed, 37 insertions, 36 deletions
diff --git a/Makefile.am b/Makefile.am
index 33b8e0a..4e95a71 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -17,14 +17,14 @@ $(pkgconfig_DATA): config.status
.PHONY: setuid_fusermount
setuid_fusermount:
- @echo "Attempting to use sudo to make util/fusermount setuid root"
+ @echo "Attempting to use sudo to make util/fusermount3 setuid root"
@echo "If this fails, set permissions manually and re-run make test"
test $$(ls -n util/fusermount3 | awk 'NR==1 {print $$3}') -eq 0 || \
sudo chown root util/fusermount3
test -u util/fusermount3 || \
sudo chmod u+s util/fusermount3
-# If we are not root, util/fusermount needs to be setuid root
+# If we are not root, util/fusermount3 needs to be setuid root
# for tests to work.
test_deps = $(shell [ "$${UID}" -eq 0 ] || echo setuid_fusermount)
diff --git a/README.md b/README.md
index f2d9ceb..ae41719 100644
--- a/README.md
+++ b/README.md
@@ -73,7 +73,7 @@ contain FUSE support).
Security implications
---------------------
-If you run `make install`, the *fusermount* program is installed
+If you run `make install`, the *fusermount3* program is installed
set-user-id to root. This is done to allow normal users to mount
their own filesystem implementations.
diff --git a/doc/Makefile.am b/doc/Makefile.am
index f92214b..8801da2 100644
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
@@ -1,5 +1,5 @@
## Process this file with automake to produce Makefile.in
-dist_man_MANS = fusermount.1 mount.fuse.8
+dist_man_MANS = fusermount3.1 mount.fuse.8
EXTRA_DIST = kernel.txt Doxyfile html README.NFS
diff --git a/doc/fusermount.1 b/doc/fusermount3.1
index 9f4cd5a..6f94e42 100644
--- a/doc/fusermount.1
+++ b/doc/fusermount3.1
@@ -1,18 +1,18 @@
-.TH FUSERMOUNT 1 2011\-10\-23 2.8.6 "Filesystem in Userspace (FUSE)"
+.TH FUSERMOUNT3 1 2011\-10\-23 2.8.6 "Filesystem in Userspace (FUSE)"
.SH NAME
-\fBfusermount\fR \- mount and unmount FUSE filesystems
+\fBfusermount3\fR \- mount and unmount FUSE filesystems
.SH SYNOPSIS
-\fBfusermount\fR [\fIOPTIONS\fR] \fIMOUNTPOINT\fR
+\fBfusermount3\fR [\fIOPTIONS\fR] \fIMOUNTPOINT\fR
.SH DESCRIPTION
Filesystem in Userspace (FUSE) is a simple interface for userspace programs to export a virtual filesystem to the Linux kernel. It also aims to provide a secure method for non privileged users to create and mount their own filesystem implementations.
.PP
-\fBfusermount\fR is a program to mount and unmount FUSE
+\fBfusermount3\fR is a program to mount and unmount FUSE
filesystems. It should be called directly only for unmounting FUSE
file systems. To allow mounting and unmounting by unprivileged users,
-\fBfusermount\fR needs to be installed set-uid root.
+\fBfusermount3\fR needs to be installed set-uid root.
.SH OPTIONS
.IP "\-h" 4
print help.
@@ -32,7 +32,7 @@ lazy unmount.
\fImount.fuse\fR(8),
.SH HOMEPAGE
-More information about fusermount and the FUSE project can be found at <\fIhttp://fuse.sourceforge.net/\fR>.
+More information about fusermount3 and the FUSE project can be found at <\fIhttp://fuse.sourceforge.net/\fR>.
.SH AUTHORS
.LP
diff --git a/doc/kernel.txt b/doc/kernel.txt
index 7938aab..e73484f 100644
--- a/doc/kernel.txt
+++ b/doc/kernel.txt
@@ -39,7 +39,7 @@ What is FUSE?
FUSE is a userspace filesystem framework. It consists of a kernel
module (fuse.ko), a userspace library (libfuse.*) and a mount utility
-(fusermount).
+(fusermount3).
One of the most important features of FUSE is allowing secure,
non-privileged mounts. This opens up new possibilities for the use of
@@ -176,7 +176,7 @@ How do non-privileged mounts work?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Since the mount() system call is a privileged operation, a helper
-program (fusermount) is needed, which is installed setuid root.
+program (fusermount3) is needed, which is installed setuid root.
The implication of providing non-privileged mounts is that the mount
owner must not be able to use this capability to compromise the
@@ -204,7 +204,7 @@ How are requirements fulfilled?
The solution is not to allow opening device files and ignore
setuid and setgid bits when executing programs. To ensure this
- fusermount always adds "nosuid" and "nodev" to the mount options
+ fusermount3 always adds "nosuid" and "nodev" to the mount options
for non-privileged mounts.
B) If another user is accessing files or directories in the
@@ -222,7 +222,7 @@ How are requirements fulfilled?
owner could otherwise not be able to modify (or could only
make limited modifications).
- This is solved in fusermount, by checking the access
+ This is solved in fusermount3, by checking the access
permissions on the mountpoint and only allowing the mount if
the mount owner can do unlimited modification (has write
access to the mountpoint, and mountpoint is not a "sticky"
diff --git a/doc/mount.fuse.8 b/doc/mount.fuse.8
index 81c498e..c42894b 100644
--- a/doc/mount.fuse.8
+++ b/doc/mount.fuse.8
@@ -16,14 +16,14 @@ kernel.
\fBlibfuse\fP
The shared library that most (user-space) filesystems use to
communicate with FUSE (the kernel filesystem). libfuse also provides
-the \fBfusermount\fP helper to allow non-privileged users to mount
-filesystems.
+the \fBfusermount3\fP (or \fBfusermount\fP if you have older version of
+libfuse) helper to allow non-privileged users to mount filesystems.
.TP
\fBfilesystem owner\fP
The user that starts the filesystem and instructs the kernel to
associate it with a particular mountpoint. The latter is typically done
by the filesystem itself on start-up. When using libfuse, this is done
-by calling the \fBfusermount\fP utility.
+by calling the \fBfusermount3\fP utility.
.TP
\fBclient\fP
Any process that interacts with the mountpoint.
@@ -37,7 +37,7 @@ Set the maximum number of FUSE mounts allowed to non-root users. The default is
Allow non-root users to specify the \fBallow_other\fP or
\fBallow_root\fP mount options (see below).
.TP
-These limits are enforced by the \fBfusermount\fP helper, so they can be avoided by filesystems that run as root.
+These limits are enforced by the \fBfusermount3\fP helper, so they can be avoided by filesystems that run as root.
.SH OPTIONS
Most of the generic mount options described in \fBmount\fP are
supported (\fBro\fP, \fBrw\fP, \fBsuid\fP, \fBnosuid\fP, \fBdev\fP,
@@ -217,7 +217,7 @@ Transform absolute symlinks into relative
\fBnorellinks\fP
Do not transform absolute symlinks into relative. This is the default.
.SH SECURITY
-The fusermount program is installed set-user-gid to fuse. This is done to allow users from fuse group to mount
+The fusermount3 program is installed set-user-gid to fuse. This is done to allow users from fuse group to mount
their own filesystem implementations.
There must however be some limitations, in order to prevent Bad User from
doing nasty things. Currently those limitations are:
@@ -228,7 +228,7 @@ The mountpoint is not a sticky directory which isn't owned by the user (like \fI
.IP 3.
No other user (including root) can access the contents of the mounted filesystem.
.SH NOTE
-FUSE filesystems are unmounted using the \fBfusermount\fP(1) command (\fBfusermount -u mountpoint\fP).
+FUSE filesystems are unmounted using the \fBfusermount3\fP(1) command (\fBfusermount3 -u mountpoint\fP).
.SH "AUTHORS"
.LP
FUSE is currently maintained by Nikolaus Rath <Nikolaus@rath.org>
@@ -238,5 +238,6 @@ The original author of FUSE is Miklos Szeredi <mszeredi@inf.bme.hu>.
This man page was originally written by Bastien Roucaries <roucaries.bastien+debian@gmail.com> for the
Debian GNU/Linux distribution.
.SH SEE ALSO
-fusermount(1)
-mount(8)
+.BR fusermount3 (1)
+.BR fusermount (1)
+.BR mount (8)
diff --git a/lib/mount.c b/lib/mount.c
index 8fbebbf..d19242e 100644
--- a/lib/mount.c
+++ b/lib/mount.c
@@ -356,7 +356,7 @@ static int fuse_mount_fusermount(const char *mountpoint, struct mount_opts *mo,
snprintf(env, sizeof(env), "%i", fds[0]);
setenv(FUSE_COMMFD_ENV, env, 1);
exec_fusermount(argv);
- perror("fuse: failed to exec fusermount");
+ perror("fuse: failed to exec fusermount3");
_exit(1);
}
@@ -364,7 +364,7 @@ static int fuse_mount_fusermount(const char *mountpoint, struct mount_opts *mo,
rv = receive_fd(fds[1]);
if (!mo->auto_unmount) {
- /* with auto_unmount option fusermount will not exit until
+ /* with auto_unmount option fusermount3 will not exit until
this socket is closed */
close(fds[1]);
waitpid(pid, NULL, 0); /* bury zombie */
@@ -404,7 +404,7 @@ static int fuse_mount_sys(const char *mnt, struct mount_opts *mo,
}
if (mo->auto_unmount) {
- /* Tell the caller to fallback to fusermount because
+ /* Tell the caller to fallback to fusermount3 because
auto-unmount does not work otherwise. */
return -2;
}
@@ -462,7 +462,7 @@ static int fuse_mount_sys(const char *mnt, struct mount_opts *mo,
if (res == -1) {
/*
* Maybe kernel doesn't support unprivileged mounts, in this
- * case try falling back to fusermount
+ * case try falling back to fusermount3
*/
if (errno == EPERM) {
res = -2;
diff --git a/test/util.py b/test/util.py
index 4f8e123..76b8ec1 100644
--- a/test/util.py
+++ b/test/util.py
@@ -28,7 +28,7 @@ def cleanup(mnt_dir):
stderr=subprocess.STDOUT)
def umount(mount_process, mnt_dir):
- # fusermount will be setuid root, so we can only trace it with
+ # fusermount3 will be setuid root, so we can only trace it with
# valgrind if we're root
if os.getuid() == 0:
cmdline = base_cmdline
@@ -85,5 +85,5 @@ else:
base_cmdline = []
-# Try to use local fusermount
+# Try to use local fusermount3
os.environ['PATH'] = '%s:%s' % (pjoin(basename, 'util'), os.environ['PATH'])
diff --git a/util/Makefile.am b/util/Makefile.am
index 32c4e1e..756afea 100644
--- a/util/Makefile.am
+++ b/util/Makefile.am
@@ -33,7 +33,7 @@ install-exec-local:
$(MKDIR_P) $(DESTDIR)$(MOUNT_FUSE_PATH)
$(INSTALL_PROGRAM) $(builddir)/mount.fuse3 $(DESTDIR)$(MOUNT_FUSE_PATH)/mount.fuse3
$(MKDIR_P) $(DESTDIR)$(INIT_D_PATH)
- $(INSTALL_SCRIPT) $(srcdir)/init_script $(DESTDIR)$(INIT_D_PATH)/fuse
+ $(INSTALL_SCRIPT) $(srcdir)/init_script $(DESTDIR)$(INIT_D_PATH)/fuse3
@if test -x /usr/sbin/update-rc.d; then \
echo "/usr/sbin/update-rc.d fuse start 34 S . start 41 0 6 . || true"; \
/usr/sbin/update-rc.d fuse start 34 S . start 41 0 6 . || true; \
@@ -41,7 +41,7 @@ install-exec-local:
install-data-local:
$(MKDIR_P) $(DESTDIR)$(UDEV_RULES_PATH)
- $(INSTALL_DATA) $(srcdir)/udev.rules $(DESTDIR)$(UDEV_RULES_PATH)/99-fuse.rules
+ $(INSTALL_DATA) $(srcdir)/udev.rules $(DESTDIR)$(UDEV_RULES_PATH)/99-fuse3.rules
uninstall-local:
rm -f $(DESTDIR)$(MOUNT_FUSE_PATH)/mount.fuse3
diff --git a/util/fusermount.c b/util/fusermount.c
index 03da451..0f65435 100644
--- a/util/fusermount.c
+++ b/util/fusermount.c
@@ -209,10 +209,10 @@ static int may_unmount(const char *mnt, int quiet)
}
/*
- * Check whether the file specified in "fusermount -u" is really a
+ * Check whether the file specified in "fusermount3 -u" is really a
* mountpoint and not a symlink. This is necessary otherwise the user
* could move the mountpoint away and replace it with a symlink
- * pointing to an arbitrary mount, thereby tricking fusermount into
+ * pointing to an arbitrary mount, thereby tricking fusermount3 into
* unmounting that (umount(2) will follow symlinks).
*
* This is the child process running in a separate mount namespace, so
@@ -780,7 +780,7 @@ static int do_mount(const char *mnt, char **typep, mode_t rootmode,
if (getuid() != 0 && !user_allow_other &&
(opt_eq(s, len, "allow_other") ||
opt_eq(s, len, "allow_root"))) {
- fprintf(stderr, "%s: option %.*s only allowed if 'user_allow_other' is set in /etc/fuse.conf\n", progname, len, s);
+ fprintf(stderr, "%s: option %.*s only allowed if 'user_allow_other' is set in %s\n", progname, len, s, FUSE_CONF);
goto err;
}
if (!skip_option) {
@@ -1022,7 +1022,7 @@ static int mount_fuse(const char *mnt, const char *opts)
if (getuid() != 0 && mount_max != -1) {
int mount_count = count_fuse_fs();
if (mount_count >= mount_max) {
- fprintf(stderr, "%s: too many FUSE filesystems mounted; mount_max=N can be set in /etc/fuse.conf\n", progname);
+ fprintf(stderr, "%s: too many FUSE filesystems mounted; mount_max=N can be set in %s\n", progname, FUSE_CONF);
goto fail_close_fd;
}
}
@@ -1119,7 +1119,7 @@ static void usage(void)
static void show_version(void)
{
- printf("fusermount version: %s\n", PACKAGE_VERSION);
+ printf("fusermount3 version: %s\n", PACKAGE_VERSION);
exit(0);
}
diff --git a/util/init_script b/util/init_script
index 331b33a..4815e7b 100755
--- a/util/init_script
+++ b/util/init_script
@@ -17,7 +17,7 @@ PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
MOUNTPOINT=/sys/fs/fuse/connections
# Gracefully exit if the package has been removed.
-which fusermount &>/dev/null || exit 5
+which fusermount3 &>/dev/null || exit 5
case "$1" in
start|restart|force-reload)