|
NAMEmac_prepare , mac_prepare_type ,
mac_prepare_file_label ,
mac_prepare_ifnet_label ,
mac_prepare_process_label —
allocate appropriate storage for
mac_t
SYNOPSIS#include <sys/mac.h>
int
int
int
int
int
DESCRIPTIONThemac_prepare family of functions allocates the
appropriate amount of storage and initializes *mac for
use by
mac_get(3).
When the resulting label is passed into the
mac_get(3)
functions, the kernel will attempt to fill in the label elements specified
when the label was prepared. Elements are specified in a nul-terminated
string, using commas to delimit fields. Element names may be prefixed with the
‘? ’ character to indicate that a failure
by the kernel to retrieve that element should not be considered fatal.
The
RETURN VALUESUpon successful completion, the value 0 is returned; otherwise the value -1 is returned and the global variable errno is set to indicate the error.SEE ALSOmac(3), mac_free(3), mac_get(3), mac_is_present(3), mac_set(3), mac(4), mac.conf(5), maclabel(7)STANDARDSPOSIX.1e is described in IEEE POSIX.1e draft 17. Discussion of the draft continues on the cross-platform POSIX.1e implementation mailing list. To join this list, see the FreeBSD POSIX.1e implementation page for more information.HISTORYSupport for Mandatory Access Control was introduced in FreeBSD 5.0 as part of the TrustedBSD Project. Support for generic object types first appeared in FreeBSD 5.2.
Visit the GSP FreeBSD Man Page Interface. |