SV-268508r1131219_rule
V-268508
SRG-OS-000366-GPOS-00153
APPL-15-002060
CAT I
10
Configure the macOS system to apply gatekeeper settings to block applications from unidentified developers by installing the "com.apple.systempolicy.control" configuration profile.
Verify the macOS system is configured to apply gatekeeper settings to block applications from unidentified developers with the following commands:
/usr/bin/osascript -l JavaScript << EOS
function run() {
let pref1 = ObjC.unwrap($.NSUserDefaults.alloc.initWithSuiteName('com.apple.systempolicy.control')\
.objectForKey('AllowIdentifiedDevelopers'))
let pref2 = ObjC.unwrap($.NSUserDefaults.alloc.initWithSuiteName('com.apple.systempolicy.control')\
.objectForKey('EnableAssessment'))
if ( pref1 == true && pref2 == true ) {
return("true")
} else {
return("false")
}
}
EOS
If the result is not "true", this is a finding.
V-268508
False
APPL-15-002060
Verify the macOS system is configured to apply gatekeeper settings to block applications from unidentified developers with the following commands:
/usr/bin/osascript -l JavaScript << EOS
function run() {
let pref1 = ObjC.unwrap($.NSUserDefaults.alloc.initWithSuiteName('com.apple.systempolicy.control')\
.objectForKey('AllowIdentifiedDevelopers'))
let pref2 = ObjC.unwrap($.NSUserDefaults.alloc.initWithSuiteName('com.apple.systempolicy.control')\
.objectForKey('EnableAssessment'))
if ( pref1 == true && pref2 == true ) {
return("true")
} else {
return("false")
}
}
EOS
If the result is not "true", this is a finding.
M
5661