Due to a merger, I have to alternate between Pulse Secure and another VPN solution. They understandably do not cooperate. I have found I can suspend the Pulse VPN and activate the "brand C" one and everything works. I'd like to be able to do this via a CLI, but I'm on MacOS and I don't seem to be able to get a CLI to work. I found /Applications/Pulse Secure.app/Contents/Plugins/JamUI/jamCommand which looks like it ought to do the trick but all I have been able to get it to do is open the GUI. I'd like to send it the /suspend or /resume commands. The docs suggest I need <GUIDS>. If I need to specify that, where do I find it?
Solved! Go to Solution.
Thanks, Ray. This is now a moot point as our IT guys have configured us such that both VPN's can coexist. But for the benefit of anyone else stumbling across this thread, I was able to locate the file you mentioned and found multiple stansas starting ive "long hex string" { corresponding to each of the VPN gateways, as well as one starting machine "local" { and one starting machine settings {. Each of these stanzas contains a different guid: "long hex string" line. I tried all of these values with jamCommand and still just manage to launch the GUI. I am able to use jamCommand to change the log level, so it is talking to the daemon. It may just be a matter of getting the right GUID into the right format in the command line. The log indicates that a command was executed and returned a 0 return code, but the state of the VPN remains unchanged. I tried both /suspend (for a running instance) and /resume (for a connection I had suspended through the GUI).
Proposed solution by @reergymerej
Topic link - https://community.pulsesecure.net/t5/Pulse-Desktop-Clients/CLI-Interface-to-Pulse-Secure-to-Suspend-...
External link - https://reergymerej.github.io/blog/2020/11/17/pulse-secure-vpn-automation.html
Thank you so much for sharing this information.
Try to find connstore.dat file under /Library/Application\ Support/Pulse\ Secure/Pulse, which would contain the GUIDs in the format of ive:<GUID>.
Good luck, @sdenham .
Thanks, Ray. This is now a moot point as our IT guys have configured us such that both VPN's can coexist. But for the benefit of anyone else stumbling across this thread, I was able to locate the file you mentioned and found multiple stansas starting ive "long hex string" { corresponding to each of the VPN gateways, as well as one starting machine "local" { and one starting machine settings {. Each of these stanzas contains a different guid: "long hex string" line. I tried all of these values with jamCommand and still just manage to launch the GUI. I am able to use jamCommand to change the log level, so it is talking to the daemon. It may just be a matter of getting the right GUID into the right format in the command line. The log indicates that a command was executed and returned a 0 return code, but the state of the VPN remains unchanged. I tried both /suspend (for a running instance) and /resume (for a connection I had suspended through the GUI).
@sdenham Tried the same thing in my lab and noticed similar results, wherein the jamcommand program when executed with /suspend <GUID> did not suspend the desired VPN connection, rather it just suspends the Pulse UI process which would not killing the VPN session.
But in case of Windows, there is another utility called PulseLauncher.exe which is capable for connection manager to suspend, resume, stop and delete the connecitons.
https://kb.pulsesecure.net/articles/Pulse_Secure_Article/KB23158/?kA1j0000000FjG0 - KB article
C:\Program Files (x86)\Common Files\Pulse Secure\Integration\pulselauncher.exe
pulselauncher [-version|-help|-stop] [-url <url> -u <user> -p <password> -r <realm>] [-d <DSID> -url <url>] [-cert <client certificate> [-usesystemcert] -url <url> -r <realm>] [<-signout|-suspend|-resume> -url <url>] [-t Time(Seconds min:45, max:600)]
Unfortunately, PulseLauncher is not available for macOS Nevertheless, I am glad to know that this is not stopping you from working, Thanks to your IT team.
-- Ray.
Proposed solution by @reergymerej
Topic link - https://community.pulsesecure.net/t5/Pulse-Desktop-Clients/CLI-Interface-to-Pulse-Secure-to-Suspend-...
External link - https://reergymerej.github.io/blog/2020/11/17/pulse-secure-vpn-automation.html
Thank you so much for sharing this information.