cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
548
Views
0
Helpful
7
Replies

How do can script a client VPN session

t.fortmann
Level 1
Level 1

I have a need to automate a client VPN connection from within my application. I currently launch the client, but I would prefer to automate the complete login and logout. Does anyone know if there is a CLI available to do this? Alternatively, I found reference to a VPN API available, however, I can not find any documentation for this API on the Cisco site - not sure if this is a public API. The API may be the preferred method assuming it provides a callback mechanism for my application to present status and error information to the user.

Thank you in advance for any help.

7 Replies 7

mchin345
Level 6
Level 6

Post you running config

Running config? I'm not sure I follow - is there a server side configuration option that impacts a connected Mac notebook's ability to script the VPNClient connect process?

But do you realize the security implications of this? Like a stolen laptop etc?

After all this is one of the primary reasons X-auth was invented....

Regards

Farrukh

I do understand the security implications. I'm not looking to store the user's credentials. I just want to make use of the Mac OS X vpnclient.framework library to embedded the login prompt in my application.

t.fortmann
Level 1
Level 1

Yes - Thank you. I found this late last week and it turns out you can execute vpnclient from a bash prompt with these CLI parameters. However, when executing this from within another application you need to either present the user with a terminal window (not pretty) or scrape the output and represent it. I also found that you can execute the binary contained in the Mac VPNClient.app application to script the Cisco GUI. This is the approach I'm using for now, but I really was hoping to use their library to control the whole user experience.

Thanks again for your help. At this point I'm assuming Cisco is not prepared to expose the programming API (despite references to the contrary on some of the Easy VPN Client marketing collateral).

The marketing guys are not always in sync with the techies :)

Anyway I'm sorry I could not help more.

Regards

Farrukh

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: