17
0
nu-vpn-proxy/openconnect_command-ssh.sh
Benjamin Mako Hill c3af198d87 updated the proxy code to make it work based on other bitrot
- hipreport: updated the client version to match new globalconnect code
- hipreport: update linux kernel version to something more modern
- disable ESP and IPv6 which seem to be working poorly
- change code in ssh wrapper for no ESP
2025-03-09 23:13:18 -07:00

16 lines
650 B
Bash
Executable File

#!/bin/bash -x
OS="linux"
LOG_FILE=/tmp/nu-globalprotect-saml.log
PID_FILE=/tmp/nu-vpn-openconnect.pid
exec > $LOG_FILE
# change to the vpn file directory
cd ~/bin/nu-vpn-proxy
## do the authentication
eval $( ./gp-saml-gui.py -v --gateway --clientos=Linux vpn-connect2.northwestern.edu )
echo "${COOKIE}" | /usr/sbin/openconnect --protocol=gp '--useragent=PAN GlobalProtect' --user="${USER}" --os="${OS}" --usergroup=gateway:prelogin-cookie --passwd-on-stdin vpn-connect2.northwestern.edu --csd-wrapper="hipreport-modified.sh" --reconnect-timeout 60 --script-tun --script "ocproxy -D 9052" -b --disable-ipv6 --no-dtls --pid-file "${PID_FILE}"