Redirect outgoing http requests with IPtables
Hello.
I have searched along google but this thing looks really chaotic.
I just want to redirect some outgoing urls (like torrent sites for example) to a default page, for example 127.0.0.1/deny.html I would like to do it via iptables, no proxy servers or software. Is that possible?
I have managed to make all outgoing connections to one ip to be dropped by iptables with the command:
ipatbles -A OUTPUT -d [IP] -j DROP
But when i type a url instead of [IP], the iptables converts to ip automatically.
Also i coundn't get redirection working.
Thanks,
Dennis
|