mac_set.c revision 176901
11473SN/A/*
27953SN/A * Copyright (c) 1999, 2000, 2001, 2002 Robert N. M. Watson
31473SN/A * All rights reserved.
41473SN/A *
51473SN/A * This software was developed by Robert Watson for the TrustedBSD Project.
61473SN/A *
71473SN/A * Redistribution and use in source and binary forms, with or without
82362SN/A * modification, are permitted provided that the following conditions
91473SN/A * are met:
102362SN/A * 1. Redistributions of source code must retain the above copyright
111473SN/A *    notice, this list of conditions and the following disclaimer.
121473SN/A * 2. Redistributions in binary form must reproduce the above copyright
131473SN/A *    notice, this list of conditions and the following disclaimer in the
141473SN/A *    documentation and/or other materials provided with the distribution.
151473SN/A * 3. The names of the authors may not be used to endorse or promote
161473SN/A *    products derived from this software without specific prior written
171473SN/A *    permission.
181473SN/A *
191473SN/A * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
201473SN/A * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
211473SN/A * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
222362SN/A * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
232362SN/A * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
242362SN/A * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
251473SN/A * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
261473SN/A * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
271473SN/A * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
281473SN/A * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
291473SN/A * SUCH DAMAGE.
301473SN/A */
311473SN/A
321473SN/A#include <sys/cdefs.h>
331473SN/A__FBSDID("$FreeBSD: head/lib/libc/posix1e/mac_set.c 176901 2008-03-07 15:25:56Z rwatson $");
341473SN/A
351473SN/A#include <sys/types.h>
361473SN/A#include <sys/mac.h>
371473SN/A
381473SN/Aextern	int	__mac_set_fd(int fd, struct mac *mac_p);
391473SN/Aextern	int	__mac_set_file(const char *path_p, struct mac *mac_p);
401473SN/Aextern	int	__mac_set_link(const char *path_p, struct mac *mac_p);
411473SN/Aextern	int	__mac_set_proc(struct mac *mac_p);
421473SN/A
431473SN/Aint
441473SN/Amac_set_fd(int fd, struct mac *label)
451473SN/A{
461473SN/A
471473SN/A	return (__mac_set_fd(fd, label));
481473SN/A}
491473SN/A
501473SN/Aint
511473SN/Amac_set_file(const char *path, struct mac *label)
521473SN/A{
531473SN/A
541473SN/A	return (__mac_set_file(path, label));
551473SN/A}
561473SN/A
571473SN/Aint
581473SN/Amac_set_link(const char *path, struct mac *label)
591473SN/A{
601473SN/A
611473SN/A	return (__mac_set_link(path, label));
621473SN/A}
631473SN/A
641473SN/Aint
651473SN/Amac_set_proc(struct mac *label)
661473SN/A{
671473SN/A
681473SN/A	return (__mac_set_proc(label));
691473SN/A}
701473SN/A