summaryrefslogtreecommitdiffstats
path: root/sys/security/mac_mls/mac_mls.c
diff options
context:
space:
mode:
authorrwatson <rwatson@FreeBSD.org>2002-10-21 16:39:12 +0000
committerrwatson <rwatson@FreeBSD.org>2002-10-21 16:39:12 +0000
commit963bded1fb2f4ecfdaa5a4ec70ab3f869451e270 (patch)
treedbcc5fbe026a55102da4486bf1c825a5388748b7 /sys/security/mac_mls/mac_mls.c
parentec031d49239e57b45533903e045aebb509b6f768 (diff)
downloadFreeBSD-src-963bded1fb2f4ecfdaa5a4ec70ab3f869451e270.zip
FreeBSD-src-963bded1fb2f4ecfdaa5a4ec70ab3f869451e270.tar.gz
Since the Biba and MLS access checks are identical to the open checks,
collapse the two cases more cleanly: rather than wrapping an access check around open, simply provide the open implementation for the access vector entry. No functional change. Obtained from: TrustedBSD Project Sponsored by: DARPA, Network Associates Laboratories
Diffstat (limited to 'sys/security/mac_mls/mac_mls.c')
-rw-r--r--sys/security/mac_mls/mac_mls.c13
1 files changed, 1 insertions, 12 deletions
diff --git a/sys/security/mac_mls/mac_mls.c b/sys/security/mac_mls/mac_mls.c
index 345592b..63150d3 100644
--- a/sys/security/mac_mls/mac_mls.c
+++ b/sys/security/mac_mls/mac_mls.c
@@ -107,9 +107,6 @@ static int mac_mls_slot;
MALLOC_DEFINE(M_MACMLS, "mls label", "MAC/MLS labels");
-static int mac_mls_check_vnode_open(struct ucred *cred, struct vnode *vp,
- struct label *vnodelabel, mode_t acc_mode);
-
static struct mac_mls *
mls_alloc(int flag)
{
@@ -1462,14 +1459,6 @@ mac_mls_check_socket_visible(struct ucred *cred, struct socket *socket,
}
static int
-mac_mls_check_vnode_access(struct ucred *cred, struct vnode *vp,
- struct label *label, mode_t flags)
-{
-
- return (mac_mls_check_vnode_open(cred, vp, label, flags));
-}
-
-static int
mac_mls_check_vnode_chdir(struct ucred *cred, struct vnode *dvp,
struct label *dlabel)
{
@@ -2231,7 +2220,7 @@ static struct mac_policy_op_entry mac_mls_ops[] =
{ MAC_CHECK_SOCKET_VISIBLE,
(macop_t)mac_mls_check_socket_visible },
{ MAC_CHECK_VNODE_ACCESS,
- (macop_t)mac_mls_check_vnode_access },
+ (macop_t)mac_mls_check_vnode_open },
{ MAC_CHECK_VNODE_CHDIR,
(macop_t)mac_mls_check_vnode_chdir },
{ MAC_CHECK_VNODE_CHROOT,
OpenPOWER on IntegriCloud