russdill / juniper-vpn-py

Python Juniper VPN Authenticator
GNU Lesser General Public License v2.1
103 stars 80 forks source link

force python2, add basic matrixcard support #22

Open mindrunner opened 7 years ago

mindrunner commented 7 years ago

Main reason for this pull request is extended 2-Factor support. My organization uses matrixcards for auth. Server gives me an index and I have to enter the key. This patch enables parsing the webform and shows the matrixcard index on CLI. No error checking yet, nothing. Works for me, but dont know about any other setups out there. Happy to improve if needed for getting this upstream. Furthermore:

some ssl-context stuff i dont understand from: https://github.com/dnschneid/crouton/wiki/Juniper-Junos-Pulse-VPN-with-OpenConnect

python2 in shebang, cus script fails when running on a python3 default system.

mindrunner commented 7 years ago

Added Patch from @jlinton to automatically disconnect existing/stale connections.

johnou commented 7 years ago

@mindrunner if you don't have time I am happy to split this up into three pull requests to Russ can pull it in, let me know.

mindrunner commented 7 years ago

I am not (or barely) using this at the moment and Pulse is end of life in my company in favour of a absolutely non working Citrix Netscaler Setup... Feel free to make whatever you like to my code and get it upstream!