From owner-p4-projects Tue Apr 23 9:43:19 2002 Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id B582937B400; Tue, 23 Apr 2002 09:43:07 -0700 (PDT) Delivered-To: perforce@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id BEC1737B434 for ; Tue, 23 Apr 2002 09:43:03 -0700 (PDT) Received: (from perforce@localhost) by freefall.freebsd.org (8.11.6/8.11.6) id g3NGh3318923 for perforce@freebsd.org; Tue, 23 Apr 2002 09:43:03 -0700 (PDT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Tue, 23 Apr 2002 09:43:03 -0700 (PDT) Message-Id: <200204231643.g3NGh3318923@freefall.freebsd.org> X-Authentication-Warning: freefall.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson Subject: PERFORCE change 10182 for review To: Perforce Change Reviews Sender: owner-p4-projects@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG http://people.freebsd.org/~peter/p4db/chv.cgi?CH=10182 Change 10182 by rwatson@rwatson_curry on 2002/04/23 09:42:58 Remove many of the mac_te-local definitions from mac.h, and stick them in a new mac_te.h under the sub-directory specific to mac_te. Not all definitions can be moved, because 'struct mac_te' is still relevant to the definition of 'struct mac'. Currently, there don't appear to be consumers of these definitions outside the kernel, so mac_te.h is not installed. If that conclusion is wrong/changes, we can fix it easily enough. Affected files ... ... //depot/projects/trustedbsd/mac/sys/security/mac_te/mac_te.c#23 edit ... //depot/projects/trustedbsd/mac/sys/security/mac_te/mac_te.h#1 add ... //depot/projects/trustedbsd/mac/sys/sys/mac.h#94 edit Differences ... ==== //depot/projects/trustedbsd/mac/sys/security/mac_te/mac_te.c#23 (text+ko) ==== @@ -66,6 +66,8 @@ #include #include +#include + #ifdef MAC SYSCTL_DECL(_security_mac); ==== //depot/projects/trustedbsd/mac/sys/sys/mac.h#94 (text+ko) ==== @@ -132,60 +132,6 @@ struct mac_te { char mt_type[MAC_TE_TYPE_MAXLEN+1]; /* TE type */ }; -#define MAC_TE_TYPE_UNINITIALIZED "uninitialized_t" -#define MAC_TE_TYPE_EQUAL "equal" -#define MAC_TE_TYPE_INIT "init_d" -#define MAC_TE_TYPE_KPROC "kproc_d" -#define MAC_TE_TYPE_ROOTFS "rootfs_t" -#define MAC_TE_TYPE_FS "fs_t" -#define MAC_TE_TYPE_DEVICE "device_t" -#define MAC_TE_TYPE_DEVNULL "devnull_t" -#define MAC_TE_TYPE_DEVZERO "devzero_t" -#define MAC_TE_TYPE_DEVRANDOM "devrandom_t" -#define MAC_TE_TYPE_DEVFD "devfd_t" - -#define MAC_TE_CLASS_ANY 0 -#define MAC_TE_OPERATION_ANY 0 - -#define MAC_TE_CLASS_PROC 1 -#define MAC_TE_OPERATION_PROC_DEBUG 1 -#define MAC_TE_OPERATION_PROC_SCHED 2 -#define MAC_TE_OPERATION_PROC_SEE 3 -#define MAC_TE_OPERATION_PROC_SIGNAL 4 - -#define MAC_TE_CLASS_FILE 2 -#define MAC_TE_OPERATION_FILE_ADMIN 1 -#define MAC_TE_OPERATION_FILE_DELETE 2 -#define MAC_TE_OPERATION_FILE_EXEC 3 -#define MAC_TE_OPERATION_FILE_GETEXTATTR 4 -#define MAC_TE_OPERATION_FILE_READ 5 -#define MAC_TE_OPERATION_FILE_SETEXTATTR 6 -#define MAC_TE_OPERATION_FILE_STAT 7 -#define MAC_TE_OPERATION_FILE_WRITE 8 - -#define MAC_TE_CLASS_MBUF 3 -#define MAC_TE_OPERATION_MBUF_RECEIVE 1 -#define MAC_TE_OPERATION_MBUF_SEND 2 - -#define MAC_TE_CLASS_DIR 4 -#define MAC_TE_OPERATION_DIR_ADMIN 1 -#define MAC_TE_OPERATION_DIR_CHDIR 2 -#define MAC_TE_OPERATION_DIR_DELETE 3 -#define MAC_TE_OPERATION_DIR_GETEXTATTR 4 -#define MAC_TE_OPERATION_DIR_LOOKUP 5 -#define MAC_TE_OPERATION_DIR_READ 6 -#define MAC_TE_OPERATION_DIR_SETEXTATTR 7 -#define MAC_TE_OPERATION_DIR_STAT 8 -#define MAC_TE_OPERATION_DIR_WRITE 9 - -#define MAC_TE_CLASS_FS 5 -#define MAC_TE_OPERATION_FS_STATFS 1 - -#define MAC_TE_CLASS_BPF 6 -#define MAC_TE_OPERATION_BPF_RECEIVE 1 - -#define MAC_TE_CLASS_SOCKET 7 -#define MAC_TE_OPERATION_SOCKET_SEE 1 struct mac_sebsd { uint32_t ms_psid; /* persistent sid storage */ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe p4-projects" in the body of the message