| Password Cracking |
Article Index for Password |
Website Links For Password |
Information AboutPassword Cracking |
| CATEGORIES ABOUT PASSWORD CRACKING | |
| cryptographic attacks | |
| security exploits | |
| system administration | |
|
BACKGROUND Passwords to access computer systems are usually stored, typically not in Cleartext form, in a database so the system can perform password verification when users attempt to login. To preserve confidentiality of system passwords, the password verification data is typically generated by applying a One-way Function to the password, possibly in combination with other data. For simplicity in this discussion, when the one-way function (which may be either an encryption function or Cryptographic Hash ) does not incorporate a secret key, other than the password, we will refer to the one way function employed as a ''hash'' and its output as a ''hashed password''. Even though functions that create hashed passwords may be cryptographically secure, possession of a hashed password provides a quick way to test guesses for the password by applying the function to each guess, and comparing the result to the verification data. The most commonly used hash functions can be computed rapidly and the attacker can test guesses repeatedly with different guesses until one succeeds, meaning the Plaintext password has been recovered. The term ''password cracking'' is typically limited to recovery of one or more Plaintext passwords from hashed passwords. Password cracking requires that an attacker can gain access to a hashed password, either by reading the password verification database (e.g., via a Trojan Horse , Virus program, or social engineering) or intercepting a hashed password sent over an open network, or has some other way to rapidly and without limit test whether a guessed password is correct. Without the hashed version of a password, the attacker can still attempt access to the computer system in question with guessed passwords. However well designed systems limit the number of failed access attempts and can alert administrators to trace the source of the attack if that quota is exceeded. With the hashed password, the attacker can work undetected, and if the attacker has obtained several hashed passwords, the chances for cracking at least one is quite high. There are also many other ways of obtaining passwords illicitly, such as Social Engineering , Wiretap ping, Keystroke Logging , Login Spoofing , Dumpster Diving , Phishing , Shoulder Surfing , Timing Attack , Acoustic Cryptanalysis , identity management system attacks (such as abuse of Self-service Password Reset ) and compromising host security (see Password for details). However, ''cracking'' usually designates a guessing attack. Cracking may be combined with other techniques. For example, use of a hash-based Challenge-response Authentication method for password verification may provide a hashed password to an eavesdropper, who can then crack the password. A number of stronger Cryptographic Protocols exist that do not expose hashed-passwords during verification over a network, either by protecting them in transmission using a high-grade key, or by using a Zero-knowledge Password Proof . PRINCIPAL ATTACK METHODS Weak encryption If a system uses a Cryptographically weak function to hash or encrypt passwords, exploiting that weakness can recover even 'well-chosen' passwords. Decryption need not be a quick operation, and can be conducted while not connected to the target system. Any 'cracking' technique of this kind is considered successful if it can decrypt the password in fewer operations than would be required by a Brute Force Attack (see below). The fewer operations required, the "weaker" the encryption is considered to be (for equivalently well chosen passwords). One example is the LM Hash that Microsoft Windows uses by default to store user passwords that are less than 15 characters in length. LM hash breaks the password into two 7-character fields which are then hashed separately, allowing each half to be attacked separately. Progress in cryptography has made available functions which are believed to actually be " One Way " Hashes , such as MD5 or SHA-1 . These are thought to be impossible to invert in practice. When quality implementations of good cryptographic hash functions are correctly used for authentication, password cracking through decryption can be considered infeasible. Guessing Not surprisingly, many users choose weak passwords, usually one related to themselves in some way. Repeated research over some 40 years has demonstrated that around 40% of user-chosen passwords are readily guessable by programs. Examples of insecure choices include:
and so on. Some users even neglect to change the default password that came with their account on the computer system. And some administrators neglect to change default account passwords provided by the operating system vendor or hardware supplier. A famous example is the use of ''FieldService'' as a user name with ''Guest'' as the password. If not changed at system configuration time, anyone familiar with such systems will have 'cracked' an important password; such service accounts often have higher access privileges than a normal user account. The determined cracker can easily develop a computer program that accepts personal information about the user being attacked and generates common variations for passwords suggested by that information. Dictionary attack A Dictionary Attack also exploits the tendency of people to choose weak passwords, and is related to the previous attack. Password cracking programs usually come equipped with "dictionaries", or word lists, with thousands or even millions of entries of several kinds, including:
The cracking program encrypts each word in the dictionary, and simple modifications of each word, and checks whether any match an encrypted password. This is feasible because the attack can be automated and, on inexpensive modern computers, several thousand possibilities can be tried per second. Guessing, combined with dictionary attacks, have been repeatedly and consistently demonstrated for several decades to be sufficient to crack perhaps as many as 50% of all account passwords on production systems. Brute force attack A last resort is to try ''every'' possible password, known as a Brute Force Attack . In theory, a brute force attack will always be successful since the rules for acceptable passwords must be publicly known, but as the length of the password increases, so does the number of possible passwords. This method is unlikely to be practical unless the password is relatively small. But, how small is too small? This depends heavily on whether the prospective attacker has access to the Hash of the password, in which case the attack is called an ''offline attack'' (it can be done without connection to the protected resource), or not, in which case it is called an ''online attack''. Offline attack is generally a lot easier, because testing a password is reduced to a quickly calculated mathematical computation, i.e. calculating the hash of the password to be tried and comparing it to the hash of the real password. In an online attack the attacker has to actually try to authenticate himself with all the possible passwords, where arbitrary rules and delays can be imposed by the system and the attempts can be logged. A common current length recommendation for cases where the attacker will not have access to the hash is 8 or more randomly chosen characters combining letters, numbers, and special (punctuation, etc) characters. Systems which limit passwords to numeric characters only, or upper case only, or, generally, which exclude possible password character choices make such attacks easier. Using longer passwords in such cases (if possible on a particular system) can compensate for a limited allowable character set. And, of course, even with an adequate range of character choice, users who ignore that range (using only upper case alphabetic characters, or digits alone, for instance) make brute force attacks much easier against those password choices. Generic Brute-force Search techniques can be used to speed up the computation. But the real threat may be likely to be from ''smart'' brute-force techniques that exploit knowledge about how people tend to choose passwords. NIST SP 800-63 (2) provides further discussion of password quality, and suggests, for example, that an 8 character ''user-chosen'' password may provide somewhere between 18 and 30 bits of entropy, depending on how it is chosen. This amount of entropy is far less than what is generally considered safe for an encryption key. How small is ''too small'' for offline attacks thus depends partly on an attacker's ingenuity and resources (e.g., available time, computing power, etc.), the latter of which will increase as computers get faster. Most commonly used hashes can be implemented using specialized hardware, allowing faster attacks. Large numbers of computers can be harnessed in parallel, each trying a separate portion of the search space. Unused overnight and weekend time on office computers can also be used for this purpose. The distinction between guessing, dictionary and brute force attacks is not strict. They are similar in that an attacker goes through a list of candidate passwords one by one; the list may be explicitly enumerated or implicitly defined, may or may not incorporate knowledge about the victim, and may or may not be linguistically derived. Each of the three approaches, particularly 'dictionary attack', is frequently used as an umbrella term to denote all the three attacks and the spectrum of attacks encompassed by them. Precomputation In its most basic form, precomputation involves hashing each word in the dictionary (or any search space of candidate passwords) and storing the Advanced precomputation methods exist that are even more effective. By applying a LAN Manager passwords in a few seconds. This is much faster than brute force attacks on the obsolete LAN Manager, which uses a particularly weak method of hashing the password. Current Windows systems still compute and store a LAN Manager hash by default for backwards compatibility. {Link without Title} ) A technique similar to precomputation, known generically as Memoization , can be used to crack multiple passwords at the cost of cracking just one. Since encrypting a word takes much longer than comparing it with a stored word, a lot of effort is saved by encrypting each word only once and comparing it with each of the encrypted passwords using an efficient List Search algorithm. The two approaches may of course be combined: the time-space tradeoff attack can be modified to crack multiple passwords simultaneously in a shorter time than cracking them one after the other. Salting The benefits of precomputation and Memoization can be nullified by randomizing the hashing process. This is known as Salting . When the user sets a password, a short, random string called the salt is suffixed to the password before encrypting it; the salt is stored along with the encrypted password so that it can be used during verification. Since the salt is usually different for each user, the attacker can no longer construct tables with a single encrypted version of each candidate password. Early Unix systems used a 12-bit salt. Attackers could still build tables with common passwords encrypted with all 4096 possible 12-bit salts. However, if the salt is long enough (e.g. 32 bits), there are too many possibilities and the attacker must repeat the encryption of every guess for each user. Early Unix password vulnerability
PREVENTION The best method of preventing password cracking is to ensure that attackers cannot get access even to the encrypted password. For example, on the Unix Operating System , encrypted passwords were originally stored in a publicly accessible file "/etc/passwd". On modern Unix (and similar) systems, on the other hand, they are stored in the file "/etc/shadow", which is accessible only to programs running with enhanced privileges (ie, 'system' privileges). This makes it harder for a malicious user to obtain the encrypted passwords in the first instance. Unfortunately, many common network protocols transmit the hashed passwords to allow remote authentication. REFERENCES # Philippe Oechslin: Making a Faster Cryptanalytic Time-Memory Trade-Off. CRYPTO 2003: pp617–630 # NIST Special Publication 800-63: Electronic Authentication Guideline EXTERNAL LINKS
SEE ALSO Password cracking programs
|
|
|