Password strength

From Wikipedia, the free encyclopedia

Password strength is the likelihood that a password can be guessed by an unauthorized person or computer. Passwords easily guessed are known as weak or vulnerable; passwords very difficult or impossible to guess are considered strong.

The terms weak and strong are relative and have meaning only with regard to specific password systems. The necessary quality of the password depends on how well the password system limits attempts to guess a user's password, whether by a person who knows the user well, or a computer trying millions of possibilities. In a cryptographic context, the terms can have considerable precision. For example, passwords generally are not suitable for use as encryption keys. But note that even a 'strong' password may still be stolen, tricked, or extorted from a user, collected from a keyboard logger, intercepted in transit, or otherwise discovered.

Contents

[edit] Weak passwords

A weak password is short, common, a system default, or that which could be rapidly guessed by executing a brute force attack using a subset of all possible passwords such as words in the dictionary, proper names, words based on the user name or common variations on these themes. Passwords easily guessed by acquaintances of the user, such as a birth date and pet's name, are also considered weak.

Examples of weak passwords include:

  • admin -- too easily guessed
  • 1234 -- too easily guessed
  • susan -- common personal name
  • password -- trivially guessed, used astonishingly often
  • p@$$\/\/0rd -- simple letter substitutions are pre-programmed into cracking tools.
  • rover -- common name for a pet, a dictionary word in any case
  • 12/3/75 -- date, possibly of personal importance
  • December12' -- Using the date of a forced password change is very common.
  • nbusr123 -- probably a user name, if so very easily guessed
  • asdf -- a sequence of adjacent letters on many keyboards

Studies of production computer systems have for decades consistently shown that about 40% of all user-chosen passwords are readily guessed.

Many users do not change the default password that comes with many computer security systems. Lists of default passwords are available on the Internet.[1]

