]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
fusefs: WIP supporting -o default_permissions
authorasomers <asomers@FreeBSD.org>
Wed, 10 Apr 2019 17:31:00 +0000 (17:31 +0000)
committerasomers <asomers@FreeBSD.org>
Wed, 10 Apr 2019 17:31:00 +0000 (17:31 +0000)
commit79e82cb45e8f20f93dbb73cb9835f3d85773fe98
tree8482d155af4ec440323165de2760a089f07e198e
parenta1b1462fe340f8ffe25e43919babf9e260894a12
fusefs: WIP supporting -o default_permissions

Normally all permission checking is done in the fuse server.  But when -o
default_permissions is used, it should be done in the kernel instead.  This
commit adds appropriate permission checks through fusefs when -o
default_permissions is used.  However, sticky bit checks aren't working yet.
I'll handle those in a follow-up commit.

There are no checks for file flags, because those aren't supported by our
version of the FUSE protocol.  Nor is there any support for ACLs, though
that could be added if there were any demand.

PR: 216391
Reported by: hiyorin@gmail.com
Sponsored by: The FreeBSD Foundation
sys/fs/fuse/fuse_internal.c
sys/fs/fuse/fuse_internal.h
sys/fs/fuse/fuse_vnops.c
tests/sys/fs/fusefs/default_permissions.cc
tests/sys/fs/fusefs/destroy.cc
tests/sys/fs/fusefs/lookup.cc
tests/sys/fs/fusefs/setattr.cc
tests/sys/fs/fusefs/unlink.cc
tests/sys/fs/fusefs/utils.cc
tests/sys/fs/fusefs/utils.hh
tests/sys/fs/fusefs/xattr.cc