https://github.com/alertua/cisco_vpn_connect
Cisco Anyconnect Command Line VPN Connection Script
https://github.com/alertua/cisco_vpn_connect
Last synced: 8 months ago
JSON representation
Cisco Anyconnect Command Line VPN Connection Script
- Host: GitHub
- URL: https://github.com/alertua/cisco_vpn_connect
- Owner: ALERTua
- Created: 2025-06-19T15:49:52.000Z (12 months ago)
- Default Branch: main
- Last Pushed: 2025-06-20T11:17:33.000Z (12 months ago)
- Last Synced: 2025-07-01T12:06:30.168Z (12 months ago)
- Language: PowerShell
- Size: 10.7 KB
- Stars: 2
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
[](https://stand-with-ukraine.pp.ua)
[](https://stand-with-ukraine.pp.ua)
[](https://stand-with-ukraine.pp.ua)
[](https://stand-with-ukraine.pp.ua)
Cisco AnyConnect Command Line VPN Connection Script
---------------------
Connect to Cisco AnyConnect VPN using the command line. Useful if placed in the Windows Startup folder.
### Usage
I. Create a new generic credential in Windows Credentials Manager
1. Start Menu
2. Credentials Manager
3. Windows Credentials
4. Generic Credentials
5. Add a generic credential
6. Credentials "Internet or network address": Any string, it will be used as Credentials Alias
7. Username: VPN Username
8. Password: VPN Password
9. Save
10. Don't forget to update the credentials record when you change your password.
II. Use the script to connect to VPN using the credentials alias
```powershell
powershell vpn_connect.ps1 "VPN URL" "Credentials Alias"
```
You can also fill in the arguments in `vpn_connect.cmd` and place a shortcut to it in the Windows Startup folder.
III. To get the connection status, you can execute `vpn_status.cmd`
IV. To disconnect, you can execute `vpn_disconnect.cmd`
### Caveats
- The script outputs your **PLAIN TEXT PASSWORD** to the console once.
- The connection is persistent, but the tray icon is not shown as in the GUI version.
- If you are disconnected for any reason, you'll still get the GUI dialog about the connection being lost.
Написав ChatGPT. Я лише переклав на рідну мову.