steps to hardening linux server connected in public network

We having one internet leased line. we going to use that leased line in our proxy server (squid). for internet access we have assigned public IP to our proxy server. so we need to harden our Linux server security.

OS: Ubuntu server 9.10

Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Some basics:

Keep the root from being able to SSH into the box.  Ubuntu has that disabled by default and you should keep it that way.

Use complex passwords for your access accounts.  The longer the better and mix in capitals, numbers, and a special character.  

Use IPTables and restrict access into the host to only those ports you need.   Deny all else (make sure you keep your SSH access available though).

Use FailtoBan to set a timeout period for failed ssh attempts or some other mechanism to stop constant failed logon attempts.  

Uninstall and remove any services that you don't need/use.  

Always a good idea to keep patching up to date for security issues.  


Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Are you married to Ubuntu? You might want to go with the debian netinstall. It's a very minimal install, so you're attack surface is going to be small. This way you only install the packages you need. You won't have to worry about shutting off services you're not using, becuase most of them won't be installed at all. I have a full Debian install for my desktop, and a minimal install for my servers. Whenver I read of new debian bugs, I update both. My desktop always needs updates, the servers rarely do.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Anti-Virus Apps

From novice to tech pro — start learning today.