[Bug 241684] autofs: no way to have permissions other than 755 for automounted media

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Mon Nov 25 13:50:09 UTC 2019


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=241684

Edward Tomasz Napierala <trasz at FreeBSD.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Assignee|bugs at FreeBSD.org            |trasz at FreeBSD.org

--- Comment #1 from Edward Tomasz Napierala <trasz at FreeBSD.org> ---
When you mount a filesystem, permissions on a mountpoint are taken from
permissions from the mounted filesystem root directory.  Basically:

% ll
total 6
drwxr-xr-x   3 root  wheel   512 Nov 25 13:04 .
drwxr-xr-x  23 root  wheel  1024 Nov 25 13:04 ..
drwxr-xr-x   3 root  wheel   512 Nov 25 13:44 md0
trasz at v2:/media % ll
total 6
drwxr-xr-x   3 root  wheel   512 Nov 25 13:04 .
drwxr-xr-x  23 root  wheel  1024 Nov 25 13:04 ..
drwxr-xr-x   3 root  wheel   512 Nov 25 13:44 md0
trasz at v2:/media % cd md0 
trasz at v2:/media/md0 % ls -al
total 9
drwxrwxrwx  3 root  wheel     512 Nov 25 13:47 .
drwxr-xr-x  3 root  wheel     512 Nov 25 13:04 ..
drwxrwxr-x  2 root  operator  512 Nov 25 13:46 .snap
trasz at v2:/media/md0 % cd ..
trasz at v2:/media % ls -al
total 9
drwxr-xr-x   3 root  wheel   512 Nov 25 13:04 .
drwxr-xr-x  23 root  wheel  1024 Nov 25 13:04 ..
drwxrwxrwx   3 root  wheel   512 Nov 25 13:47 md0

In this case, "ls -al" triggered mounting an UFS-formatted md0, which, before
the experiment, had "chmod 0777 ." done to its root inode.

What I'm getting at - the permissions on autofs nodes shouldn't matter at all;
it's the mounted filesystem's permissions that's being used for the access
checks.  Could you tell me some more about your scenario?

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-bugs mailing list