1.100 APPL-26-002110

Information

The macOS system must disable Bluetooth Sharing.

GROUP ID: V-277127
RULE ID: SV-277127r1149415

Bluetooth Sharing must be disabled.

Bluetooth Sharing allows users to wirelessly transmit files between the macOS and Bluetooth-enabled devices, including personally owned cellphones and tablets. A malicious user might introduce viruses or malware onto the system or extract sensitive files via Bluetooth Sharing. When Bluetooth Sharing is disabled, this risk is mitigated.

[NOTE]

The check and fix are for the last logged in user. To get the last logged in user, run the following.
[source,bash]

CURRENT_USER=$( /usr/bin/defaults read /Library/Preferences/com.apple.loginwindow lastUserName )

====

Satisfies: SRG-OS-000080-GPOS-00048, SRG-OS-000095-GPOS-00049

Solution

Configure the macOS system to disable Bluetooth sharing with the following commands:

CURRENT_USER=$( /usr/sbin/scutil <<< "show State:/Users/ConsoleUser" | /usr/bin/awk '/Name :/ && ! /loginwindow/ { print $3 }' )
/usr/bin/sudo -u "$CURRENT_USER" /usr/bin/defaults -currentHost write com.apple.Bluetooth PrefKeyServicesEnabled -bool false

See Also

https://workbench.cisecurity.org/benchmarks/26538