ACL questions

Eric Blake
Fri Jan 28 13:54:00 GMT 2005

Hash: SHA1

Several places in the coreutils testsuite died because new directories in
cygwin have 7 ACL designations (user, group, other, mask, default user,
default group, default other) instead of MIN_ACL_ENTRIES (4, for user,
group, other, and mask), so their `ls -ld' listing gives a mode of
drwxrwxrwx+ (that extra + denotes extra ACLs).  It looks like the cygwin
default entries for each directory mirror the user, group, and other values.
$ mkdir dir
$ getfacl dir
# file: dir
# owner: eblake
# group: None

My limited testing on Solaris 8, which also supports ACLs, only added
default entries to directories when I specifically set ACLs, and not when
I created a directory, so `ls -ld' never displayed the '+' in the mode
string until I played with the ACLs. See also the example on

POSIX XBD 4.4 File Permissions permits ACLs, but states that ACLs must
either be additional (more restrictive, never less) or alternate (in which
case they can be enabled only on a per-file request, and that they are
disabled when permission is changed with chmod()).  My understanding is
that ACLs are alternate, since I can grant more access to a particular
user or group than the one that actually owns the file.  And if that is
the case, I think that `ls -ld' should never list the '+' at the end of
the mode string for alternate access unless I used an facl() command on
that file or directory.

Could this be a bug in cygwin/'s getacl() for creating directory
default ACLs that are no different from the owner's permissions when
parsing the Windows permissions?  Or is it really valid behavior that all
cygwin directories start life with default ACL entries, in which case
either the coreutils testsuite needs to account for the '+' in the mode
(or else patch `ls' to treat 7 ACL entries on directories, with the 3
default entries matching the corresponding directory owner permissions, as
normal and not extended access)?

- --
Life is short - so eat dessert first!

Eric Blake   
Version: GnuPG v1.4.0 (Cygwin)
Comment: Using GnuPG with Thunderbird -


Unsubscribe info:
Problem reports:

More information about the Cygwin mailing list