summarylogtreecommitdiffstats
path: root/ip-down.sh
blob: 66b5e0ba3ae31d9497d3a082d074e4fefac369b6 (plain)
1
2
3
4
5
6
7
8
9
#!/usr/bin/bash

OLD_GATEGAY=$(cat /run/vpn-old-gateway)

[[ -n "$OLD_GATEGAY" ]] || exit

for ip_range in $(cat /etc/china-ip-skip-vpn/china-ip-list.txt); do
  ip route del $ip_range via $OLD_GATEGAY
done