Disabling remote Screen Sharing connections on your Mac

Since macOS 10.12 Sierra, configuring the built-in Screen Sharing/Remote Management service to exclusively respond to local connection requests via a secure connection has become possible.

To implement this, open Terminal.app and execute the following command:

sudo defaults write /Library/Preferences/com.apple.RemoteManagement.plist VNCOnlyLocalConnections -bool yes

To revert to the default behavior, replace "yes" with "no" at the end of the command.

Requirement: Enable Secure Connections

For this configuration to take effect, it's essential to activate Secure Connections (SSH) in both Screens and Screens Connect (if installed). Connecting without a secure connection won't be possible since the VNCOnlyLocalConnections parameter instructs the service to exclusively listen on localhost.

Enable Secure Connections in Screens Connect

Navigate to the Preferences window, go to the General section, and enable Use Remote Login.

Enable Secure Connections in Screens

In Screens, to enable secure connections, access the Security section within your saved connection settings.

Important: Ensure that Enable on the local connections is turned on.

Still need help?

Send us an Email