Re: posix_acl_permission() and MAY_* flags

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Oct 12, 2018 at 10:08:57PM -0600, Andreas Dilger wrote:

> It's not that I'm _so_ worried about the values changing, just
> that I was following the ACL code paths around, and the caller
> is passing in MAY_* flags on the one side, but then comparing
> them to values set from S_I*OTH flags on disk and it made me
> wonder if something was broken, or if it might break in the future.
> 
> I would definitely agree that S_I* flags are set in stone, but
> I've never really thought of MAY_* flags as being directly tied
> to on-disk values because there are so many more than just
> MAY_{READ,WRITE,EXECUTE} - MAY_APPEND, MAY_OPEN, etc.  I'd always
> thought of them like the EXT4_IMMUTABLE_FL on-disk flags vs.
> the S_IMMUTABLE inode flags in memory.

In theory - yes, in practice... imm/append-only are nowhere near
as common and didn't have universal values on-disk (ext* ones are
different from ufs ones, for example).

It might be worth a comment (near the definition of MAY_...,
probably mentioning that MAY_READ/MAY_WRITE/MAY_EXEC are
also equal to R_OK/W_OK/X_OK), but that's about it.



[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux