2 .\" Copyright (c) 2001, Sun Microsystems, Inc.
3 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License.
4 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License.
5 .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
6 .TH ACLTOTEXT 3SEC "Dec 10, 2001"
8 acltotext, aclfromtext \- convert internal representation to or from external
13 \fBcc\fR [ \fIflag\fR... ] \fIfile\fR... \fB-lsec\fR [ \fIlibrary\fR... ]
16 \fBchar *\fR\fBacltotext\fR(\fBaclent_t *\fR\fIaclbufp\fR, \fBint\fR \fIaclcnt\fR);
21 \fBaclent_t *\fR\fBaclfromtext\fR(\fBchar *\fR\fIacltextp\fR, \fBint *\fR\fIaclcnt\fR);
27 The \fBacltotext()\fR function converts an internal \fBACL\fR representation
28 pointed to by \fIaclbufp\fR into an external \fBACL\fR representation. The
29 space for the external text string is obtained using \fBmalloc\fR(3C). The
30 caller is responsible for freeing the space upon completion..
33 The \fBaclfromtext()\fR function converts an external \fBACL\fR representation
34 pointed to by \fIacltextp\fR into an internal \fBACL\fR representation. The
35 space for the list of \fBACL\fR entries is obtained using \fBmalloc\fR(3C). The
36 caller is responsible for freeing the space upon completion. The \fIaclcnt\fR
37 argument indicates the number of \fBACL\fR entries found.
40 An external \fBACL\fR representation is defined as follows:
43 <acl_entry>[,<acl_entry>]\|.\|.\|.
46 Each <acl_entry> contains one \fBACL\fR entry. The external representation of
47 an \fBACL\fR entry contains two or three colon-separated fields. The first
48 field contains the \fBACL\fR entry tag type. The entry type keywords are
56 This \fBACL\fR entry with no \fBUID\fR specified in the \fBACL\fR entry
57 \fBID\fR field specifies the access granted to the owner of the object.
58 Otherwise, this \fBACL\fR entry specifies the access granted to a specific
59 user-name or user-id number.
68 This \fBACL\fR entry with no \fBGID\fR specified in the \fBACL\fR entry
69 \fBID\fR field specifies the access granted to the owning group of the object.
70 Otherwise, this \fBACL\fR entry specifies the access granted to a specific
71 group-name or group-id number.
80 This \fBACL\fR entry specifies the access granted to any user or group that
81 does not match any other \fBACL\fR entry.
90 This \fBACL\fR entry specifies the maximum access granted to user or group
97 \fB\fBdefault:user\fR\fR
100 This \fBACL\fR entry with no uid specified in the \fBACL\fR entry \fBID\fR
101 field specifies the default access granted to the owner of the object.
102 Otherwise, this \fBACL\fR entry specifies the default access granted to a
103 specific user-name or user-\fBID\fR number.
109 \fB\fBdefault:group\fR\fR
112 This \fBACL\fR entry with no gid specified in the \fBACL\fR entry \fBID\fR
113 field specifies the default access granted to the owning group of the object.
114 Otherwise, this \fBACL\fR entry specifies the default access granted to a
115 specific group-name or group-\fBID\fR number.
121 \fB\fBdefault:other\fR\fR
124 This \fBACL\fR entry specifies the default access for other entry.
130 \fB\fBdefault:mask\fR\fR
133 This \fBACL\fR entry specifies the default access for mask entry.
138 The second field contains the \fBACL\fR entry \fBID\fR, as follows:
145 This field specifies a user-name, or user-\fBID\fR if there is no user-name
146 associated with the user-\fBID\fR number.
155 This field specifies a group-name, or group-\fBID\fR if there is no group-name
156 associated with the group-\fBID\fR number.
165 This field is used by the user and group \fBACL\fR entry types.
170 The third field contains the following symbolic discretionary access
196 execute/search permission
211 Upon successful completion, the \fBacltotext()\fR function returns a pointer to
212 a text string. Otherwise, it returns \fBNULL\fR.
215 Upon successful completion, the \fBaclfromtext()\fR function returns a pointer
216 to a list of \fBACL\fR entries. Otherwise, it returns \fBNULL\fR.
220 See \fBattributes\fR(5) for descriptions of the following attributes:
228 ATTRIBUTE TYPE ATTRIBUTE VALUE
230 Interface Stability Evolving
238 \fBacl\fR(2), \fBmalloc\fR(3C), \fBattributes\fR(5)