Open System Services Shell and Utilities Reference Manual (G06.29+, H06.08+, J06.03+)
getacl(1) OSS Shell and Utilities Reference Manual
NAME
getacl - Lists access control lists (ACLs) for files
SYNOPSIS
getacl [ -ad ] file ...
FLAGS
-a Displays the filename, owner, group, and any nondefault ACL entries for the file.
-d Displays the filename, owner, group, and any default ACL entries for the file. Only
directories have default ACL entries.
If you do not specify any flags, the filename, owner, group, and both default and nondefault ACL
entries are displayed.
DESCRIPTION
The getacl command displays the owner, group, and ACL entries for each file that is a directory,
a regular file, a first-in, first-out (FIFO) special file, or a bound AF_UNIX socket.
When you specify multiple files, a blank line separates the ACL listing for each file. The format
of a single ACL is:
# file: filename
# owner: uid
# group: gid
user::perm
user:uid:perm
group::perm
group:gid:perm
class:perm
other:perm
default:user::perm
default:user:uid:perm
default:group::perm
default:group:gid:perm
default:class:perm
default:other:perm
The first three lines show the filename, the file owner, and the file-owning group. When you
specify only the -d flag, and the file has no default ACL, only these three lines are displayed.
Only directories have default ACL entries.
The user entry without a user ID indicates the permissions that are granted to the owner of the
file. One or more additional user entries indicate the permissions that are granted to the specified
users. The group entry without a group identifier indicates the permissions that are granted to
the owning group of the file. One or more additional group entries indicate the permissions that
are granted to the specified groups. The other entry indicates the permissions that are granted to
others. The class entry provides a mask that you can use to restrict the permissions granted by
additional user entries and any group entries.
The default entries (default:user, default:group, and default:other) can exist for directories
only and contain ACL entries that are added to files and directories created within the directory.
Default entries are added to new files as actual entries. Default entries are added to new direc-
tories both as actual entries and default entries.
The uid is the login name, gid is a group name, and perm is a three-character string of letters
representing the separate discretionary access rights: r (read), w (write), x (execute/search), or
the placeholder character - (dash). The value of perm is displayed in the order rwx.
If a permis-
sion is not granted by an ACL entry, the placeholder character appears.
4−10 Hewlett-Packard Company 527188-021