tcproxy/README.md
2024-03-04 04:08:04 +03:30

660 B

Sample iptables rules

sudo iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j REDIRECT --to-port 8443
sudo iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j REDIRECT --to-port 8443
sudo ip6tables -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j REDIRECT --to-port 8443
sudo ip6tables -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j REDIRECT --to-port 8443

Sample dnsmasq config

no-dhcp-interface=
enable-tftp=false

address=/#/185.218.139.254

Acknowledgements

(https://www.agwa.name/blog/post/writing_an_sni_proxy_in_go) (https://www.agwa.name/blog/post/writing_an_sni_proxy_in_go/media/sniproxy.go)