I'm trying to have an "On Connect Script" in Forticlient EMS. The goal is to execute the command gpupdate /force on clients whenever they connect to our SSL VPN because we have some clients always connecting from remote.
The admin guide doesn't have much info about this :
http://docs.fortinet.com/uploaded/files/3269/forticlient-ems-v1.0.2-admin-guide.pdf
Page 68
And I tried something like this :
<on_connect><script><os>windows</os><script><script><![CDATA[ gpupdate /force ]]></script></script></script></on_connect> Since it's already an On Connect Script box maybe I don't have to put all brackets but I also tried to put this in the XML config directly and didn't work. Any clue?
Fortigate : 80E, 80F, 100E, 200F, 300E : 6.4.6
FortiAnalyzer, ForticlientEMS
It was way simpler than I thought.
I simply had to put gpupdate /force in the box and it works. Clients now update their group policies after a SSL VPN tunnel connection.
Fortigate : 80E, 80F, 100E, 200F, 300E : 6.4.6
FortiAnalyzer, ForticlientEMS
What "box" are you referring to? I know this is an ancient post but maybe you are still around and will recall. Thanks.
Please try this, Its working for me.
Regards
Ajith M
<on_connect>
<script>
<os>windows</os>
<script><![CDATA[timeout /t 10 /nobreak
gpupdate /force]]></script>
</script>
</on_connect>
How to confirm whether its working....can we check it in the logs.
Select Forum Responses to become Knowledge Articles!
Select the “Nominate to Knowledge Base” button to recommend a forum post to become a knowledge article.
User | Count |
---|---|
1742 | |
1113 | |
759 | |
447 | |
241 |
The Fortinet Security Fabric brings together the concepts of convergence and consolidation to provide comprehensive cybersecurity protection for all users, devices, and applications and across all network edges.
Copyright 2025 Fortinet, Inc. All Rights Reserved.