Skip to content

Instantly share code, notes, and snippets.

@rjmacarthy
Created November 20, 2018 16:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rjmacarthy/328d3dd3c22ffd59088d1a9df29ef3b4 to your computer and use it in GitHub Desktop.
Save rjmacarthy/328d3dd3c22ffd59088d1a9df29ef3b4 to your computer and use it in GitHub Desktop.
#Connect
#/bin/bash
sudo ipsec up vpnname
echo "c vpnname" >/var/run/xl2tpd/l2tp-control
sleep 8
route add <x.x.x.x remote> gw 192.168.0.1
route add default dev ppp0
#Disconnect
#/bin/bash
echo "d vpnname" > /var/run/xl2tpd/l2tp-control
sudo ipsec down vpnname
#RDP
#/bin/bash
xfreerdp /multimon /u:user.name /p:password /v:x.x.x.x
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment