Bash script for quickly connecting to VPN Gate free VPN

adnan360 0f688ad9e8 Add support for extra openvpn CLI parameters 3 jaren geleden
data ffc9cc774a Initial commit 3 jaren geleden
inc 2e5a640449 Apply fixes for OpenBSD 3 jaren geleden
run 77615ed17e Initial implementation of scripts 3 jaren geleden
.gitignore 77615ed17e Initial implementation of scripts 3 jaren geleden
LICENSE 631488f6bf Initial commit 3 jaren geleden
README.md 77615ed17e Initial implementation of scripts 3 jaren geleden
config.sample.sh 0f688ad9e8 Add support for extra openvpn CLI parameters 3 jaren geleden
connect.sh 0f688ad9e8 Add support for extra openvpn CLI parameters 3 jaren geleden
fetch.sh 2e5a640449 Apply fixes for OpenBSD 3 jaren geleden

README.md

gatekeeper

Bash script for quickly connecting to VPN Gate's free VPN

Plain, simple script to connect to the free VPN service VPN Gate. It works with basic tools which are commonly available on any system. Doesn't even require network-manager.

Usage

git clone --depth 1 https://notabug.org/adnan360/gatekeeper.git
cd gatekeeper
./fetch.sh
./connect.sh

Press Ctrl+C when you want to disconnect.

Configure

Configuration is optional.

cp -i config.sample.sh config.sh
$EDITOR config.sh

Scripts

You can run custom scripts when vpn is connected or disconnected. This is handy for customization, firewall tightening etc. Possibilities are endless. Create up.sh and down.sh right inside data directory, make them executable.

data/up.sh

#!/usr/bin/env bash
echo 'UPPP!!!'

data/down.sh

#!/usr/bin/env bash
echo 'DOWNNN!!!'

Now connect and disconnect to see if the above messages appear. You can use contents created inside run directory to use in these scripts if you need it.

  • vpn_device: stores the device through which VPN is connected. e.g. tun0
  • vpn_ip: stores the remote ip that is connected to.
  • vpn_port: stores the remote port that is connected to.

Requirements

  • bash
  • curl or wget
  • base64
  • openvpn

License

GPLv2