Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Does a Server need a local firewall?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
KWhat
l33t
l33t


Joined: 04 Sep 2005
Posts: 660
Location: Los Angeles

PostPosted: Fri Dec 01, 2006 5:14 pm    Post subject: Does a Server need a local firewall? Reply with quote

I have some what of a general question concerning server security.

I recently setup a gentoo server to replace a redhat server we had due to redhats licencing requirements and the fact that gentoo is 100x easier to manage.

The question is, does this server need a local firewall similar to the redhat setup? It is a fairly simple web server with mysql, samba, etc. It is accessable both internally and externally, and it is behind a firewall externally. I dont really see any reason to have a local firewall on the box but then again I am not a sys admin. Also if i really should have a firewall inplace is their a nice guide somewhere that can walk me threw the iptables config? I have setup iptabes in the past for routers however never for a webserver.

Thanks in advance.
Back to top
View user's profile Send private message
nixnut
Bodhisattva
Bodhisattva


Joined: 09 Apr 2004
Posts: 10974
Location: the dutch mountains

PostPosted: Fri Dec 01, 2006 5:40 pm    Post subject: Reply with quote

Quote:
The question is, does this server need a local firewall

Only you can answer that. If you have analysed the risks and your conclusion is that you don't see the need then there's your answer. On the other hand, there are so many scripts out there to generate firewall rules for a webserver, that the effort usually is so low that you'd need very good reasons not to setup a firewall.
Take a look in /usr/portage/net-firewall/
_________________
Please add [solved] to the initial post's subject line if you feel your problem is resolved. Help answer the unanswered

talk is cheap. supply exceeds demand
Back to top
View user's profile Send private message
GNUtoo
Veteran
Veteran


Joined: 05 May 2005
Posts: 1919

PostPosted: Fri Dec 01, 2006 8:33 pm    Post subject: Reply with quote

mabe the question would be...would i be more secure over a firewall

you seems to have samba shares so you could or add your local machines in your firewall configuration or edit smb.conf for the ip(do the same for ssh unless you want to be able to acess ssh from anywere)
also have strong identification for ssh
scanning the whole internet for open ssh port take one day with 500 compromised machines
avoid password or use something like denyhosts because you will have people or machine trying to gain acess to your server trough ssh

a firewall is useless for protecting external services because the ports need to be open in order to work correctly for evrybody
but maybe for protecting internal services it could be a good thing if they don't have a config file that can deny access to the outside world like smb.conf or sshd_config
you could also set-up an IDS like snort

by the way wich gentoo did you choose?
hardened gentoo or the normal one?

be carefull i am not a sysadmin so i have no experience of the real world

by the way firewall may be able to control the acess of the machines based on a lot more caracteristics than simply the ip(like the sshd_config or the smb.conf does),like the aplication used,the mac adress or the operating system(see NuFW for that)

you could also look for tcp wrapper
http://en.wikipedia.org/wiki/Tcp_wrapper
# cat /usr/portage/profiles/use.desc | grep tcpd
tcpd - Adds support for TCP wrappers

roughly use tcpwrapper or modify the config files(remember that an ip can easely be changed) in order to protect your ssh from your local network...you can also disable ssh if you have physical acess to the machine

the problem is also that mac adress can also easely be changed
you also have identification possiblities for a network such as radius and NuFw(be carefull there is 2 windows client and one is not free as in price)

do you use wireless?
have you physical acess to your server
can the employee acess the server?(the case of the server must be secure and the console should be locked)
do you need to acess ssh from a remote location?
even the keyboard is a risk...someone could buy an identical keyboard and remplace your keyboard with one that has a keylogger...(so ssh is more secure)
security is a hard task...
Back to top
View user's profile Send private message
KWhat
l33t
l33t


Joined: 04 Sep 2005
Posts: 660
Location: Los Angeles

PostPosted: Fri Dec 01, 2006 10:03 pm    Post subject: Reply with quote

The machine is protected by the general firewall so internal access is limited and external access is denied for things like ssh and smb so im not terribly concerned. Also the serivices that are running are going to be availabe to everyone internally such as apache and mysql. I dont think the firewall would hurt although its one more pain in my ass. FYI I am using the normal gentoo install not the hardened one.
Back to top
View user's profile Send private message
GNUtoo
Veteran
Veteran


Joined: 05 May 2005
Posts: 1919

PostPosted: Sat Dec 02, 2006 10:12 pm    Post subject: Reply with quote

rhel had selinux... the normal gentoo doesn't have it
if you want to deny acess from the internal network for ssh in the case you have some employree that are also hackers...lol you can install a firewall or use the config files or use tcp wrapper
if you have wireless acess you should do it
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum