Iptables string
- by Mr. BeatMasta
I have an iptables rule like this:
iptables -t nat -I PREROUTING -p tcp --dport 80 -s 192.168.1.2 -j DNAT --to-destination 192.168.1.1:80
it works perfectly.. but I want to redirect only for one URL like this:
iptables -t nat -I PREROUTING -p tcp --dport 80 -s 192.168.1.2 -m string --string "google.com" -j DNAT --to-destination 192.168.1.1:80
which does not work in any way... please help me with this