Skip to content

Instantly share code, notes, and snippets.

@alastairhm
Created April 18, 2018 20:35
Show Gist options
  • Save alastairhm/b2de205f411dfc3fc72967658d231b71 to your computer and use it in GitHub Desktop.
Save alastairhm/b2de205f411dfc3fc72967658d231b71 to your computer and use it in GitHub Desktop.
Redirect 443 to higher port using IP tables.
iptables -t nat -A PREROUTING -p tcp --dport 443 -j REDIRECT --to-port 18079
iptables -t nat -I OUTPUT -p tcp -d 127.0.0.1 --dport 443 -j REDIRECT --to-ports 18079
iptables-save
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment