xref: /freebsd/lib/libc/posix1e/acl_get_perm_np.3 (revision 6061acb30c4dc248b5c245c56766b937b8f16809)
19a227c57SChris D. Faulhaber.\"-
29a227c57SChris D. Faulhaber.\" Copyright (c) 2001 Chris D. Faulhaber
39a227c57SChris D. Faulhaber.\" All rights reserved.
49a227c57SChris D. Faulhaber.\"
59a227c57SChris D. Faulhaber.\" Redistribution and use in source and binary forms, with or without
69a227c57SChris D. Faulhaber.\" modification, are permitted provided that the following conditions
79a227c57SChris D. Faulhaber.\" are met:
89a227c57SChris D. Faulhaber.\" 1. Redistributions of source code must retain the above copyright
99a227c57SChris D. Faulhaber.\"    notice, this list of conditions and the following disclaimer.
109a227c57SChris D. Faulhaber.\" 2. Redistributions in binary form must reproduce the above copyright
119a227c57SChris D. Faulhaber.\"    notice, this list of conditions and the following disclaimer in the
129a227c57SChris D. Faulhaber.\"    documentation and/or other materials provided with the distribution.
139a227c57SChris D. Faulhaber.\"
149a227c57SChris D. Faulhaber.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
159a227c57SChris D. Faulhaber.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
169a227c57SChris D. Faulhaber.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
179a227c57SChris D. Faulhaber.\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR THE VOICES IN HIS HEAD BE
189a227c57SChris D. Faulhaber.\" LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
199a227c57SChris D. Faulhaber.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
209a227c57SChris D. Faulhaber.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
219a227c57SChris D. Faulhaber.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
229a227c57SChris D. Faulhaber.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
239a227c57SChris D. Faulhaber.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
249a227c57SChris D. Faulhaber.\" POSSIBILITY OF SUCH DAMAGE.
259a227c57SChris D. Faulhaber.\"
269a227c57SChris D. Faulhaber.\" $FreeBSD$
279a227c57SChris D. Faulhaber.\"
289a227c57SChris D. Faulhaber.Dd April 10, 2001
299a227c57SChris D. Faulhaber.Dt ACL_GET_PERM_NP 3
309a227c57SChris D. Faulhaber.Os
319a227c57SChris D. Faulhaber.Sh NAME
329a227c57SChris D. Faulhaber.Nm acl_get_perm_np
336061acb3SRuslan Ermilov.Nd "check if a permission is set in a permission set"
349a227c57SChris D. Faulhaber.Sh LIBRARY
359a227c57SChris D. Faulhaber.Lb libc
369a227c57SChris D. Faulhaber.Sh SYNOPSIS
379a227c57SChris D. Faulhaber.Fd #include <sys/types.h>
389a227c57SChris D. Faulhaber.Fd #include <sys/acl.h>
399a227c57SChris D. Faulhaber.Ft int
409a227c57SChris D. Faulhaber.Fn acl_get_perm_np "acl_permset_t permset_d" "acl_perm_t perm"
419a227c57SChris D. Faulhaber.Sh DESCRIPTION
429a227c57SChris D. Faulhaber.Fn acl_get_perm_np
439a227c57SChris D. Faulhaberis a non-portable function that checks if a permission is set in
449a227c57SChris D. Faulhabera permission set.
459a227c57SChris D. Faulhaber.Sh RETURN VALUES
469a227c57SChris D. FaulhaberIf the permission in
479a227c57SChris D. Faulhaber.Fa perm
489a227c57SChris D. Faulhaberis set in the permission set
499a227c57SChris D. Faulhaber.Fa permset_d ,
509a227c57SChris D. Faulhabera value of
516061acb3SRuslan Ermilov1
529a227c57SChris D. Faulhaberis returned, otherwise a value of
536061acb3SRuslan Ermilov0
549a227c57SChris D. Faulhaberis returned.
559a227c57SChris D. Faulhaber.Sh ERRORS
569a227c57SChris D. FaulhaberIf any of the following conditions occur, the
579a227c57SChris D. Faulhaber.Fn acl_get_perm_np
589a227c57SChris D. Faulhaberfunction will return a value of
596061acb3SRuslan Ermilov\-1
606061acb3SRuslan Ermilovand set global variable
619a227c57SChris D. Faulhaber.Va errno
629a227c57SChris D. Faulhaberto the corresponding value:
639a227c57SChris D. Faulhaber.Bl -tag -width Er
649a227c57SChris D. Faulhaber.It Bq Er EINVAL
659a227c57SChris D. FaulhaberArgument
669a227c57SChris D. Faulhaber.Fa perm
679a227c57SChris D. Faulhaberdoes not contain a valid ACL permission or argument
689a227c57SChris D. Faulhaber.Fa permset_d
699a227c57SChris D. Faulhaberis not a valid ACL permset.
709a227c57SChris D. Faulhaber.El
719a227c57SChris D. Faulhaber.Sh SEE ALSO
729a227c57SChris D. Faulhaber.Xr acl 3 ,
739a227c57SChris D. Faulhaber.Xr acl_add_perm 3 ,
749a227c57SChris D. Faulhaber.Xr acl_clear_perms 3 ,
759a227c57SChris D. Faulhaber.Xr acl_delete_perm 3 ,
769a227c57SChris D. Faulhaber.Xr acl_get_permset 3 ,
779a227c57SChris D. Faulhaber.Xr acl_set_permset 3 ,
789a227c57SChris D. Faulhaber.Xr posix1e 3
799a227c57SChris D. Faulhaber.Sh STANDARDS
809a227c57SChris D. FaulhaberPOSIX.1e is described in IEEE POSIX.1e draft 17.
819a227c57SChris D. Faulhaber.Sh HISTORY
829a227c57SChris D. FaulhaberPOSIX.1e support was introduced in
839a227c57SChris D. Faulhaber.Fx 4.0 .
849a227c57SChris D. FaulhaberThe
859a227c57SChris D. Faulhaber.Fn acl_get_perm_np
869a227c57SChris D. Faulhaberfunction was added in
879a227c57SChris D. Faulhaber.Fx 5.0 .
889a227c57SChris D. Faulhaber.Sh AUTHORS
899a227c57SChris D. FaulhaberThe
909a227c57SChris D. Faulhaber.Fn acl_get_perm_np
919a227c57SChris D. Faulhaberfunction was written by
929a227c57SChris D. Faulhaber.An Chris D. Faulhaber Aq jedgar@fxp.org .
93