nixCraft Poll

Topics

Howto: Protect account against a password cracking attack

Posted by Vivek Gite [Last updated: August 28, 2006]

Usually most Linux and UNIX system use a password for authentication purpose i.e. to verify your identity.

If your password is obtained using cracking attack, your data, computer, and network comes under attack. Therefore, you must protect your self from a password cracking attack.

=> Use shadow and Message-Digest Algorithm (MD5) passwords.

=> Make sure root user only owns your /etc/shadow file (you can write protect this file with chattr command)

=> Use a strong password. Attacker will try both ssh or ftp login using brute-force technique. Try to avoid following type of password:

=> A good password includes

Fortunately, Linux and UNIX allow you to setup tight password policies:

Stay tuned, for more information. I will write about how to implement these password policies.

Want to stay up to date with the latest Linux tips, news and announcements? Subscribe to our free e-mail newsletter or RSS feed to get all updates. You can Email this page to a friend.

You may also be interested in other helpful articles:

Discussion on This Article:

  1. amnju Says:

    hi..
    can u reply to my mail how you can decrypt passwords in the /etc/shadow file…..

  2. nixcraft Says:

    You cannot decrypt passwords in the /etc/shadow. You can just encrypt password and compare with /etc/shadow version using API

  3. Harka Says:

    > Do not write down password

    I disagree with that. In this day and age there’s almost no way to NOT write down passwords.
    I see it this way: when you do write it down (assuming, of course, you store everything in a reasonably secure place…like your wallet) it makes it much easier to choose GOOD passwords, as opposed to lousy one’s just so you can remember them…

    Btw., most authentication routines use 128-bit encryption/hashing, incl. Linux passwords (MD5). In order to make your passwords at least as strong as the underlying algorithm you need at least 28 *randomly chosen* characters, if you were only picking from the 26 lower-case english alphabet. Picked from upper and lower-case (52 chars) you’d need 23 randomly chosen characters and if you add the 0-9 numbers into the mix (62 chars), you’d still need at least 22 random characters out of that.
    Now you know how weak your password really is compared to the technical implementation of it :-)

Leave a Reply

We encourage your comments, and suggestions. But please stay on topic, be polite, and avoid spam. Thank you very much for stopping by our site!

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

*
To prove you're a person (not a spam script), type the security word shown in the picture. Click on the picture to hear an audio file of the word.
Click to hear an audio file of the anti-spam word

Copyright © 2004-2008 nixCraft. All rights reserved - TOS/Disclaimer - Privacy policy - Sitemap - Powered by Open source software.