1 .\" Copyright (c) 2001 Networks Associates Technology, Inc.
2 .\" All rights reserved.
4 .\" This software was developed for the FreeBSD Project by Chris
5 .\" Costello at Safeport Network Services and NAI Labs, the Security
6 .\" Research Division of Network Associates, Inc. under DARPA/SPAWAR
7 .\" contract N66001-01-C-8035 ("CBOSS"), as part of the DARPA CHATS
10 .\" Redistribution and use in source and binary forms, with or without
11 .\" modification, are permitted provided that the following conditions
13 .\" 1. Redistributions of source code must retain the above copyright
14 .\" notice, this list of conditions and the following disclaimer.
15 .\" 2. Redistributions in binary form must reproduce the above copyright
16 .\" notice, this list of conditions and the following disclaimer in the
17 .\" documentation and/or other materials provided with the distribution.
19 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHORS AND CONTRIBUTORS ``AS IS'' AND
20 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
21 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
22 .\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE LIABLE
23 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
24 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
25 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
26 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
27 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
28 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
39 .Nd convert MAC label to/from text representation
45 .Fn mac_from_text "mac_t *mac" "const char *text"
47 .Fn mac_to_text "mac_t label" "char **text"
51 function converts the text representation of a label
52 into the internal policy label format
56 which must later be freed with
61 function allocates storage for
63 which will be set to the text representation of
68 for the MAC label format.
70 .Rv -std mac_from_text mac_to_text
72 POSIX.1e does not define
73 a format for text representations
76 POSIX.1e requires that text strings allocated using
82 implementation, they must be freed using
86 is used only to free memory used for type
91 Insufficient memory was available
92 to allocate internal storage.
98 .Xr mac_is_present 3 ,
105 POSIX.1e is described in IEEE POSIX.1e draft 17.
106 Discussion of the draft
107 continues on the cross-platform POSIX.1e implementation mailing list.
108 To join this list, see the
110 POSIX.1e implementation page
111 for more information.
113 Support for Mandatory Access Control was introduced in