summaryrefslogtreecommitdiff
path: root/Utilities/cmlibarchive/libarchive/archive_entry_acl.3
diff options
context:
space:
mode:
authorDongHun Kwak <dh0128.kwak@samsung.com>2021-10-08 09:20:10 +0900
committerDongHun Kwak <dh0128.kwak@samsung.com>2021-10-08 09:20:10 +0900
commitf58f7a233a9b66287e1a0fad0d149e3202a098b4 (patch)
treecc0cea82fae3f153df9299b27650e17c58da1125 /Utilities/cmlibarchive/libarchive/archive_entry_acl.3
parent46f8b5215bbbfcf4bc0caed1daf52b678fd2b976 (diff)
downloadcmake-f58f7a233a9b66287e1a0fad0d149e3202a098b4.tar.gz
cmake-f58f7a233a9b66287e1a0fad0d149e3202a098b4.tar.bz2
cmake-f58f7a233a9b66287e1a0fad0d149e3202a098b4.zip
Imported Upstream version 3.18.0upstream/3.18.0
Diffstat (limited to 'Utilities/cmlibarchive/libarchive/archive_entry_acl.3')
-rw-r--r--Utilities/cmlibarchive/libarchive/archive_entry_acl.380
1 files changed, 36 insertions, 44 deletions
diff --git a/Utilities/cmlibarchive/libarchive/archive_entry_acl.3 b/Utilities/cmlibarchive/libarchive/archive_entry_acl.3
index 534dbfac6..50dd642c2 100644
--- a/Utilities/cmlibarchive/libarchive/archive_entry_acl.3
+++ b/Utilities/cmlibarchive/libarchive/archive_entry_acl.3
@@ -34,7 +34,6 @@
.Nm archive_entry_acl_from_text ,
.Nm archive_entry_acl_from_text_w ,
.Nm archive_entry_acl_next ,
-.Nm archive_entry_acl_next_w ,
.Nm archive_entry_acl_reset ,
.Nm archive_entry_acl_to_text ,
.Nm archive_entry_acl_to_text_w ,
@@ -89,16 +88,6 @@ Streaming Archive Library (libarchive, -larchive)
.Fa "const char **ret_name"
.Fc
.Ft int
-.Fo archive_entry_acl_next_w
-.Fa "struct archive_entry *a"
-.Fa "int type"
-.Fa "int *ret_type"
-.Fa "int *ret_permset"
-.Fa "int *ret_tag"
-.Fa "int *ret_qual"
-.Fa "const wchar_t **ret_name"
-.Fc
-.Ft int
.Fn archive_entry_acl_reset "struct archive_entry *a" "int type"
.Ft char *
.Fo archive_entry_acl_to_text
@@ -118,15 +107,16 @@ Streaming Archive Library (libarchive, -larchive)
.Sh DESCRIPTION
The
.Dq Access Control Lists (ACLs)
-extend the standard Unix perssion model.
+extend the standard Unix permission model.
The ACL interface of
.Nm libarchive
-supports both POSIX.1e and NFSv4 style ACLs. Use of ACLs is restricted by
+supports both POSIX.1e and NFSv4 style ACLs.
+Use of ACLs is restricted by
various levels of ACL support in operating systems, file systems and archive
formats.
.Ss POSIX.1e Access Control Lists
A POSIX.1e ACL consists of a number of independent entries.
-Each entry specifies the permission set as bitmask of basic permissions.
+Each entry specifies the permission set as a bitmask of basic permissions.
Valid permissions in the
.Fa permset
are:
@@ -147,13 +137,13 @@ The user specified by the name field.
.It Dv ARCHIVE_ENTRY_ACL_USER_OBJ
The owner of the file.
.It Dv ARCHIVE_ENTRY_ACL_GROUP
-The group specied by the name field.
+The group specified by the name field.
.It Dv ARCHIVE_ENTRY_ACL_GROUP_OBJ
-The group who owns the file.
+The group which owns the file.
.It Dv ARCHIVE_ENTRY_ACL_MASK
The maximum permissions to be obtained via group permissions.
.It Dv ARCHIVE_ENTRY_ACL_OTHER
-Any principal who is not file owner or a member of the owning group.
+Any principal who is not the file owner or a member of the owning group.
.El
.Pp
The principals
@@ -164,12 +154,12 @@ and
are equivalent to user, group and other in the classic Unix permission
model and specify non-extended ACL entries.
.Pp
-All files with have an access ACL
+All files have an access ACL
.Pq Dv ARCHIVE_ENTRY_ACL_TYPE_ACCESS .
This specifies the permissions required for access to the file itself.
Directories have an additional ACL
.Pq Dv ARCHIVE_ENTRY_ACL_TYPE_DEFAULT ,
-which controls the initial access ACL for newly created directory entries.
+which controls the initial access ACL for newly-created directory entries.
.Ss NFSv4 Access Control Lists
A NFSv4 ACL consists of multiple individual entries called Access Control
Entries (ACEs).
@@ -197,11 +187,11 @@ The user specified by the name field.
.It Dv ARCHIVE_ENTRY_ACL_USER_OBJ
The owner of the file.
.It Dv ARCHIVE_ENTRY_ACL_GROUP
-The group specied by the name field.
+The group specified by the name field.
.It Dv ARCHIVE_ENTRY_ACL_GROUP_OBJ
-The group who owns the file.
+The group which owns the file.
.It Dv ARCHIVE_ENTRY_ACL_EVERYONE
-Any principal who is not file owner or a member of the owning group.
+Any principal who is not the file owner or a member of the owning group.
.El
.Pp
Entries with the
@@ -216,9 +206,10 @@ integer.
.Pp
NFSv4 ACE permissions and flags are stored in the same
.Fa permset
-bitfield. Some permissions share the same constant and permission character but
-have different effect on directories than on files. The following ACE
-permissions are supported:
+bitfield.
+Some permissions share the same constant and permission character
+but have different effect on directories than on files.
+The following ACE permissions are supported:
.Bl -tag -offset indent -compact -width ARCHIV
.It Dv ARCHIVE_ENTRY_ACL_READ_DATA ( Sy r )
Read data (file).
@@ -265,7 +256,8 @@ Inherit parent directory ACE to subdirectories.
.It Dv ARCHIVE_ENTRY_ACL_ENTRY_INHERIT_ONLY ( Sy i )
Only inherit, do not apply the permission on the directory itself.
.It Dv ARCHIVE_ENTRY_ACL_ENTRY_NO_PROPAGATE_INHERIT ( Sy n )
-Do not propagate inherit flags. Only first-level entries inherit ACLs.
+Do not propagate inherit flags.
+Only first-level entries inherit ACLs.
.It Dv ARCHIVE_ENTRY_ACL_ENTRY_SUCCESSFUL_ACCESS ( Sy S )
Trigger alarm or audit on successful access.
.It Dv ARCHIVE_ENTRY_ACL_ENTRY_FAILED_ACCESS ( Sy F )
@@ -279,8 +271,8 @@ and
.Fn archive_entry_acl_add_entry_w
add a single ACL entry.
For the access ACL and non-extended principals, the classic Unix permissions
-are updated. An archive entry cannot contain both POSIX.1e and NFSv4 ACL
-entries.
+are updated.
+An archive entry cannot contain both POSIX.1e and NFSv4 ACL entries.
.Pp
.Fn archive_entry_acl_clear
removes all ACL entries and resets the enumeration pointer.
@@ -300,7 +292,8 @@ for POSIX.1e ACLs and
.It Dv ARCHIVE_ENTRY_ACL_TYPE_AUDIT
.It Dv ARCHIVE_ENTRY_ACL_TYPE_ALARM
.El
-for NFSv4 ACLs. For POSIX.1e ACLs if
+for NFSv4 ACLs.
+For POSIX.1e ACLs if
.Dv ARCHIVE_ENTRY_ACL_TYPE_ACCESS
is included and at least one extended ACL entry is found,
the three non-extended ACLs are added.
@@ -312,7 +305,8 @@ add new
.Pq or merge with existing
ACL entries from
.Pq wide
-text. The argument
+text.
+The argument
.Fa type
may take one of the following values:
.Bl -tag -offset indent -compact -width "ARCHIVE_ENTRY_ACL_TYPE_DEFAULT"
@@ -322,11 +316,13 @@ may take one of the following values:
.El
Supports all formats that can be created with
.Fn archive_entry_acl_to_text
-or respective
+or respectively
.Fn archive_entry_acl_to_text_w .
-Existing ACL entries are preserved. To get a clean new ACL from text
+Existing ACL entries are preserved.
+To get a clean new ACL from text
.Fn archive_entry_acl_clear
-must be called first. Entries prefixed with
+must be called first.
+Entries prefixed with
.Dq default:
are treated as
.Dv ARCHIVE_ENTRY_ACL_TYPE_DEFAULT
@@ -342,8 +338,6 @@ character
are skipped.
.Pp
.Fn archive_entry_acl_next
-and
-.Fn archive_entry_acl_next_w
return the next entry of the ACL list.
This functions may only be called after
.Fn archive_entry_acl_reset
@@ -351,10 +345,8 @@ has indicated the presence of extended ACL entries.
.Pp
.Fn archive_entry_acl_reset
prepare reading the list of ACL entries with
-.Fn archive_entry_acl_next
-or
-.Fn archive_entry_acl_next_w .
-The function returns either 0, if no non-extended ACLs are found.
+.Fn archive_entry_acl_next .
+The function returns 0 if no non-extended ACLs are found.
In this case, the access permissions should be obtained by
.Xr archive_entry_mode 3
or set using
@@ -367,7 +359,8 @@ and
.Fn archive_entry_acl_to_text_w
convert the ACL entries for the given type into a
.Pq wide
-string of ACL entries separated by newline. If the pointer
+string of ACL entries separated by newline.
+If the pointer
.Fa len_p
is not NULL, then the function shall return the length of the string
.Pq not including the NULL terminator
@@ -415,7 +408,8 @@ are prefixed with
.Dq default: .
.Pp
.Fn archive_entry_acl_types
-get ACL entry types contained in an archive entry's ACL. As POSIX.1e and NFSv4
+get ACL entry types contained in an archive entry's ACL.
+As POSIX.1e and NFSv4
ACL entries cannot be mixed, this function is a very efficient way to detect if
an ACL already contains POSIX.1e or NFSv4 ACL entries.
.Sh RETURN VALUES
@@ -438,9 +432,7 @@ if all entries were successfully parsed and
if one or more entries were invalid or non-parseable.
.Pp
.Fn archive_entry_acl_next
-and
-.Fn archive_entry_acl_next_w
-return
+returns
.Dv ARCHIVE_OK
on success,
.Dv ARCHIVE_EOF