Files
firezone/rust/docker-init.sh
Gabi b563c7ad5a connlib: fix ipv6 (#1855)
Fixes some of the ipv6 handling.

Making this PR I also realized we need to update checksums on UDP and
TCP too, since we're mangling packets.
2023-08-04 03:17:35 +00:00

11 lines
347 B
Bash
Executable File

#!/bin/sh
if [ $ENABLE_MASQUERADE = "1" ]; then
IFACE="utun"
iptables -A FORWARD -i $IFACE -j ACCEPT
iptables -A FORWARD -o $IFACE -j ACCEPT
iptables -t nat -A POSTROUTING -o eth+ -j MASQUERADE
ip6tables -A FORWARD -i $IFACE -j ACCEPT
ip6tables -A FORWARD -o $IFACE -j ACCEPT
ip6tables -t nat -A POSTROUTING -o eth+ -j MASQUERADE
fi