Skip to content

Instantly share code, notes, and snippets.

@jamesmacwhite
jamesmacwhite / README.md
Last active October 27, 2024 21:27
An example and overview of mwan3 IPv6 configuration with NAT6 (sorry anti IPv6 NAT people)

Deploying mwan3 with IPv6 (using NAT6)

I'm a user of mwan3 and contribute to its development in a small way by mainly providing feedback with my multi WAN setup and maintaining the beast of it's documentation on the OpenWrt wiki (feedback and contributors welcome).

This setup ultimately requires the use of a NAT6 firewall script. NAT6 is currently broke with fw3 and LuCI, so this is an important helper script to workaround this current limitation.

The NAT6 configuration requirements are explained in more detail on the OpenWrt wiki.

This gist is aims to document my configuration for others.

@0ff
0ff / iptables.sh
Created March 27, 2016 00:06
iptables for OpenWrt to unlock netflix using getflix.com.au
YOUR_GETFLIX_SERVER=1.2.3.4 # see https://www.getflix.com.au/setup/overview
YOUR_ATV_MAC=AA:BB:CC:DD:EE # see ”DHCP and DNS" in OpenWrt
iptables -A zone_lan_forward ! -d $YOUR_GETFLIX_SERVER/32 -p tcp -m tcp --dport 53 -m mac --mac-source $YOUR_ATV_MAC -m comment --comment "restrict dns" -j zone_wan_dest_REJECT
iptables -A zone_lan_forward ! -d $YOUR_GETFLIX_SERVER/32 -p udp -m udp --dport 53 -m mac --mac-source $YOUR_ATV_MAC -m comment --comment "restrict dns" -j zone_wan_dest_REJECT