2 Usage: getfacl [-adn] FILE [FILE2...]
3 Display file and directory access control lists (ACLs).
5 -a, --all display the filename, the owner, the group, and
7 -d, --dir display the filename, the owner, the group, and
8 the default ACL of the directory, if it exists
9 -h, --help output usage information and exit
10 -n, --noname display user and group IDs instead of names
11 -v, --version output version information and exit
13 When multiple files are specified on the command line, a blank
14 line separates the ACLs for each file.
15 For each argument that is a regular file, special file or
16 directory, getfacl displays the owner, the group, and the ACL.
17 For directories getfacl displays additionally the default ACL.
19 With no options specified, getfacl displays the filename, the
20 owner, the group, and both the ACL and the default ACL, if it
23 The format for ACL output is as follows:
30 group:name or gid:perm
34 default:user:name or uid:perm
36 default:group:name or gid:perm
43 Usage: setfacl [-r] (-f ACL_FILE | -s acl_entries) FILE...
44 setfacl [-r] ([-d acl_entries] [-m acl_entries]) FILE...
45 Modify file and directory access control lists (ACLs)
47 -d, --delete delete one or more specified ACL entries
48 -f, --file set ACL entries for FILE to ACL entries read
50 -m, --modify modify one or more specified ACL entries
51 -r, --replace replace mask entry with maximum permissions
52 needed for the file group class
53 -s, --substitute substitute specified ACL entries for the
55 -h, --help output usage information and exit
56 -v, --version output version information and exit
58 At least one of (-d, -f, -m, -s) must be specified
60 Acl_entries are one or more comma-separated ACL entries
61 from the following list:
70 Default entries are like the above with the additional
71 default identifier. For example:
73 d[efault]:u[ser]:uid:perm
75 'perm' is either a 3-char permissions string in the form
76 "rwx" with the character - for no permission
77 or it is the octal representation of the permissions, a
78 value from 0 (equivalent to "---") to 7 ("rwx").
79 'uid' is a user name or a numerical uid.
80 'gid' is a group name or a numerical gid.
83 For each file given as parameter, setfacl will either replace its
84 complete ACL (-s, -f), or it will add, modify, or delete ACL
87 The following options are supported:
89 -d Delete one or more specified entries from the file's ACL.
90 The owner, group and others entries must not be deleted.
91 Acl_entries to be deleted should be specified without
92 permissions, as in the following list:
101 -f Take the Acl_entries from ACL_FILE one per line. Whitespace
102 characters are ignored, and the character "#" may be used
103 to start a comment. The special filename "-" indicates
106 - One user entry for the owner of the file.
107 - One group entry for the group of the file.
109 If additional user and group entries are given:
110 - A mask entry for the file group class of the file.
111 - No duplicate user or group entries with the same uid/gid.
112 If it is a directory:
113 - One default user entry for the owner of the file.
114 - One default group entry for the group of the file.
115 - One default mask entry for the file group class.
116 - One default other entry.
118 -m Add or modify one or more specified ACL entries.
119 Acl_entries is a comma-separated list of entries from the
122 -r Causes the permissions specified in the mask entry to be
123 ignored and replaced by the maximum permissions needed for
124 the file group class.
126 -s Like -f, but substitute the file's ACL with Acl_entries
127 specified in a comma-separated list on the command line.
129 While the -d and -m options may be used in the same command, the
130 -f and -s options may be used only exclusively.
132 Directories may contain default ACL entries. Files created
133 in a directory that contains default ACL entries will have
134 permissions according to the combination of the current umask,
135 the explicit permissions requested and the default ACL entries
136 Note: Under Cygwin, the default ACL entries are not taken into