If you can use iptables on the firewall, this should work:
iptables -t nat -I PREROUTING -i <internal-interface> -d <public-ip-of-fw> -j DNAT --to <internal-address-of-web-server>
This will NAT all traffic from the internal network to the public ip of the firewall to the webserver. You can test this by pinging the public address of your firewall from the local network.
Regards, Frank
Thanks everyone, there are three solutions that work for me:
1 - Fast and dirty.
Add local used hostname entries to /etc/hosts file and let everyone use squid
internal or route port 80 with iptables to squid. Squid does the first lookup
in the /etc/hosts file:
iptables -t nat -A PREROUTING -i <internal iface> -p tcp --dport 80 -j REDIRECT
--to-port 3128
2 - DNS. Keep a copy of the used domains in my own DNS to point to the local IP of the server.
3 - IP tables, my preferred way. The most elegant way, works with one iptables line, and no maintenance. iptables -t nat -I PREROUTING -i <internal-interface> -d <public ip> -j DNAT --to <internal ip>
Frank, thanks for the solution!
_______________________________________________ tsl-discuss mailing list [email protected] http://lists.trustix.org/mailman/listinfo/tsl-discuss
