Users

All Posts (1)

avatar

kmpoppe

Cisco AnyConnect functionality?

avatar
avatar
avatar
avatar

Hi jskuby,


I have experimented with the anyconnect commandline tool but was always faced with the problem, that i have to enter the password myself. Since it's no big deal, i'll post the crappy batch i wrote:


@"c:\programme\Cisco\Cisco AnyConnect VPN Client\vpncli" disconnect

@set vpncliuname=

@if "%COMPUTERNAME%" == "..." set vpncliuname=xxx

@if "%COMPUTERNAME%" == "..." set vpncliuname=yyy

@if "%1" == "connect" echo %vpncliuname%|"c:\programme\Cisco\Cisco AnyConnect VPN Client\vpncli" connect %2

@set vpncliuname=

(Where %1 is connect oder disconnect and %2 is the dns-name of the remote vpn device)


for obvious reasons the login names are blanked out ;-)


Now, echoing the username and piping it to the vpncli works just fine, entering the password is to be done on my own since i cannot echo 2 lines (with CRLF) and pipe it to the vpncli for it to read both parameters.


If you have an addon in the beat phase i would be more than happy to test it! Just PM' me the download link!


Thank you for bringing this up!

1 - 1 of 1 items