ACE Syntax

Describes how to construct access control expressions (ACEs).

An Access Control Expression (ACE) is defined by a combination of user, group, or role definitions. You can combine these definitions using the following syntax:

Operator Description
u Username or user ID, as they appear in /etc/passwd, of a specific user. Usage: u:<username or user ID>
g Group name or group ID, as they appear in /etc/group, of a specific group. Usage: g:<group name or group ID>
r Name of a specific role. Usage: r:<role name>.
p Public. Specifies that this operation is available to the public without restriction. Cannot be combined with any other operator. API request or CLI command to save such settings will return an error.
! Negation operator. Usage: !<operator>.
& AND operation.
| OR operation
() Delimiters for subexpressions.
"" The empty string indicates that no user has the specified permission.

An example definition is u:1001 | r:engineering, which restricts access to the user with ID 1001 or to any user with the role engineering.

In this next example, members of the group admin are given access, and so are members of the group qa:

g:admin | g:qa

For another example, suppose that you have this list of groups to which you want to give read permissions:

To grant the read permission, you construct this boolean expression:
u:cfkane | (g:admin & !g:cl3) | (g:qa & (g:app2 | g:app3)) | (g:ba & g:dept_7a) | g:ds

This expression is made up of five subexpressions which are separated by OR operators.