diff options
author | Robert Watson <rwatson@FreeBSD.org> | 2003-12-10 18:48:05 +0000 |
---|---|---|
committer | Robert Watson <rwatson@FreeBSD.org> | 2003-12-10 18:48:05 +0000 |
commit | 7b9ed9a7938dabb3f9043d87c57bd5aeec0ca542 (patch) | |
tree | 77c0706161b8078f41917f40845436e2200dd7b0 /sys/security/mac_test | |
parent | 20dc9331aacca4ea06c7bf7b7563b608cf736c67 (diff) | |
download | src-7b9ed9a7938dabb3f9043d87c57bd5aeec0ca542.tar.gz src-7b9ed9a7938dabb3f9043d87c57bd5aeec0ca542.zip |
interpvnodelabel can be NULL in mac_test_execve_transition(). This
only turned up when running mac_test side by side with a transitioning
policy such as SEBSD. Make the NULL testing match
mac_test_execve_will_transition(), which already tested the vnode
label pointer for NULL.
Obtained from: TrustedBSD Project
Sponsored by: DARPA, Network Associates Laboratories
Notes
Notes:
svn path=/head/; revision=123397
Diffstat (limited to 'sys/security/mac_test')
-rw-r--r-- | sys/security/mac_test/mac_test.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/security/mac_test/mac_test.c b/sys/security/mac_test/mac_test.c index ef8c5b3126ba..05f0e8c85a48 100644 --- a/sys/security/mac_test/mac_test.c +++ b/sys/security/mac_test/mac_test.c @@ -1038,7 +1038,9 @@ mac_test_execve_transition(struct ucred *old, struct ucred *new, ASSERT_CRED_LABEL(old->cr_label); ASSERT_CRED_LABEL(new->cr_label); ASSERT_VNODE_LABEL(filelabel); - ASSERT_VNODE_LABEL(interpvnodelabel); + if (interpvnodelabel != NULL) { + ASSERT_VNODE_LABEL(interpvnodelabel); + } if (execlabel != NULL) { ASSERT_CRED_LABEL(execlabel); } |