BaselineWatch
Desk

os_world_writable_system_folder_configure Ensure No World Writable Files Exist in the System Folder

NIST macOS Security Compliance Project Sequoia Guidance, Revision 4.0 (be5491f)
All changes in this version
first version loaded macOS

Title

Ensure No World Writable Files Exist in the System Folder

Control

/usr/bin/find /System/Volumes/Data/System -type d -perm -2 -ls | /usr/bin/grep -vE "downloadDir|locks" | /usr/bin/wc -l | /usr/bin/xargs

Discussion

Folders in /System/Volumes/Data/System _MUST_ not be world-writable.

Fix

[source,bash]
----
IFS=$'\n'
for sysPermissions in $( /usr/bin/find /System/Volumes/Data/System -type d -perm -2 | /usr/bin/grep -vE "downloadDir|locks" ); do
/bin/chmod -R o-w "$sysPermissions"
done
----