Archive for the 'Unix' Category

Shortest masquerade config

Voici la commande la plus courte et simple afin de faire du masquerading sous Linux

# this will masquerade all packet to ppp0
iptables -F; iptables -t nat -F; iptables -t mangle -F
iptables -t nat -A POSTROUTING -o ppp0-j MASQUERADE
echo 1 > /proc/sys/net/ipv4/ip_forward

admin September 18th, 2003