Skip to content

Instantly share code, notes, and snippets.

@pupboss
Last active April 1, 2021 10:42
Show Gist options
  • Star 5 You must be signed in to star a gist
  • Fork 3 You must be signed in to fork a gist
  • Save pupboss/581fc9eb5c4654637837303eef33e3c3 to your computer and use it in GitHub Desktop.
Save pupboss/581fc9eb5c4654637837303eef33e3c3 to your computer and use it in GitHub Desktop.
Shell script for NTU campus vpn connection
#!/usr/bin/expect
set timeout 10
spawn sudo openconnect ntuvpn.ntu.edu.sg --prot=pulse
expect "Password:"
send "ACCOUNTPWD\n"
expect "Realm"
send "Student\n"
expect "Username:"
send "UNAME\n"
expect "Password:"
send "PWD\n"
interact
@codieboomboom
Copy link

Thanks so much, this is awesome!

@pupboss
Copy link
Author

pupboss commented Dec 2, 2020

Thanks so much, this is awesome!

My pleasure

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment