From: Christian Brauner <brauner@kernel.org>
To: Theodore Ts'o <tytso@mit.edu>
Cc: Jeff Layton <jlayton@kernel.org>,
Ondrej Valousek <ondrej.valousek.xm@renesas.com>,
"trondmy@hammerspace.com" <trondmy@hammerspace.com>,
"linux-fsdevel@vger.kernel.org" <linux-fsdevel@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: A pass-through support for NFSv4 style ACL
Date: Fri, 19 May 2023 12:56:55 +0200 [thread overview]
Message-ID: <20230519-allzu-aufmerksam-c3098b5ecf0d@brauner> (raw)
In-Reply-To: <20230517123914.GA4578@mit.edu>
On Wed, May 17, 2023 at 08:39:14AM -0400, Theodore Ts'o wrote:
> On Wed, May 17, 2023 at 09:42:59AM +0200, Christian Brauner wrote:
> >
> > I have no idea about the original flame war that ended RichACLs in
> > additition to having no clear clue what RichACLs are supposed to
> > achieve. My current knowledge extends to "Christoph didn't like them".
>
> As to what RichACL's are supposed to achieve....
Interesting, thanks for all the details!
>
> Windows/NFSv4 -style ACL's are very different from POSIX semantics, in
> a gazillion ways. For example, if you set a top-level acl, it will
> automatically affect all of the ACL's in the subhierarcy. This is
> trivially easy in Windows given that apparently ACL's are evaluated by
> path every time you try to operate on a file (or at least, that's how
> it works effectively; having not taken a look at Windows source code,
> I can't vouch for how it is actually implemented.) This is, of
> course, a performance disaster and doesn't work all that well for
> Linux where we can do things like like fchdir() and use O_PATH file
> descriptors and *at() system calls. Moreover, Windows doesn't have
> things like the mode parameter to open(2) and mkdir(2) system calls.
>
> As a result, RichACL's are quite a bit more complicated than Posix
> ACL's or the Windows-style ACL's from which they were derived because
> they have to compromise between the Windows authorization model and
> the Posix/Linux authorization model while being expressive enough
> to mostly emulate Windows-style ACL's. For example, instead of
> implementing Windows-style "automatic inheritance", setrichacl(1) will
> do the moral equivalent of chmod -R, and then add a lot of hair in the
> form of "file_inherit, dir_inherit, no_propagate, and inherit_only"
> flags to each ACL entry, which are all there to try to mostly (but not
> completely) handle make Windows-style and Linux/POSIX acl's work
> within the same file system. There's a lot more detail of the hair
> documented here[1].
>
> [1] https://www.systutorials.com/docs/linux/man/7-richacl/
>
> I'll note most of this complexity is only necessary if you want to
> have local file access to the file system work with similar semantics
> as what would get exported via NFSv4. If you didn't, you could just
> store the Windows-style ACL in an xattr and just let it be set via the
> remote file system, and return it when the remote file system queries
> it. The problem comes when you want to have "RichACLs" actually
> influence the local Linux permissions check.
Yeah, I'm already scared enough.
next prev parent reply other threads:[~2023-05-19 10:57 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-05-16 12:46 [PATCH] fs: don't call posix_acl_listxattr in generic_listxattr Jeff Layton
2023-05-16 14:17 ` Christian Brauner
[not found] ` <TYXPR01MB18549D3A5B0BE777D7F6B284D9799@TYXPR01MB1854.jpnprd01.prod.outlook.com>
2023-05-16 21:22 ` A pass-through support for NFSv4 style ACL Jeff Layton
2023-05-17 7:42 ` Christian Brauner
2023-05-17 7:45 ` Christoph Hellwig
2023-05-17 7:50 ` Christian Brauner
2023-05-17 9:29 ` Ondrej Valousek
2023-05-17 9:58 ` Jeff Layton
2023-05-17 12:39 ` Theodore Ts'o
2023-05-19 10:56 ` Christian Brauner [this message]
2023-05-19 11:38 ` Ondrej Valousek
2023-05-19 12:02 ` Christian Brauner
2023-09-04 20:36 ` [PATCH] fs: don't call posix_acl_listxattr in generic_listxattr Ondrej Valousek
2023-09-05 10:50 ` Jeff Layton
2023-09-05 11:36 ` Ondrej Valousek
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=20230519-allzu-aufmerksam-c3098b5ecf0d@brauner \
--to=brauner@kernel.org \
--cc=jlayton@kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=ondrej.valousek.xm@renesas.com \
--cc=trondmy@hammerspace.com \
--cc=tytso@mit.edu \
/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
all inboxes | Powered by JetHome®