Created
September 17, 2014 01:40
-
-
Save vsefer/52355d1f0b868274847a to your computer and use it in GitHub Desktop.
Firewall config for OpenWrt to tunnel all traffic to VPN with OpenVPN
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
iptables -I OUTPUT -o tun+ -j ACCEPT | |
iptables -I INPUT -i tun+ -m state --state ESTABLISHED,RELATED -j ACCEPT | |
iptables -I FORWARD -o tun+ -j ACCEPT | |
iptables -I FORWARD -i tun+ -m state --state ESTABLISHED,RELATED -j ACCEPT | |
iptables -t nat -I POSTROUTING -o tun+ -j MASQUERADE |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment