Skip to content

Instantly share code, notes, and snippets.

@gerry gerry/

Created Aug 16, 2016
What would you like to do?
#!/bin/sh -e
LOCAL_NET=$(ip -o -f inet addr show $DEFAULT_IFACE | awk '{print $4}')
ufw --force reset
ufw default deny outgoing
ufw default deny incoming
ufw allow out on tun0 from any to any
ufw allow in on tun0 from any to any
for IP in $(echo $HOST_IPS | tr , \\n); do
#ufw allow in from $IP to any
ufw allow out from any to $IP
#ufw allow from $LOCAL_NET
ufw allow out 1198/udp
ufw enable
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.