]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - lib/libc/posix1e/acl_extended_file_np.3
ssh: update to OpenSSH v9.0p1
[FreeBSD/FreeBSD.git] / lib / libc / posix1e / acl_extended_file_np.3
1 .\"-
2 .\" Copyright (c) 2021 Gleb Popov
3 .\" All rights reserved.
4 .\"
5 .\" Redistribution and use in source and binary forms, with or without
6 .\" modification, are permitted provided that the following conditions
7 .\" are met:
8 .\" 1. Redistributions of source code must retain the above copyright
9 .\"    notice, this list of conditions and the following disclaimer.
10 .\" 2. Redistributions in binary form must reproduce the above copyright
11 .\"    notice, this list of conditions and the following disclaimer in the
12 .\"    documentation and/or other materials provided with the distribution.
13 .\"
14 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
15 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
16 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
17 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
18 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 .\" SUCH DAMAGE.
25 .\"
26 .Dd February 26, 2021
27 .Dt ACL_EXTENDED_FILE_NP 3
28 .Os
29 .Sh NAME
30 .Nm acl_extended_file_np ,
31 .Nm acl_extended_file_nofollow_np ,
32 .Nm acl_extended_link_np
33 .Nd checks if the file has extended ACLs set
34 .Sh LIBRARY
35 .Lb libc
36 .Sh SYNOPSIS
37 .In sys/types.h
38 .In sys/acl.h
39 .Ft int
40 .Fn acl_extended_file_np "const char* path_p"
41 .Ft int
42 .Fn acl_extended_file_nofollow_np "const char* path_p"
43 .Ft int
44 .Fn acl_extended_link_np "const char* path_p"
45 .Sh DESCRIPTION
46 The
47 .Fn acl_extended_file_np
48 function is a non-portable call that checks if the file or directory referred to
49 by the argument
50 .Va path_p
51 contains extended access ACLs. The
52 .Fn acl_extended_file_nofollow_np
53 function works the same way, except it does not follow symlinks. The
54 .Fn acl_extended_link_np
55 function is a synonim to
56 .Fn acl_extended_file_nofollow_np
57 named in FreeBSD style.
58 An ACL is considered to be extended access one if it contains entries other
59 than the three required entries of tag types ACL_USER_OBJ, ACL_GROUP_OBJ and
60 ACL_OTHER.
61 .Sh RETURN VALUES
62 Upon successful completion, this function returns 0 if the file object does not
63 contain extended access ACLs and 1 in the other case.
64 Otherwise, the value -1 is returned, and
65 .Va errno
66 indicates the error.
67 .Sh ERRORS
68 If any of the following conditions occur, the
69 .Fn acl_extended_file_np
70 function shall return a value of
71 .Va -1
72 and set
73 .Va errno
74 to the corresponding value:
75 .Bl -tag -width Er
76 .It Bq Er EACCES
77 Search permission is denied for a component of the path prefix.
78 .Sh SEE ALSO
79 .Xr extattr_get_file 2 ,
80 .Xr posix1e 3
81 .Sh STANDARDS
82 POSIX.1e is described in IEEE POSIX.1e draft 17.
83 Discussion
84 of the draft continues on the cross-platform POSIX.1e implementation
85 mailing list.
86 To join this list, see the
87 .Fx
88 POSIX.1e implementation
89 page for more information.
90 .Sh HISTORY
91 POSIX.1e support was introduced in
92 .Fx 4.0 ,
93 and development continues.
94 .Sh AUTHORS
95 .An Gleb Popov