Skip to content

Instantly share code, notes, and snippets.

@airlanggacahya
Created December 11, 2015 05:48
Show Gist options
  • Save airlanggacahya/e64d97133ea9db27524e to your computer and use it in GitHub Desktop.
Save airlanggacahya/e64d97133ea9db27524e to your computer and use it in GitHub Desktop.
Nat Iptables
sudo iptables --table nat --append POSTROUTING --out-interface usb0 -j MASQUERADE
sudo iptables --append FORWARD --in-interface eth0 -j ACCEPT
echo 1 | sudo tee /proc/sys/net/ipv4/ip_forward
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment