Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I remember a time when Unix passwords (or was it usernames) could be no longer than 8 or 16 characters. Even nowadays, the password box displayed by login managers is relatively narrow, although one can type past its edge. I would like to know, are there currently any limits to the length of a password one may enter in a password box under Linux?

Thanks,

John Goche

share|improve this question

1 Answer 1

up vote 2 down vote accepted

It depends on what you're using, but most modern distros have moved to something other than stock crypt for passwords and can go to much longer lengths. It is still somewhat distro-dependent though.

  • Blowfish-backed systems can do 60 or 72 characters, and probably longer
  • MD5-backed systems can to that or more
  • SHA1-backed systems aren't that common but do go greatly past 8-char
  • SHA2-backed systems are very new and have even fewer restrictions

What's unclear to me is the impact of 2-byte and 4-byte character-sets on these limits.

Generally, if the system was build in the last 3 or so years it can take longer than 8 characters.

share|improve this answer
    
Thanks. Yes, I could not find an exact value under help.ubuntu.com/8.04/serverguide/user-management.html but at least the password I entered which is relatively long, seems to have all its characters accepted (if I type less characters then the password is not recognized). On older systems, password characters past the 8th character could be anything and the password would be accepted anyways. Very bad! –  John Goche Jul 22 '12 at 14:30

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.