March 8th, 2002, 09:22 AM
Bastille-Linux and iptables blocking httpd?
I have run into a problem while configuring my apache webserver on linux.. I can not seem to get my webserver past my firewall. With the help of those on irc.antionline.com, I created these rules for iptables, but they did not work.
/sbin/iptables -A INPUT -p tcp -i ppp0 --dport 80 -j ACCEPT # for www
/sbin/iptables -A INPUT -i eth0 -p TCP -s 0/0 --dport 80
-j LOG --log-prefix "IPTABLES www IN"
So just curious if my webserver would work at all, I decided to turn off bastille-linux and iptables using:
service bastille-firewall stop
service iptables stop
After this, many of my ports were opened up however port 80 wasnt one of them and remained stealth according to the port scan at grc.com. Not wanting to be vulnerable for too long I turned all of my firewalls back on and scanned again. All of my ports remained stealth except port 443. While trying to protect that port I added a rule to iptables that looks like this:
/sbin/iptables -A INPUT -s 0/0 -d 0/0 -p UDP --dport 443
This did not work however. I was able to get the response that this port was closed by turning off apache, but this would be counterproductive. Am I missing something here. Im not embarrassed to be made a fool of as long as I find an answer. What is blocking port 80? Why cant I protect port 443? All help is appreciated.