Print this page
12288 getfacl and setfacl could stand improvement
*** 6,16 ****
.TH ACL_TOTEXT 3SEC "Jun 16, 2008"
.SH NAME
acl_totext, acl_fromtext \- convert internal representation to or from
external representation
.SH SYNOPSIS
- .LP
.nf
cc [ \fIflag\fR\&.\|.\|. ] \fIfile\fR\&.\|.\|. \fB-lsec\fR [ \fIlibrary\fR\&.\|.\|. ]
#include <sys/acl.h>
\fBchar *\fR\fBacl_totext\fR(\fBacl_t *\fR\fIaclp\fR, \fBint\fR \fIflags\fR);
--- 6,15 ----
*** 20,31 ****
.nf
\fBint\fR \fBacl_fromtext\fR(\fBchar *\fR\fIacltextp\fR, \fBacl_t **\fR\fIaclp\fR);
.fi
.SH DESCRIPTION
- .sp
- .LP
The \fBacl_totext()\fR function converts an internal ACL representation pointed
to by \fIaclp\fR into an external ACL representation. The memory for the
external text string is obtained using \fBmalloc\fR(3C). The caller is
responsible for freeing the memory upon completion.
.sp
--- 19,28 ----
*** 48,58 ****
.na
\fB\fBACL_APPEND_ID\fR\fR
.ad
.RS 19n
Append the \fBuid\fR or \fBgid\fR for additional user or group entries. This
! flag is used to construt ACL entries in a manner that is suitable for archive
utilities such as \fBtar\fR(1). When the ACL is translated from the external
format to internal representation using \fBacl_fromtext()\fR, the appended ID
will be used to populate the \fBuid\fR or \fBgid\fR field of the ACL entry when
the user or group name does not exist on the host system. The appended id will
be ignored when the user or group name does exist on the system.
--- 45,55 ----
.na
\fB\fBACL_APPEND_ID\fR\fR
.ad
.RS 19n
Append the \fBuid\fR or \fBgid\fR for additional user or group entries. This
! flag is used to construct ACL entries in a manner that is suitable for archive
utilities such as \fBtar\fR(1). When the ACL is translated from the external
format to internal representation using \fBacl_fromtext()\fR, the appended ID
will be used to populate the \fBuid\fR or \fBgid\fR field of the ACL entry when
the user or group name does not exist on the host system. The appended id will
be ignored when the user or group name does exist on the system.
*** 609,620 ****
.RS 9n
The mask specified in field three should be denied.
.RE
.SH RETURN VALUES
- .sp
- .LP
Upon successful completion, the \fBacl_totext()\fR function returns a pointer
to a text string. Otherwise, it returns \fINULL\fR.
.sp
.LP
Upon successful completion, the \fBacl_fromtext()\fR function returns 0.
--- 606,615 ----
*** 699,709 ****
.RS 28n
Unknown data was found in the ACL.
.RE
.SH EXAMPLES
- .LP
\fBExample 1 \fRExamples of permissions when \fBACL_COMPACT_FMT\fR is not
specified.
.sp
.in +2
.nf
--- 694,703 ----
*** 738,749 ****
.fi
.in -2
.sp
.SH ATTRIBUTES
- .sp
- .LP
See \fBattributes\fR(5) for descriptions of the following attributes:
.sp
.sp
.TS
--- 732,741 ----
*** 756,764 ****
_
MT-Level Safe
.TE
.SH SEE ALSO
- .sp
- .LP
\fBls\fR(1), \fBtar\fR(1), \fBacl\fR(2), \fBmalloc\fR(3C),
\fBaclfromtext\fR(3SEC), \fBacl\fR(5), \fBattributes\fR(5)
--- 748,754 ----