A password might be guessable if a user chooses an easily-discovered piece of personal information as a password (such as a student ID number, a boy- or girlfriend's name, a birthday, a telephone number, or a license plate number). Personal data about individuals are now available from various sources, many on-line, and can often be obtained by someone using social engineering techniques, such as posing as an opinion surveyor.

A password is often vulnerable if it can be found in a list. Dictionaries in machine-readable form are available for many languages, and there exist lists of commonly-chosen passwords. In tests on live systems, dictionary attacks are so routinely successful that software implementing this kind of attack is available for many systems.

A too-short password, perhaps chosen for ease of typing, is vulnerable if an attacker can obtain the cryptographic hash of the password. Computers are now fast enough to try all alphabetic passwords shorter than 7 characters, for example.

Departing employees, programmers and systems administrators often know widely disclosed passwords that are rarely changed. Easily guessed passwords may enable expensive losses through mischief, fraud or revenge.

[edit] Strong passwords

A strong password is sufficiently long, random, or otherwise producible only by the user who chose it, that successfully guessing it will require too long a time. The length of time deemed to be too long will vary with the attacker, the attacker's resources, the ease with which a password can be tried, and the value of the password to the attacker. A student's password might not be worth more than a few seconds of computer time, whilst a password controlling access to a large bank's electronic money transfer system might be worth many weeks of computer time.

Examples of stronger passwords include:

  • t3wahSetyeT4, not a dictionary word, has both alpha and numeric characters
  • 4pRte!ai@3, not a dictionary word, has both cases of alpha, plus numeric, and punctuation characters
  • #3kLfN2x, same as preceding
  • MoOoOfIn245679, long, with both alpha cases and numeric characters
  • Convert_100£ to Euros!, Phrases can be long, memorable and contain an extended symbol to increase its strength.

These passwords are longer and use combinations of lower and upper case letters, digits, and symbols. The longer and the wider the variety of symbol choices, the more intensive the password cracking effort or well matched the Rainbow table must be to defeat the password; assuming that suitable password hashing and protection methods are in place.

Further, not using a single word makes password cracking word lists a less effective form of direct brute force attack. Note: some systems do not allow symbols like #, @ and ! in passwords and they may be hard to find on different keyboards. In such cases, adding another letter or number or two may offer equivalent security.

The above examples, having been published in this article as password examples, are no longer good choices; examples from publicly-accessible discussions about passwords are obviously good candidates for inclusion in a dictionary to be used for a dictionary attack. However, beware that even "strong" passwords (by this limited criterion), and especially human-chosen passwords, are not equivalent to a strong encryption key, and should not be used as such, if for no other reason than that they contain no unprintable characters. Passphrases and password-authenticated key agreement methods have been used to address this limitation.

Passwords can be found by using so called brute force password generators. In the simplest case, these are small programs that simply tries all possible combinations. A 3 GHz processor can generate approximately 3 million passwords a second. A password such as '4pRte!ai@3' is likely to be found after take approximately 9510 / 3000000 / 3600 / 24 / 365 = 632860 years, assuming purely random possible password generation.

However, certain weak password hashing methods can betray a password much more quickly by reducing the number of combinations needed or increasing the speed that guesses may be rejected to crack an otherwise "strong" password. Further, certain precomputed tables of such as rainbow tables can increase the cracking speed considerably.

A formula which calculates the number of possible passwords is: maximumCombinations = nrAvailableCharsPassswordLength. Using only the 26 lowercase letters and a password length of 6 characters the number of combinations is relativaly small: 267 = 8.03 billion combinations. This may appear large to some, but in a time when common computers can generate 3 million passwords a second, it will only take 45 minutes to find the password.

Passwords longer than 7 characters using non-dictionary words are therefore to be preferred in an attempt to use 'good' passwords. However, the majority of computer users don't observe such precautions, in part because they are hard to remember.

A simple example can be used to investigate the resistance of passwords to brute force search (see [2]). Experimenting with this program will make clear that a password such as apple is very easy to discover, since it can be found in less than 30 by an exceptionally simple approach.

[edit] Random passwords

The most secure passwords are long, random strings of characters, but such passwords are generally the most difficult to remember. For the same number of characters, a password is stronger if it includes a mix of upper and lower case letters, numbers and other symbols (when allowed). The difficulty in remembering such a password increases the chance that the user will write down the password, which makes it more vulnerable, to a different attack (finding the paper and copying the password) in this case. Whether this represents a net reduction in security depends on whether the primary threat to security is internal or external.

Forcing users to use system-created random passwords ensures the password will have no connection with that user and shouldn't be findable in any dictionary. Several operating systems have included such a feature. Many also includes password aging, requiring users to choose new passwords regularly (commonly after 30 or 45 days). While helpful from a security viewpoint, many users resent such measures, particularly in the absence of effective security awareness training. The imposition of strong random passwords may encourage users to write down their password, store them in a PDA or cellphone, share them with others against memory failure, etc thus increasing the risk of its loss.

Acceptance of random password use by people can work when some of the following trade offs are carefully used:

  • Create a training program. The initial advantages of random passwords need to be laid out for people. Also, updated training for those found to disclose passwords will be needed. The extra effort of memorizing a new random password is a natural incentive to discourage lax user behavior.
  • Reward users of random passwords by reducing the rate of forced password changes to periods longer than 3 months. Typically 4, 6 or 12 month forced password reset periods work. Spreading out the password change process may have an advantage to human memory processes.
  • Compensate for disclosed passwords by building a vigilant account closure process for departing users and/or a process to show each user a last login notification banner.
  • Automate a password reset system as a safety net for people. This will also reduce Helpdesk call volume concerning password resets. (Of course your mother's maiden name isn't a very good password, so you should try to make your reset system secure as well.)

[edit] Mnemonic passwords

Some users develop mnemonic phrases that generate random seeming passwords. For instance, use the first letter of each word. Another way to make "random" passwords more memorable is to use random words (see diceware) or syllables instead of randomly chosen letters.

Personal mnemonics are sometimes recommended. That is, things that are memorable to you, but not to others. For example, the password Iw21wIfvP, an otherwise difficult to remember string, derives from "I was 21 when I first visited Paris", possibly easily remembered (for non-Parisians). But, if your first experience of Paris was important to you, it may be possible to guess this password from a little research about you, and, if so, this would not be a sensible password choice.

Another is NYianc@US which derives from the phrase "New York is a nice city at the US", though it may run afoul of restrictions on allowed characters on some systems. Exclusion of punctuation and non-alphanumeric characters may be a practical issue as some keyboards will not have all such characters and some software will not accept some of these characters in a password. It is also a reduction in security, as the policy makes guessing passwords easier, an undesirable outcome. On the other hand, such a password is a considerable improvement on a child or pet's name, initials, birthday, mother's maiden name, or many of the choices made without such a requirement. Please avoid word choices, most language and jargon dictionaries have less than 100,000 words, a PC guessing at 3,000,000 combinations per second can check word lists very quickly. Ritualistic substitutions for letters such as are used in leet are often pre-programmed into password cracking software software.

[edit] Patterned passwords

Any pattern in a password makes guessing (automated or not) easier. As of October 2005, employees of the UK Government are advised to use passwords of the following form: consonant, vowel, consonant, consonant, vowel, consonant, number, number (for example pinray45). Apparently upper and lower case do not matter, and this form is called an Environ password. The pattern of alternated vowel and consonant has probably been suggested so that the result will be somewhat pronounceable; it is a considerable reduction in the "randomness" of the generated password and is a reduction in security as a result, as is the restriction to letters and numbers.

[edit] A Cautionary Tale

In large password files the awareness of password strength may be roughly measured by the time it takes to crack 50% of the password hashes present. With a large password file, using a standard Pentium 4 system, Microsoft password hashing techniques and an under-trained user group making password choices, it may be safely estimated that 50% of the password hashes will crack in less than 2 minutes. However, with careful attention to password strength advice, password choices can outlast the patience of a password cracking effort.

User Training versus a cracking time metric for large user base password files:

User training actions Metric: 50% password hashes cracked
No Training Time <= 2 minutes
Sporadic User Training Time <= 4 minutes
General User Training Time >= 45 minutes
Focused User Training Time >= 24 hours
Motivated User Population Time >= 1 week
Random Password Group Time >= 2 weeks
Contest Winners Time >= 1 month

Note: times are based on reports from authorized password cracking efforts that used John the Ripper, without a dictionary, on Microsoft LM Hashes, run on a Pentium 4, 2 GHz system. Only results from password files containing greater than 3,000 password hashes are included.

The following rough cut survey is provided as food for thought:

  • 50% of all password cracking efforts voluntarily terminate in less than 2 hours.
  • 50% of trained security professions voluntarily terminate password cracking efforts in less than 36 hours.

Pre-computed Rainbow tables represent a determined computing investment. The greater the range of keys included and the length in password places covered, the greater the number of combinations to compute, and the greater the expense of time or money to obtain them.

Factors to consider

  • Keyspace
  • Investment in Computer Time
  • Parallel computing team coordination
  • Raw patience of a determined computing effort
  • Predictive Accuracy
  • Encryption Type
  • Storage Space
  • Distribution or Purchase Costs

Rainbow Table Defenses

  • Exceeding the password length of commonly available tables.
  • Exceeding the keyspace of commonly available tables.
  • Avoiding the use or exceeding the useful length of old hashing methods.
  • Preventing the capture of password hashes.
  • Using salts.

[edit] Passwords weakened by hashing vulnerabilites

Knowning which password hashing methods are used to protect your password, can help you choose a more effective one. In this training example the effect of position in password selection is illustrated. Microsoft has updated its password hashing methods over time, but the LM hashing method often remains because of backward compatible features of newer Microsoft systems.

Training Samples to avoid.

Password Quality Notes
Crunchy Bad It is a word. 100,000 words can be tested in less than 0.03 seconds.
Crunchy! Bad The symbol "!" amounts to a second, single digit, password and will not last long.
CrunchyPretzel Bad "Pretzel" amounts to a second password, that is a word.

Why are these sample passwords at risk?

  • Each 7 places in a Microsoft LM password hash may be cracked separately.
  • These passwords show unfortunate placement problems in LM hashing protection.
Password Full Length Cracking Lengths First Half 1 2 3 4 5 6 7 Second Half 8 9 10 11 12 13 14
Crunchy 7 7 + 0 Crunchy C r u n c h y
Crunchy! 8 7 + 1 Crunchy C r u n c h y !  !
CrunchyPretzel 14 7 + 7 Crunchy C r u n c h y Pretzel P r e t z e l
  • LM hashing is only used by Microsoft for passwords of 14 places or less.
  • Longer passwords will not be subject to backward compatible hashing weakness.
  • By evading LM hashing, substantial improvements in cracking delay are added.
  • An extra password place beyond 14 can frustrate a cracking effort by millions of years by avoiding LM password hashing.
  • Such a plan can work even inside a network where shorter passwords are backward compatible to LM hashing.

[edit] Guarding user passwords

Computer users are generally advised "never write a password down anywhere, no matter what" and "never use a password for more than one account." These maxims, while sound in theory, ignore the reality that an ordinary computer user may have dozens of password-protected accounts. The multitude of accounts often ends up with users having the same password everywhere. A user's attempt to comply will often result in many forgotten passwords, even for important accounts.

If passwords are written down, they should never be kept in obvious places such as address books, Rolodex files, under drawers or keyboards or behind pictures. Perhaps the worst, but all too common, method is a Post-it note near the computer. Better locations are a safe deposit box or a locked file approved for information of comparable sensitivity to that protected by the password. Software is available for popular hand-held computers that can store passwords for numerous accounts in encrypted form. Another approach is to use a single password for low security accounts and select separate, strong passwords for a smaller number of high-value applications such as online banking. Manual or offline forms of this approach are also in use. For example a phone directory may be used to keep a map between computer accounts and password hints.

The problem of password overload is quite real. Certain IT professionals may manage from 25 to 250 privileged passwords at any one time. In such cases, some safe storage area for password hints, private key or encrypting password become unavoidable.

At a 2005 security conference, an expert from Microsoft was quoted as saying: "I claim that password policy should say you should write down your password. I have 68 different passwords. If I am not allowed to write any of them down, guess what I am going to do? I am going to use the same password on every one of them." [3]

Whether it is worse to use weak passwords that are memorized or strong passwords that are written down can provoke fierce debate among experts. Practical security often requires balancing conflicting imperitives such as security requirements and human factors.

[edit] Password discovery

Passwords can be discovered by shoulder surfing, burglary, extortion, blackmail, threats, or other methods. Information diving is surprisingly fruitful for situations in which sensitive printed data is discarded with insufficient precaution; it is said to be part of the techniques which have produced the recent rise in identity theft. Approximate password length can be discovered even without shoulder surfing by simply counting keyboard clicks or noting finger motions. Research published by IBM in 2004 shows that each key on a keyboard has a distinctive acoustic signature, allowing keyed in data, including passwords, to be recovered by analyzing recordings from a covert listening device or "bug." See: Acoustic cryptanalysis.

Obtaining passwords by psychological manipulation of users is an example of social engineering. An attacker might telephone a user and say "Hi. Systems Control here. We're doing a security test. Can we have your password so we can proceed?" Systems administrators and other support staff will very rarely, if ever, need to know a user's password in order to perform their jobs. System administrators with "root" or superuser privileges can change the users' passwords without their permission, so they have no need whatsoever to ask for it. In addition, they will go out of their way not to ask for a password, precisely because they do not want to encourage the habit of giving passwords to anyone. Users do not generally appreciate that any of this is so, and are thus too often vulnerable to social engineering.

Password Betrayal is a method that takes advantage of a mixed mode technique. It uses the combined effect of differing strengths of password hashing and the habit of people to re-use the same password many times. A classic example of password betrayal would be a person re-using the same password on two independent computer systems. On one computer system the strong password is strongly protected. But on the other computer system the password protection is easily defeated. The under protected password is then re-used with other accounts known to belong to the same person. This password capture method can work even if the password is a strong or complex password choice.

Single Sign On solutions can be an advantage in reducing the risk of password betrayal. However, a person may access separate systems with differing password encryption strengths, password complexity rules, Single Sign On product vendors and computer security vulnerabilities.

To help, a person can keep an index of which password is in use with multiple accounts. This strategy can mitigate this risk to some extent. The password use index allows the person to change groups of accounts with identical passwords as needed. But, a password use index should only contain password hints rather than direct password examples. Care should be taken to protect a password use index from easy duplication, sharing, exposure or capture.

[edit] External links