Disabling Gatekeeper on macOS

Gatekeeper is a security feature of the macOS operating system. It verifies that only trusted software runs on your Mac. And if the software being launched has been changed, the user will receive a message about corruption…
It is impossible to launch a damaged application without disabling the Gatekeeper function or bypassing the Quarantine function (usually the procedure is called Dequarantine or de-quarantine).

Solution 1 (Dequarantine).

This option will allow you to bypass Quarantine for a specific application. Note that the command includes the path to the application, or image (.dmg).”

1. Launch the Terminal utility. 
This is a standard utility that does not need to be installed additionally. The terminal can be found through Spotlight.

2. Use the command: sudo xattr -r -c Enter a space and drag the damaged program into the Terminal window. The team will add it.
Important! The command does not affect files in the image (.dmg). It is necessary to copy the damaged program, for example, to the desktop, and apply the command to it. In some cases, the command can be applied to the image (.dmg) before mounting. 

3. Press Enter and enter the Administrator password.
The password is not displayed when entered into the Terminal, but is entered.
If a password has not been set, create one.

4. Proceed to launch the damaged program.
Wait for the verification to complete and you will be able to Open it.
The verification time can take up to 30 minutes.

Solution 2 (disabling Gatekeeper).

This command will allow you to disable Gatekeeper, i.e. restore settings that allow the use of programs downloaded from Any source in System Settings / Protection and Security.

1. Launch the Terminal utility and run the command

For macOS 10.12 – 10.15.7

sudo spctl --master-disable

For macOS 11 and later

sudo spctl --global-disable

There is no need to drag anything into the Terminal. To enable Gatekeeper, replace “disable” with “enable”.

2. Press Enter and enter the Administrator password.

3. Proceed to launch the damaged program.


You can read more about Gatekeeper at  support.apple.com or wikipedia.org or developer.apple.com

You can read more about extended attributes and the xattr command on  wikipedia.org or real-world-systems.com or ss64.com

Leave a Reply

Your email address will not be published. Required fields are marked *