next up previous
Next: Useful Programs Up: Other Administrative Tasks Previous: Other Administrative Tasks

Securing a New Box

A default GNU/Linux installation is a system cracker's gold mine. Red Hat and other distributions based on it (including Mandrake) install and start about a dozen services that perform tasks ranging from sending and receiving email ( sendmail), to serving files ( wu-ftpd) and web pages, allowing remote computers to use your printer ( LPRng), and responding to general requests for network information ( named and rpc-statd). Unless you really know what you're doing, you should use linuxconf to turn off all of these services. If you're going to run any of them, look for the most up-to-date patched versions on the Internet; do not run the versions on the distribution CD! In addition, you should disable httpd, xntpd, and linuxconf itself (as a service; you can still run it from your console). It is useful and relatively safe to run crond and syslogd, though again you should be sure to get the latest patches for each. You may wish to install ssh, a program that allows you to connect to remote computers securely, and allows others to connect to your computer. If you must run a mail server, seriously consider qmail instead of sendmail.

Once you have decided which services you want to run and have installed the latest versions, it is a good idea to firewall your machine. The Linux kernel has firewalling capabilities written into it, so you only need some fairly simple text files to start firewalling. Firewalls are a topic for an entire book, but you can learn more about the kernel utilities ipchains and iptables on the web.

The Honeynet Project has determined that a default Red Hat 6.2 computer lasts an average of 72 hours on the Internet before it is ``root compromised'', meaning a remote attacker has root control of the machine. Unless you turn off vulnerable services, or are behind a firewall at your organization, your computer will suffer the same fate. It is very difficult to recover from a root compromise, short of a complete re-installation of the operating system and total loss of user data. Secure your machine immediately if you're going to put it on the Internet.


next up previous
Next: Useful Programs Up: Other Administrative Tasks Previous: Other Administrative Tasks
hwang
2001-10-31