From owner-p4-projects@FreeBSD.ORG Wed Oct 15 06:37:27 2003 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 2BDED16A4C0; Wed, 15 Oct 2003 06:37:27 -0700 (PDT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 013AC16A4B3 for ; Wed, 15 Oct 2003 06:37:27 -0700 (PDT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7A0E843F3F for ; Wed, 15 Oct 2003 06:37:26 -0700 (PDT) (envelope-from cvance@nailabs.com) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.12.9/8.12.9) with ESMTP id h9FDbQXJ070276 for ; Wed, 15 Oct 2003 06:37:26 -0700 (PDT) (envelope-from cvance@nailabs.com) Received: (from perforce@localhost) by repoman.freebsd.org (8.12.9/8.12.9/Submit) id h9FDbNde070273 for perforce@freebsd.org; Wed, 15 Oct 2003 06:37:23 -0700 (PDT) (envelope-from cvance@nailabs.com) Date: Wed, 15 Oct 2003 06:37:23 -0700 (PDT) Message-Id: <200310151337.h9FDbNde070273@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to cvance@nailabs.com using -f From: Chris Vance To: Perforce Change Reviews Subject: PERFORCE change 39744 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Oct 2003 13:37:27 -0000 http://perforce.freebsd.org/chv.cgi?CH=39744 Change 39744 by cvance@cvance_osx_laptop on 2003/10/15 06:36:36 Fix module registration errors with the sebsd module. Credit goes to areisse for being the first one to trip on these... Affected files ... .. //depot/projects/trustedbsd/sedarwin/apsl/xnu/bsd/kern/kern_mac.c#19 edit .. //depot/projects/trustedbsd/sedarwin/apsl/xnu/security/sebsd/sebsd.c#4 edit Differences ... ==== //depot/projects/trustedbsd/sedarwin/apsl/xnu/bsd/kern/kern_mac.c#19 (text+ko) ==== @@ -370,11 +370,11 @@ * request. Note that it returns its value via 'error' in the scope * of the caller. */ -#define MAC_CHECK(check, args...) do { \ +#define nMAC_CHECK(check, args...) do { \ error = 0; \ } while (0) -#define oMAC_CHECK(check, args...) do { \ +#define MAC_CHECK(check, args...) do { \ struct mac_policy_conf *mpc; \ int entrycount; \ \ @@ -514,14 +514,6 @@ } while (0) -static void -mac_register_module(struct mac_policy_conf *mpconf) -{ - - printf("MAC Framework registering policy: %s\n", mpconf->mpc_name); -} - - /* * Initialize the MAC subsystem, including appropriate SMP locks. */ @@ -582,7 +574,7 @@ printf("MAC: init mac_test\n"); mac_policy_register(&test_mac_policy_conf); printf("MAC: init sebsd\n"); - mac_register_module(&sebsd_mac_policy_conf); + mac_policy_register(&sebsd_mac_policy_conf); mac_late = 1; } ==== //depot/projects/trustedbsd/sedarwin/apsl/xnu/security/sebsd/sebsd.c#4 (text+ko) ==== @@ -2292,6 +2292,6 @@ "NSA/NAI Labs Security Enhanced BSD", /* full name */ &sebsd_ops, /* policy operations */ 0, /* loadtime flags*/ - 1, /* security field */ + &slot, /* security field */ 0 /* runtime flags */ };