svn commit: r321056 - stable/10/sys/security/mac_bsdextended
Ed Maste
emaste at FreeBSD.org
Sun Jul 16 19:25:19 UTC 2017
Author: emaste
Date: Sun Jul 16 19:25:18 2017
New Revision: 321056
URL: https://svnweb.freebsd.org/changeset/base/321056
Log:
MFC r319890: Correct bitwise test in mac_bsdextended ugidfw_rule_valid()
PR: 218039
CID: 1008934
Reported by: Coverity, PVS-Studio
Sponsored by: The FreeBSD Foundation
Modified:
stable/10/sys/security/mac_bsdextended/mac_bsdextended.c
Directory Properties:
stable/10/ (props changed)
Modified: stable/10/sys/security/mac_bsdextended/mac_bsdextended.c
==============================================================================
--- stable/10/sys/security/mac_bsdextended/mac_bsdextended.c Sun Jul 16 19:24:09 2017 (r321055)
+++ stable/10/sys/security/mac_bsdextended/mac_bsdextended.c Sun Jul 16 19:25:18 2017 (r321056)
@@ -126,7 +126,7 @@ ugidfw_rule_valid(struct mac_bsdextended_rule *rule)
return (EINVAL);
if ((rule->mbr_object.mbo_neg | MBO_ALL_FLAGS) != MBO_ALL_FLAGS)
return (EINVAL);
- if ((rule->mbr_object.mbo_neg | MBO_TYPE_DEFINED) &&
+ if (((rule->mbr_object.mbo_flags & MBO_TYPE_DEFINED) != 0) &&
(rule->mbr_object.mbo_type | MBO_ALL_TYPE) != MBO_ALL_TYPE)
return (EINVAL);
if ((rule->mbr_mode | MBI_ALLPERM) != MBI_ALLPERM)
More information about the svn-src-all
mailing list