Linux - SecurityThis forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
If you have accounts with common usernames and weak passwords, then it is easy to gain access by guessing. If you have strong passwords, it is very difficult to guess the password by brute force. I suggest you disallow root login via SSH, since root is often attacked, and root access can be otherwise gained after login to another account. For more security, you can disable password logins and instead use public keys (much more secure) to login from trusted computers.
(1) If you don't have a clearly-defined need for ssh or any other service, turn the service off until you do.
(2) Functionally, ssh is still "a shell", and if you allow anyone to connect to it and demand from them no more than a simple username/password (as is the default), it's just as good to them as if they were using rsh or had walked into your office wearing an invisibility cloak.
(3) If you intend to use ssh to allow yourself remote access to your machine, always set it up to use digital certificates as the primary means of authentication. The documentation is plentiful and it's easy to do. Now, in order to even attempt to connect, the user is required to possess a valid certificate... which should be password protected. Users who cannot present that "identification badge" are turned away, having been given no opportunity to enter a password of any sort.
(3a) Digital certificates, used in this way, do not cost money: you generate them and sign them yourself.
(4) No one realistically breaks into a cryptosystem by brute-forcing the key. They attack the key-management system... or the lack thereof. Notice that, while SSH encrypts the traffic that it sends, it (by default) allows anyone, anywhere to "have a try at a user/pass," and if they guess right it lets them right in! But, if you use digital certificates, the strong cryptography is used twice: not only to encrypt the traffic, as before, but to provide an impregnable and irrefutable form of user authentication.
I wrote a little script that will generate the key for you then upload the key to the server you want just hit enter twice when it ask for a password. Once that is done it will ask for the password only for the first time you log in and after that it should not ask for a password. You may find this useful: