The following script can be used to disable Zscaler on macOS. Zscaler is corporate spyware and security software that controls access to Internet resources and spoofs TLS certificates to allow inspection of encrypted communications on corporate managed computers.
This script will not uninstall the Zscaler software.
You may be asked to enter a password for command operations that require
elevated privileges via sudo. If you do not have permission to run commands
with sudo then these scripts will not work for you.
Where the script makes a change to prevent automatic restarts, a 'start' action has been provided to reset those changes back to normal, so Zscaler can restart normally after a reboot.
Download and install the script using curl as shown below.
curl -L https://gist.github.com/christopher-hopper/c8033839ef927a201feb8a8e8d256ed7/raw/zscaler-stop.sh -o zscaler-stop.sh && chmod ug+x $_
NOTE: Using curl to access gist.github.com may not work when Zscaler
is running. If so, copy and paste the raw script contents to a new file and
save it as zscaler-stop.sh.
TIP: Optionally, after download move the script into the
/usr/local/bin folder so you can execute it from anywhere.
After downloading the script can be executed in the terminal.
To stop Zscaler, in a terminal run the script with no arguments:
./zscaler-stop.sh
To restart Zscaler, run the script with the start argument:
./zscaler-stop.sh start
To check if Zscaler is listening and get usage help, run the script
with the help argument:
./zscaler-stop.sh help
@elykrk the script could be used outside the terminal with something like Automator for Mac, or with a Launch Daemon plist file to run at boot time (RunAtLoad) or on a set interval (StartInterval), etc.. However you choose, in all cases the script does need elevated privileges in order to do what it needs to do.
In Automator you can run a shell script with elevated privileges using
oascriptwhich will ask for a password before it runs the script. This might not work though if you don't want to enter the password every time it is run.Another option would be to configure your system's
sudoersto allow elevated privileges, just for this script, without asking for a password. This would allow you (or anyone) to run the script and not ask for a password. With that in place, you can then use Automator and not have to enter a password at all. The only thing to be careful with here, is locking down the script file itself, so nobody can edit it without your knowledge. A shell script that runs as root without a password is a dangerous thing if left open for anyone to edit.Does that help?