Advertisement
Guest User

NAT

a guest
Jul 6th, 2011
256
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.26 KB | None | 0 0
  1. #/bin/sh
  2. INET="eth0"
  3.  
  4. iptables -F INPUT
  5. iptables -F FORWARD
  6. iptables -F OUTPUT
  7.  
  8. iptables -P INPUT ACCEPT
  9. iptables -P OUTPUT ACCEPT
  10. iptables -P FORWARD ACCEPT
  11.  
  12. iptables -t nat -A POSTROUTING -o $INET -j MASQUERADE
  13.  
  14. echo "1" > /proc/sys/net/ipv4/ip_forward
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement