GETFACL(1)
๐ GETFACL ๐
okay so bestie, welcome to the getfacl page from the Access Control Lists manual, section 1 ๐ she's the one who reads your file ACLs โ get it, get-facl โ and she's about to spill every single permission tea ๐ซโจ
โจ NAME โจ
getfacl โ get file access control lists ๐ฆ
๐ธ SYNOPSIS ๐ธ
getfacl [-aceEsRLPtpndvh] file ...
getfacl [-aceEsRLPtpndvh] -
๐ DESCRIPTION ๐
For each file, getfacl displays the file name, owner, the group, and the Access Control List (ACL). If a directory has a default ACL, getfacl also displays the default ACL. Non-directories cannot have default ACLs โ not a thing, never was ๐
If getfacl is used on a file system that does not support ACLs, getfacl displays the access permissions defined by the traditional file mode permission bits. Like, she'll still show up for you, she'll just have less to say ๐ฅฒ
The output format of getfacl is as follows:
1: # file: somedir/
2: # owner: lisa
3: # group: staff
4: # flags: -s-
5: user::rwx
6: user:joe:rwx #effective:r-x
7: group::rwx #effective:r-x
8: group:cool:r-x
9: mask::r-x
10: other::r-x
11: default:user::rwx
12: default:user:joe:rwx #effective:r-x
13: default:group::r-x
14: default:mask::r-x
15: default:other::---
Lines 1--3 indicate the file name, owner, and owning group. the holy trinity of who even is this file ๐
Line 4 indicates the setuid (s), setgid (s), and sticky (t) bits: either the letter representing the bit, or else a dash (-). This line is included if any of those bits is set and left out otherwise, so it will not be shown for most files โ literally most files are just out here being unbothered, no special bits, no drama. (See CONFORMANCE TO POSIX 1003.1e DRAFT STANDARD 17 below.)
Lines 5, 7 and 10 correspond to the user, group and other fields of the file mode permission bits. These three are called the base ACL entries. Lines 6 and 8 are named user and named group entries. Line 9 is the effective rights mask. This entry limits the effective rights granted to all groups and to named users. (The file owner and others permissions are not affected by the effective rights mask; all other entries are.) Lines 11--15 display the default ACL associated with this directory. Directories may have a default ACL. Regular files never have a default ACL. periodt ๐
The default behavior for getfacl is to display both the ACL and the default ACL, and to include an effective rights comment for lines where the rights of the entry differ from the effective rights.
If output is to a terminal, the effective rights comment is aligned to column 40. Otherwise, a single tab character separates the ACL entry and the effective rights comment. aesthetic alignment when you're watching, tabs when you're piping โจ
The ACL listings of multiple files are separated by blank lines. The output of getfacl can also be used as input to setfacl. it's giving round-trip, it's giving full-circle moment ๐
๐ PERMISSIONS ๐
Process with search access to a file (i.e., processes with read access to the containing directory of a file) are also granted read access to the file's ACLs. This is analogous to the permissions required for accessing the file mode. no cap, that's just how it works ๐ซถ
๐ OPTIONS ๐
-a,--accessโ Display the file access control list. the classic, the moment, the main character โจ-d,--defaultโ Display the default access control list. ๐ฆ-c,--omit-headerโ Do not display the comment header (the first three lines of each file's output). shy girl behavior, keep the comments to yourself ๐-e,--all-effectiveโ Print all effective rights comments, even if identical to the rights defined by the ACL entry. she's thorough, she's thorough ๐-E,--no-effectiveโ Do not print effective rights comments. โ๏ธ-s,--skip-baseโ Skip files that only have the base ACL entries (owner, group, others). if you're basic you're getting skipped bestie ๐ญ-R,--recursiveโ List the ACLs of all files and directories recursively. down the whole tree, every branch, obsessed ๐-L,--logicalโ Logical walk, follow symbolic links. The default behavior is to follow symbolic links given on the command line, and skip symbolic links encountered in subdirectories. ๐-P,--physicalโ Physical walk, do not follow symbolic links. Symbolic links given on the command line are rejected. (For pathnames given on the command line, this option applies only to the final component; preceding path components may still be symbolic links.) ๐ซ-t,--tabularโ Use an alternative tabular output format. The ACL and the default ACL are displayed side by side. Permissions that are ineffective due to the ACL mask entry are displayed capitalized. The entry tag names for theACL_USER_OBJandACL_GROUP_OBJentries are also displayed in capital letters, which helps in spotting those entries. side by side comparison, we love a good visual ๐-p,--absolute-namesโ Do not strip leading slash characters (/). The default behavior is to strip leading slash characters. ๐-n,--numericโ List numeric user and group IDs. digits only, no names, no fluff ๐ข-v,--versionโ Print the version ofgetfacland exit. โญ-h,--helpโ Print help explaining the command line options. ๐ซถ--โ End of command line options. All remaining parameters are interpreted as file names, even if they start with a dash character. protects the files with dash-names, iconic of her honestly ๐ก๏ธ-โ If the file name parameter is a single dash character,getfaclreads a list of files from standard input. ๐ฅ
๐ CONFORMANCE TO POSIX 1003.1e DRAFT STANDARD 17 ๐
If the environment variable POSIXLY_CORRECT is defined, the default behavior of getfacl changes in the following ways: Unless otherwise specified, only the ACL is printed. The default ACL is only printed if the -d option is given. If no command line parameter is given, getfacl behaves as if it was invoked as `getfacl -`. No flags comments indicating the setuid, setgid, and sticky bits are generated. so if you've got POSIXLY_CORRECT set, expect a whole different vibe check fr fr ๐
๐ AUTHOR ๐
Andreas Gruenbacher, <andreas.gruenbacher@gmail.com>.
Please send your bug reports and comments to the above address. she reads her inbox, be nice ๐
๐ SEE ALSO ๐
setfacl(1), acl(5)
and that's the whole page bestie, no crumbs left ๐โจ this was the May 2000 edition of the ACL File Utilities manual โ yes, she's been that girl since Y2K and she's still serving ๐๐๐ฆ
๐ฆ where this page comes from
- arch rolling: acl 2.4.0-1 ยท LGPL-2.1-or-later AND GPL-2.0-or-later
- centos-stream 10: acl 2.4.0-2.el10 ยท GPL-2.0-or-later AND LGPL-2.1-or-later
- centos-stream 9: acl 2.4.0-2.el9 ยท GPLv2+
- fedora 43: acl 2.4.0-1.fc43 ยท GPL-2.0-or-later AND LGPL-2.1-or-later
- fedora 44: acl 2.4.0-1.fc44 ยท GPL-2.0-or-later AND LGPL-2.1-or-later
- nixpkgs unstable: acl 2.4.0
- opensuse-leap 16.0: acl 2.4.0-160000.1.1 ยท GPL-2.0-or-later AND LGPL-2.1-or-later
- opensuse-leap 16.0: acl 2.4.0-160000.1.1 ยท GPL-2.0-or-later AND LGPL-2.1-or-later
- opensuse-leap 16.0: acl 2.4.0-160000.1.1 ยท GPL-2.0-or-later AND LGPL-2.1-or-later
- opensuse-leap 16.0: acl 2.4.0-160000.1.1 ยท GPL-2.0-or-later AND LGPL-2.1-or-later
- ubuntu stonking: acl 2.4.0-1
- (C) 2000 Andreas Gruenbacher, <andreas.gruenbacher@gmail.com>
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms