Uninstalling FortiClient the fun and easy way

eti_andrei
New Contributor II

Fortinet's recent FortiOS 5.4.1 release for their FortiGate security appliances prevents any version of FortiClient prior to 5.4.1 from registering to the appliance. Users may even get a "FortiClient is being actively blocked from registration" which can cause panic and confusion. The problem is that, as of this writing, FortiClient 5.4.1 has yet to be released. Talk about putting the cart before the horse.

So let's say that you don't want to have a few hundred upset users and would rather uninstall FortiClient discretely, en masse. Fortinet's documentation tells you to run the FortiClientUninstaller GUI app to uninstall FortiClient. But here's a more streamlined and scriptable method:

/Applications/FortiClientUninstaller.app/Contents/Resources/uninstall_helper
rm -rf /Library/Application Support/Fortinet/

Optionally, check for the existence of the following file and delete if it exists
/private/var/root/Library/Preferences/com.fortinet.FortiClientAgent.plist

2 REPLIES 2

saikat_tripathi
New Contributor II

Fortinet Client v6.4 I tried below command and it worked well.

!/bin/bash

/Applications/FortiClientUninstaller.app/Contents/Library/LaunchServices/com.fortinet.forticlient.uninstall_helper
rm -rf /Library/Application Support/Fortinet/
rm -rf /private/var/root/Library/Preferences/com.fortinet.FortiClientAgent.plist
exit 0

Hi @saikat_tripathi 

i tried the first command from your above post on Forticlient 7.x version but i get below errors on terminal.
Can you please help here ?
Thanks

Screenshot 2023-08-02 at 8.27.31 PM.png