Skip to content

Instantly share code, notes, and snippets.

@srossross
Last active December 19, 2015 05:09
Show Gist options
  • Save srossross/5901711 to your computer and use it in GitHub Desktop.
Save srossross/5901711 to your computer and use it in GitHub Desktop.
IP Table eedirect
sudo iptables -t nat -F
sudo iptables -t nat -A OUTPUT -d localhost -p tcp --dport 80 -j REDIRECT --to-ports 8080
sudo iptables -t nat -I PREROUTING -p tcp --dport 80 -j REDIRECT --to-port 8080
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment