Update README

This commit is contained in:
Reza Behzadan 2024-08-06 23:01:40 +03:30
parent 10370ebb3d
commit b354831f4c

View File

@ -3,10 +3,14 @@
### Sample `iptables` rules ### Sample `iptables` rules
``` ```
sudo iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j REDIRECT --to-port 8443 # IPv4
sudo iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j REDIRECT --to-port 8443 sudo iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-port 8443
sudo ip6tables -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j REDIRECT --to-port 8443 sudo iptables -t nat -A PREROUTING -p tcp --dport 443 -j REDIRECT --to-port 8443
sudo ip6tables -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j REDIRECT --to-port 8443
# IPv6
sudo ip6tables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-port 8443
sudo ip6tables -t nat -A PREROUTING -p tcp --dport 443 -j REDIRECT --to-port 8443
``` ```
### Sample `dnsmasq` config ### Sample `dnsmasq` config
@ -14,6 +18,9 @@ sudo ip6tables -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j REDIRECT --to-
no-dhcp-interface= no-dhcp-interface=
enable-tftp=false enable-tftp=false
listen-address=0.0.0.0
interface=eth0
address=/#/185.218.139.254 address=/#/185.218.139.254
``` ```