Skip to content

Instantly share code, notes, and snippets.

@martian0x80
Last active December 24, 2024 14:58
Show Gist options
  • Save martian0x80/4dc1d15b011df647a68c4e63566e731d to your computer and use it in GitHub Desktop.
Save martian0x80/4dc1d15b011df647a68c4e63566e731d to your computer and use it in GitHub Desktop.
iptables forward port 80
# enable forwarding for kernel
#vim /etc/sysctl.conf
#sudo sysctl --system
iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-port xxxx
apt-get install iptables-persistent
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment