diff options
| author | Richard Lowe <richlowe@richlowe.net> | 2011-03-14 14:05:30 -0400 |
|---|---|---|
| committer | Richard Lowe <richlowe@richlowe.net> | 2011-03-14 14:05:30 -0400 |
| commit | c10c16dec587a0662068f6e2991c29ed3a9db943 (patch) | |
| tree | f414286f4bba41d75683ed4fbbaa6bfa4bf7fabd /usr/src/man/man3sec/acltotext.3sec | |
| parent | 68caef18a23a498d9e3017b983562c0f4fd8ab23 (diff) | |
| download | illumos-joyent-c10c16dec587a0662068f6e2991c29ed3a9db943.tar.gz | |
243 system manual pages should live with the software
Reviewed by: garrett@nexenta.com
Reviewed by: gwr@nexenta.com
Reviewed by: trisk@opensolaris.org
Approved by: gwr@nexenta.com
--HG--
extra : rebase_source : 0c599d0bec0dc8865fbba67721a7a6cd6b1feefb
Diffstat (limited to 'usr/src/man/man3sec/acltotext.3sec')
| -rw-r--r-- | usr/src/man/man3sec/acltotext.3sec | 269 |
1 files changed, 269 insertions, 0 deletions
diff --git a/usr/src/man/man3sec/acltotext.3sec b/usr/src/man/man3sec/acltotext.3sec new file mode 100644 index 0000000000..b70a6bcbeb --- /dev/null +++ b/usr/src/man/man3sec/acltotext.3sec @@ -0,0 +1,269 @@ +'\" te +.\" Copyright (c) 2001, Sun Microsystems, Inc. +.\" 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. +.\" 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. +.\" 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] +.TH acltotext 3SEC "10 Dec 2001" "SunOS 5.11" "File Access Control Library Functions" +.SH NAME +acltotext, aclfromtext \- convert internal representation to or from external +representation +.SH SYNOPSIS +.LP +.nf +\fBcc\fR [ \fIflag\fR... ] \fIfile\fR... \fB-lsec\fR [ \fIlibrary\fR... ] +#include <sys/acl.h> + +\fBchar *\fR\fBacltotext\fR(\fBaclent_t *\fR\fIaclbufp\fR, \fBint\fR \fIaclcnt\fR); +.fi + +.LP +.nf +\fBaclent_t *\fR\fBaclfromtext\fR(\fBchar *\fR\fIacltextp\fR, \fBint *\fR\fIaclcnt\fR); +.fi + +.SH DESCRIPTION +.sp +.LP +The \fBacltotext()\fR function converts an internal \fBACL\fR representation +pointed to by \fIaclbufp\fR into an external \fBACL\fR representation. The +space for the external text string is obtained using \fBmalloc\fR(3C). The +caller is responsible for freeing the space upon completion.. +.sp +.LP +The \fBaclfromtext()\fR function converts an external \fBACL\fR representation +pointed to by \fIacltextp\fR into an internal \fBACL\fR representation. The +space for the list of \fBACL\fR entries is obtained using \fBmalloc\fR(3C). The +caller is responsible for freeing the space upon completion. The \fIaclcnt\fR +argument indicates the number of \fBACL\fR entries found. +.sp +.LP +An external \fBACL\fR representation is defined as follows: +.sp +.LP +<acl_entry>[,<acl_entry>]\|.\|.\|. +.sp +.LP +Each <acl_entry> contains one \fBACL\fR entry. The external representation of +an \fBACL\fR entry contains two or three colon-separated fields. The first +field contains the \fBACL\fR entry tag type. The entry type keywords are +defined as: +.sp +.ne 2 +.mk +.na +\fB\fBuser\fR\fR +.ad +.RS 17n +.rt +This \fBACL\fR entry with no \fBUID\fR specified in the \fBACL\fR entry +\fBID\fR field specifies the access granted to the owner of the object. +Otherwise, this \fBACL\fR entry specifies the access granted to a specific +user-name or user-id number. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBgroup\fR\fR +.ad +.RS 17n +.rt +This \fBACL\fR entry with no \fBGID\fR specified in the \fBACL\fR entry +\fBID\fR field specifies the access granted to the owning group of the object. +Otherwise, this \fBACL\fR entry specifies the access granted to a specific +group-name or group-id number. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBother\fR\fR +.ad +.RS 17n +.rt +This \fBACL\fR entry specifies the access granted to any user or group that +does not match any other \fBACL\fR entry. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBmask\fR\fR +.ad +.RS 17n +.rt +This \fBACL\fR entry specifies the maximum access granted to user or group +entries. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBdefault:user\fR\fR +.ad +.RS 17n +.rt +This \fBACL\fR entry with no uid specified in the \fBACL\fR entry \fBID\fR +field specifies the default access granted to the owner of the object. +Otherwise, this \fBACL\fR entry specifies the default access granted to a +specific user-name or user-\fBID\fR number. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBdefault:group\fR\fR +.ad +.RS 17n +.rt +This \fBACL\fR entry with no gid specified in the \fBACL\fR entry \fBID\fR +field specifies the default access granted to the owning group of the object. +Otherwise, this \fBACL\fR entry specifies the default access granted to a +specific group-name or group-\fBID\fR number. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBdefault:other\fR\fR +.ad +.RS 17n +.rt +This \fBACL\fR entry specifies the default access for other entry. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBdefault:mask\fR\fR +.ad +.RS 17n +.rt +This \fBACL\fR entry specifies the default access for mask entry. +.RE + +.sp +.LP +The second field contains the \fBACL\fR entry \fBID\fR, as follows: +.sp +.ne 2 +.mk +.na +\fB\fBuid\fR\fR +.ad +.RS 9n +.rt +This field specifies a user-name, or user-\fBID\fR if there is no user-name +associated with the user-\fBID\fR number. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBgid\fR\fR +.ad +.RS 9n +.rt +This field specifies a group-name, or group-\fBID\fR if there is no group-name +associated with the group-\fBID\fR number. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBempty\fR\fR +.ad +.RS 9n +.rt +This field is used by the user and group \fBACL\fR entry types. +.RE + +.sp +.LP +The third field contains the following symbolic discretionary access +permissions: +.sp +.ne 2 +.mk +.na +\fB\fBr\fR\fR +.ad +.RS 9n +.rt +read permission +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBw\fR\fR +.ad +.RS 9n +.rt +write permission +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBx\fR\fR +.ad +.RS 9n +.rt +execute/search permission +.RE + +.sp +.ne 2 +.mk +.na +\fB\fB\(mi\fR \fR +.ad +.RS 9n +.rt +no access +.RE + +.SH RETURN VALUES +.sp +.LP +Upon successful completion, the \fBacltotext()\fR function returns a pointer to +a text string. Otherwise, it returns \fBNULL\fR. +.sp +.LP +Upon successful completion, the \fBaclfromtext()\fR function returns a pointer +to a list of \fBACL\fR entries. Otherwise, it returns \fBNULL\fR. +.SH ATTRIBUTES +.sp +.LP +See \fBattributes\fR(5) for descriptions of the following attributes: +.sp + +.sp +.TS +tab() box; +cw(2.75i) |cw(2.75i) +lw(2.75i) |lw(2.75i) +. +ATTRIBUTE TYPEATTRIBUTE VALUE +_ +Interface StabilityEvolving +_ +MT-LevelUnsafe +.TE + +.SH SEE ALSO +.sp +.LP +\fBacl\fR(2), \fBmalloc\fR(3C), \fBattributes\fR(5) |
