Skip to content

Instantly share code, notes, and snippets.

@top4ek
top4ek / 052-openvpn.sh
Last active February 14, 2023 01:32
My Zyxel Keenetic scripts
#!/bin/sh
[ "$table" != "filter" ] && exit 0
/opt/sbin/iptables -A FORWARD -i tun0 -s 10.8.0.0/24 -j ACCEPT
/opt/sbin/iptables -A FORWARD -m state --state ESTABLISHED,RELATED -j ACCEPT
/opt/sbin/iptables -t nat -I POSTROUTING -o ppp0 -s 10.8.0.0/24 -j MASQUERADE