Suggestions on Firewall settings on CENTOS 5.6 64-bit
CentOS 5.6 - 64-bit
Apache web server with My Sql
The web application and My Sql servers are installed on different servers for load sharing and are connected to together and is in the same data center.
Below is the current firewall configuration, would appreciate if you could tell me if these settings are sufficient to ensure my servers are secure.
iptables -L
Chain INPUT (policy ACCEPT)
target prot opt source destination
RH-Firewall-1-INPUT all – anywhere anywhere
Chain FORWARD (policy ACCEPT)
target prot opt source destination
RH-Firewall-1-INPUT all -- anywhere anywhere
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
Chain RH-Firewall-1-INPUT (2 references)
target prot opt source destination
ACCEPT all -- anywhere anywhere
ACCEPT all -- anywhere anywhere
ACCEPT icmp -- anywhere anywhere icmp any
ACCEPT esp -- anywhere anywhere
ACCEPT ah -- anywhere anywhere
ACCEPT udp -- anywhere 224.0.0.251 udp dpt:mdns
ACCEPT udp -- anywhere anywhere udp dpt:ipp
ACCEPT tcp -- anywhere anywhere tcp dpt:ipp
ACCEPT all -- anywhere anywhere state RELATED,ESTABLISHED
ACCEPT tcp -- anywhere anywhere state NEW tcp dpt:ssh
ACCEPT tcp -- anywhere anywhere state NEW tcp dpt:http
ACCEPT tcp -- anywhere anywhere state NEW tcp dpt:ftp
ACCEPT tcp -- anywhere anywhere state NEW tcp dpt:https
REJECT all -- anywhere anywhere reject-with icmp-host-prohibited
Thanks,
Avinash
9 Replies
Anyway, from the looks of things, you're allowing Internet Printing ProtocolmDNS
I hope removing FTP, IP and mDNS won't disturb access to the website?
Thanks.
@hoopycat:
No, firewalls are not sufficient to ensure a system is secure. If anything is going to get you, it's probably going to be coming in via port 80.
Anyway, from the looks of things, you're allowing
as well as FTP. Both of those are not generally things you'd want to run on a remote server. Internet Printing Protocolis also of limited utility on a public cloud. Those are the three rules I'd probably remove from the RH-Firewall-1-INPUT chain. mDNS
@vonskippy:
CentOS 5.
8 has been out since March 2012, I'd worry as much about keeping your security patches up-to-date as well as pruning your IPTABLES.
@Avinash.Rao:
Even SSL is configured to work through port 80.
Wait what? Why would HTTPS be on anything but port 443?
@mnordhoff:
@Avinash.Rao:Even SSL is configured to work through port 80.
Wait what? Why would HTTPS be on anything but port 443?
Is there anything that I need to do?
Thanks for your time.
@hoopycat:
mDNS and IPP are not used for web hosting and are mostly "LAN" protocols used within controlled environments. FTP is also not generally used for web hosting, although it is a legacy protocol used for file transfer in many places it shouldn't be.