firewall3: Make IPv6 ULA-Border generation dynamic
[openwrt/openwrt.git] / package / network / config / firewall3 / files / ipv6-ula-border.sh
1 #!/bin/sh
2 ULA_PREFIX=$(uci -q get network.globals.ula_prefix)
3 [ -n "$ULA_PREFIX" ] || exit 0
4
5 ip6tables -I delegate_forward -s $ULA_PREFIX -m comment --comment "Enforce ULA-Border" -j zone_wan_dest_REJECT
6 ip6tables -I delegate_forward -d $ULA_PREFIX -m comment --comment "Enforce ULA-Border" -j zone_wan_dest_REJECT