mac_biba.c (122879) | mac_biba.c (123173) |
---|---|
1/*- 2 * Copyright (c) 1999, 2000, 2001, 2002 Robert N. M. Watson 3 * Copyright (c) 2001, 2002, 2003 Networks Associates Technology, Inc. 4 * All rights reserved. 5 * 6 * This software was developed by Robert Watson for the TrustedBSD Project. 7 * 8 * This software was developed for the FreeBSD Project in part by Network --- 17 unchanged lines hidden (view full) --- 26 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 27 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 28 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 29 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 30 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 31 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 32 * SUCH DAMAGE. 33 * | 1/*- 2 * Copyright (c) 1999, 2000, 2001, 2002 Robert N. M. Watson 3 * Copyright (c) 2001, 2002, 2003 Networks Associates Technology, Inc. 4 * All rights reserved. 5 * 6 * This software was developed by Robert Watson for the TrustedBSD Project. 7 * 8 * This software was developed for the FreeBSD Project in part by Network --- 17 unchanged lines hidden (view full) --- 26 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 27 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 28 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 29 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 30 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 31 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 32 * SUCH DAMAGE. 33 * |
34 * $FreeBSD: head/sys/security/mac_biba/mac_biba.c 122879 2003-11-18 04:11:52Z rwatson $ | 34 * $FreeBSD: head/sys/security/mac_biba/mac_biba.c 123173 2003-12-06 21:48:03Z rwatson $ |
35 */ 36 37/* 38 * Developed by the TrustedBSD Project. 39 * Biba fixed label mandatory integrity policy. 40 */ 41 42#include <sys/types.h> --- 1280 unchanged lines hidden (view full) --- 1323 1324 mac_biba_copy(source, dest); 1325} 1326 1327/* 1328 * Labeling event operations: processes. 1329 */ 1330static void | 35 */ 36 37/* 38 * Developed by the TrustedBSD Project. 39 * Biba fixed label mandatory integrity policy. 40 */ 41 42#include <sys/types.h> --- 1280 unchanged lines hidden (view full) --- 1323 1324 mac_biba_copy(source, dest); 1325} 1326 1327/* 1328 * Labeling event operations: processes. 1329 */ 1330static void |
1331mac_biba_create_cred(struct ucred *cred_parent, struct ucred *cred_child) 1332{ 1333 struct mac_biba *source, *dest; 1334 1335 source = SLOT(cred_parent->cr_label); 1336 dest = SLOT(cred_child->cr_label); 1337 1338 mac_biba_copy_single(source, dest); 1339 mac_biba_copy_range(source, dest); 1340} 1341 1342static void | |
1343mac_biba_create_proc0(struct ucred *cred) 1344{ 1345 struct mac_biba *dest; 1346 1347 dest = SLOT(cred->cr_label); 1348 1349 mac_biba_set_single(dest, MAC_BIBA_TYPE_EQUAL, 0, NULL); 1350 mac_biba_set_range(dest, MAC_BIBA_TYPE_LOW, 0, NULL, --- 1312 unchanged lines hidden (view full) --- 2663 .mpo_destroy_ipq_label = mac_biba_destroy_label, 2664 .mpo_destroy_mbuf_label = mac_biba_destroy_label, 2665 .mpo_destroy_mount_label = mac_biba_destroy_label, 2666 .mpo_destroy_mount_fs_label = mac_biba_destroy_label, 2667 .mpo_destroy_pipe_label = mac_biba_destroy_label, 2668 .mpo_destroy_socket_label = mac_biba_destroy_label, 2669 .mpo_destroy_socket_peer_label = mac_biba_destroy_label, 2670 .mpo_destroy_vnode_label = mac_biba_destroy_label, | 1331mac_biba_create_proc0(struct ucred *cred) 1332{ 1333 struct mac_biba *dest; 1334 1335 dest = SLOT(cred->cr_label); 1336 1337 mac_biba_set_single(dest, MAC_BIBA_TYPE_EQUAL, 0, NULL); 1338 mac_biba_set_range(dest, MAC_BIBA_TYPE_LOW, 0, NULL, --- 1312 unchanged lines hidden (view full) --- 2651 .mpo_destroy_ipq_label = mac_biba_destroy_label, 2652 .mpo_destroy_mbuf_label = mac_biba_destroy_label, 2653 .mpo_destroy_mount_label = mac_biba_destroy_label, 2654 .mpo_destroy_mount_fs_label = mac_biba_destroy_label, 2655 .mpo_destroy_pipe_label = mac_biba_destroy_label, 2656 .mpo_destroy_socket_label = mac_biba_destroy_label, 2657 .mpo_destroy_socket_peer_label = mac_biba_destroy_label, 2658 .mpo_destroy_vnode_label = mac_biba_destroy_label, |
2659 .mpo_copy_cred_label = mac_biba_copy_label, |
|
2671 .mpo_copy_mbuf_label = mac_biba_copy_label, 2672 .mpo_copy_pipe_label = mac_biba_copy_label, 2673 .mpo_copy_socket_label = mac_biba_copy_label, 2674 .mpo_copy_vnode_label = mac_biba_copy_label, 2675 .mpo_externalize_cred_label = mac_biba_externalize_label, 2676 .mpo_externalize_ifnet_label = mac_biba_externalize_label, 2677 .mpo_externalize_pipe_label = mac_biba_externalize_label, 2678 .mpo_externalize_socket_label = mac_biba_externalize_label, --- 35 unchanged lines hidden (view full) --- 2714 .mpo_create_mbuf_from_bpfdesc = mac_biba_create_mbuf_from_bpfdesc, 2715 .mpo_create_mbuf_from_ifnet = mac_biba_create_mbuf_from_ifnet, 2716 .mpo_create_mbuf_multicast_encap = mac_biba_create_mbuf_multicast_encap, 2717 .mpo_create_mbuf_netlayer = mac_biba_create_mbuf_netlayer, 2718 .mpo_fragment_match = mac_biba_fragment_match, 2719 .mpo_relabel_ifnet = mac_biba_relabel_ifnet, 2720 .mpo_update_ipq = mac_biba_update_ipq, 2721 .mpo_inpcb_sosetlabel = mac_biba_inpcb_sosetlabel, | 2660 .mpo_copy_mbuf_label = mac_biba_copy_label, 2661 .mpo_copy_pipe_label = mac_biba_copy_label, 2662 .mpo_copy_socket_label = mac_biba_copy_label, 2663 .mpo_copy_vnode_label = mac_biba_copy_label, 2664 .mpo_externalize_cred_label = mac_biba_externalize_label, 2665 .mpo_externalize_ifnet_label = mac_biba_externalize_label, 2666 .mpo_externalize_pipe_label = mac_biba_externalize_label, 2667 .mpo_externalize_socket_label = mac_biba_externalize_label, --- 35 unchanged lines hidden (view full) --- 2703 .mpo_create_mbuf_from_bpfdesc = mac_biba_create_mbuf_from_bpfdesc, 2704 .mpo_create_mbuf_from_ifnet = mac_biba_create_mbuf_from_ifnet, 2705 .mpo_create_mbuf_multicast_encap = mac_biba_create_mbuf_multicast_encap, 2706 .mpo_create_mbuf_netlayer = mac_biba_create_mbuf_netlayer, 2707 .mpo_fragment_match = mac_biba_fragment_match, 2708 .mpo_relabel_ifnet = mac_biba_relabel_ifnet, 2709 .mpo_update_ipq = mac_biba_update_ipq, 2710 .mpo_inpcb_sosetlabel = mac_biba_inpcb_sosetlabel, |
2722 .mpo_create_cred = mac_biba_create_cred, | |
2723 .mpo_create_proc0 = mac_biba_create_proc0, 2724 .mpo_create_proc1 = mac_biba_create_proc1, 2725 .mpo_relabel_cred = mac_biba_relabel_cred, 2726 .mpo_check_bpfdesc_receive = mac_biba_check_bpfdesc_receive, 2727 .mpo_check_cred_relabel = mac_biba_check_cred_relabel, 2728 .mpo_check_cred_visible = mac_biba_check_cred_visible, 2729 .mpo_check_ifnet_relabel = mac_biba_check_ifnet_relabel, 2730 .mpo_check_ifnet_transmit = mac_biba_check_ifnet_transmit, --- 58 unchanged lines hidden --- | 2711 .mpo_create_proc0 = mac_biba_create_proc0, 2712 .mpo_create_proc1 = mac_biba_create_proc1, 2713 .mpo_relabel_cred = mac_biba_relabel_cred, 2714 .mpo_check_bpfdesc_receive = mac_biba_check_bpfdesc_receive, 2715 .mpo_check_cred_relabel = mac_biba_check_cred_relabel, 2716 .mpo_check_cred_visible = mac_biba_check_cred_visible, 2717 .mpo_check_ifnet_relabel = mac_biba_check_ifnet_relabel, 2718 .mpo_check_ifnet_transmit = mac_biba_check_ifnet_transmit, --- 58 unchanged lines hidden --- |