VPN- Silently Install EXE

Isaias Perez
Isaias Perez used Ask the Experts™
on
I have a VPN file that was created by our former IT group and I have no idea how. Its a windows based VPN. We recently implemented Intune in our environment and I am trying to set it up so that it installs the EXE as part of the base software configuration. Problem is i dont know the silent switch. I have tried the a few like .exe /Silent. I have attached the results of TP-VPN.exe /?. Is there a way i can find the silent switch of the VPN or create a powershell script that will just run the VPN even if its not silent. I just need it to install. If i just run the executable the first thing that pops up is a message stating " Do you wish to install Contonso VPN? Wondering how i can bypass that message. If i extract the contents of the exe. I see an executable named cmstp.exe. There also config files that might be able to examine.

 

exe-switch.jpgexe-switch.jpg
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Most Valuable Expert 2018
Distinguished Expert 2018

Commented:
The first option, /Q, might do the trick.
Isaias PerezIT Operations Manager

Author

Commented:
I tried all of the options. they all yield the error message above
Most Valuable Expert 2018
Distinguished Expert 2018

Commented:
Just to make sure: did you try it with a capital Q? Command line arguments can be case sensitive.
Acronis in Gartner 2019 MQ for datacenter backup

It is an honor to be featured in Gartner 2019 Magic Quadrant for Datacenter Backup and Recovery Solutions. Gartner’s MQ sets a high standard and earning a place on their grid is a great affirmation that Acronis is delivering on our mission to protect all data, apps, and systems.

Isaias PerezIT Operations Manager

Author

Commented:
yes I did
Adam LeinssSystems Administrator

Commented:
Try running strings on the installer: https://docs.microsoft.com/en-us/sysinternals/downloads/strings

You might get lucky and find the command line option that way.  I used that trick to find Velaro's silent command line switch: http://leinss.com/blog/?m=201502
Most Valuable Expert 2018
Distinguished Expert 2018

Commented:
OK, that is something home-grown that was done using iexpress.exe.
There aren't indeed any other relevant command line options than that, and /Q doesn't work because whoever created the package didn't seem to have added an "install" command.
What exactly happens after you confirm the dialog?
Isaias PerezIT Operations Manager

Author

Commented:
Sorry it took me long to respond. So when you initiate the exe first thing it asks is if you are sure you want to install? Then it asks if for the current user or all users and a check mark if you want to put the short cut on the desktop.If you select all users (which is what i want by default) a UAC window pops up asking for admin priv.  Please see attached pictures.

tpvpn1.png
tpvpn2.png
Isaias PerezIT Operations Manager

Author

Commented:
Then the VPN installs

tpvpn3.jpg
Most Valuable Expert 2018
Distinguished Expert 2018
Commented:
Seems like that exe and its contents was created using the Connection Manager Administration Kit.
How to create a Connection Profile with the CMAK Wizard
https://www.windows-server-2012-r2.com/how-to-create-a-connection-profile-with-the-cmak-wizard.html

You can try it with this command:
TP-VPN.exe /Q /C:"cmstp.exe /s /au TP-VPN.inf"

Open in new window

If this doesn't work, unpack the exe to a folder like C:\Temp\VPN, and try (adjust the inf file name to the one that should be inside the folder, if required)
cmstp.exe /s /au "C:\Temp\VPN\TP-VPN.inf"

Open in new window

Isaias PerezIT Operations Manager

Author

Commented:
Thank you so much ODBA. This worked flawlessly.

TP-VPN.exe /Q /C:"cmstp.exe /s /au TP-VPN.inf"
Isaias PerezIT Operations Manager

Author

Commented:
The crazy thing now is finding a detection method. I literally cant find any. When this installs it does leave any trace of an install in the Programs and Features. I cant tell what folder or registry file it has created. I tried using procmon but man thats tough as its moving a million miles an hour.I tried using another utility and all it gave me was the following:

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce]
"wextract_cleanup0"="rundll32.exe C:\\Windows\\system32\\advpack.dll,DelNodeRunDLL32 \"C:\\Users\\Admin\\AppData\\Local\\Temp\\IXP000.TMP\\\""

Can i use any of that ODBA?
Most Valuable Expert 2018
Distinguished Expert 2018

Commented:
That won't help you any, that's just temporary files that will be cleaned up during the next reboot,
Can't test it, but try it with Get-VpnConnection:
https://docs.microsoft.com/en-us/powershell/module/vpnclient/get-vpnconnection

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial