Document that client pid/gid/uid may be zero.
authorNikolaus Rath <Nikolaus@rath.org>
Mon, 3 Oct 2016 04:36:12 +0000 (21:36 -0700)
committerNikolaus Rath <Nikolaus@rath.org>
Mon, 3 Oct 2016 04:36:12 +0000 (21:36 -0700)
Fixes #67.

include/fuse_lowlevel.h

index 0822e51e755fa5cd77a1a1f871b2ea12aad80244..37655988237f174aa5538e552ffcded560ce7e22 100644 (file)
@@ -98,7 +98,14 @@ struct fuse_entry_param {
        double entry_timeout;
 };
 
-/** Additional context associated with requests */
+/**
+ * Additional context associated with requests.
+ *
+ * Note that the reported client uid, gid and pid may be zero in some
+ * situations. For example, if the FUSE file system is running in a
+ * PID or user namespace but then accessed from outside the namespace,
+ * there is no valid uid/pid/gid that could be reported.
+ */
 struct fuse_ctx {
        /** User ID of the calling process */
        uid_t uid;
@@ -109,7 +116,7 @@ struct fuse_ctx {
        /** Thread ID of the calling process */
        pid_t pid;
 
-       /** Umask of the calling process (introduced in version 2.8) */
+       /** Umask of the calling process */
        mode_t umask;
 };