Actions

Passwords

Introduction[edit]


If weak passwords (passphrases) are used, they can be easily determined by brute-force attacks, whether or not Whonix is installed. In essence, attackers systematically try all passwords until the correct one is found, or attempt to guess the key which is created from the password using a key derivation function (an exhaustive key search). This method is very fast for short and/or non-random passwords.

Generating Unbreakable Passwords[edit]

Introduction[edit]

To generate passwords which cannot be brute-forced over millions or even billions of years, users should default to lengthy diceware passwords based on information in the next section. [3] Note this entry assumes that quantum computers do not already exist which have broken or impacted common cryptographic algorithms, such as halving the key size of symmetric keys. Wikipedia explains how diceware operates: [4]

Diceware is a method for creating passphrases, passwords, and other cryptographic variables using ordinary dice as a hardware random number generator. For each word in the passphrase, five rolls of the dice are required. The numbers from 1 to 6 that come up in the rolls are assembled as a five-digit number, e.g. 43146. That number is then used to look up a word in a word list. In the English list 43146 corresponds to munch. By generating several words in sequence, a lengthy passphrase can be constructed.


A Diceware word list is any list of 6^5 = 7,776 ... unique words, preferably ones the user will find easy to spell and to remember... The level of unpredictability of a Diceware passphrase can be easily calculated: each word adds 12.9 bits of entropy to the passphrase... This level of unpredictability assumes that a potential attacker knows that Diceware has been used to generate the passphrase, knows the particular word list used, and knows exactly how many words make up the passphrase. If the attacker has less information, the entropy can be greater than 12.9 bits per word.

A suitable diceware word list can be found here. It is available in a long list version for those using 5 dice, or in a short list version if using only 4 dice. Note that only using 4 dice and shorter word lists reduces the entropy to 10.3 bits per word, so a longer password must be generated to be safe. [5]

Diceware Password Strength[edit]

The following estimates of entropy and password strength have been calculated using this online tool, and is based on the 5 dice method. "Entropy" in the table below can be defined as: [6]

Entropy is a measure of the uncertainty or randomness of a system. The concept is a difficult one to grasp fully and is confusing, even to experts. Strictly speaking, any given passphrase has an entropy of zero because it is already chosen. It is the method you use to randomly select your passphrase that has entropy. Entropy tells how hard it will be to guess the passphrase itself even if an attacker knows the method you used to select your passphrase. A passphrase is more secure if it is selected using a method that has more entropy.


Entropy is measured in bits. The outcome of a single coin toss -- "heads or tails" -- has one bit of entropy.

Table: Diceware Password Strength [7]

Word Total Bits of Entropy Estimated Brute-force Time (Classical Computing) [8] Future-proof Safety [9] Post-quantum Secure [10]
Five ~64 ~165 days No No
Six ~78 ~3,505 years Maybe No
Seven ~90 ~27,256 millenia Yes No
Eight ~103 ~15 x age Universe Yes No
Nine ~116 ~119,441 x age Universe Yes No
Ten ~129 ~928,773,415 x age Universe Yes No
Fifteen ~194 ~26,405,295,715,806,668,059,525,829,264 x age Universe Yes Yes
Twenty ~259 ~750,710,162,715,852,378,145,230,792,130,183,941,981,164,925,924 x age Universe Yes Yes

Classical Computing Attack

  • Diceware passphrases of 7 to 8 words in length are likely to be sufficient for several decades or more.
  • Generally speaking, lower entropy is reasonable to prevent online attacks due to limits on incorrect username/password combinations.
  • For important cryptographic keys or valuable encrypted external media, users are recommended to generate diceware passphrases of 10 words of more, since this removes the feasibility of brute-forcing predicated on a rapid improvement in classic technology. [11]


Quantum Computing Attack

  • For symmetric keys, [12] diceware passphrases of 15 words or more are likely to be sufficient for the foreseeable future. However, it is recommended to use a 20-word passphrase to completely rule out the possibility of brute-forcing.
  • It is possible to attain comparable entropy without creating longer passphrases, but this necessitates a larger diceware list than is outlined in this entry. [13]
  • All traffic relying on asymmetric public-key cryptography will be broken, such as browsing and email using SSL/TLS, PGP-encrypted email, and all Tor network activity (at least until quantum-resistant ciphers are introduced). [14]
  • Longer term defense requires the widespread adoption of post-quantum cryptographic algorithms.

Password Generation Method[edit]

Generating truly random passwords in a secure manner is surprisingly difficult. Experts in the field note it is preferable to rely on physical measures of randomness when creating diceware passwords: [15]

Generating truly random numbers using a computer is very tricky. The so-called random number generators that come with most programming libraries are nowhere near good enough. For most users dice is by far a better way to select passphrase words.

In light of this advice, common password generation methods can be classified for safety:

  • Safest: Physical measures of randomness only, such as dice, coins or similar methods.
  • Safe: A combination password using both physical measures and reputable software.
  • Potentially Unsafe: Software used in isolation introduces unknown variables. The software or libraries may be flawed, or the VM used for password generation may already be infected. [16]

Physically-generated Passwords[edit]

As dice are commonly used, it is important to note they must be correctly weighted to guarantee that words are chosen at random. If possible source translucent casino dice from a reputable manufacturer, since traditional gaming sets typically have poor-quality dice, which introduces statistical bias. [17] [18]

Software-generated Passwords[edit]

Advanced users can install the diceware package from Debian testing in order to create diceware passwords from the command line.

To generate a 10 word password, run.

diceware -n 10

Additional Tips[edit]

Follow this additional advice for diceware passwords: [19]

  • Diceware passwords should have spaces between each word, otherwise the strength of the password is materially weakened. For example, a six-word passphrase without spaces “stray clam my aloof micro judo” has the same strength as a five-word passphrase “stray clammy aloof micro judo” with spaces.
  • Only change passwords if a compromise is suspected.
  • Random character capitalization is not recommended. Although it adds 1 bit per character, it requires regular pressing of the shift key - slowing down typing and increasing the number of keystrokes. Instead, it is better to just make the passphrase longer if additional entropy is required.
  • If users do not have access to dice, a conversion table and three different coins can be used to generate an equivalent "dice roll". [20]

Principles for Stronger Passwords[edit]

Users should read Wikipedia: Weak Passwords to learn about better practices for generating strong passwords, and to determine if current passwords are weak. (w). The general principles for stronger passwords are outlined below. [21]

Content and Length[edit]

  • Avoid Dictionary-based Passwords: It is unsafe to use passwords that are dependent on dictionary words, keyboard patterns, special letter or number sequences, usernames, phrases from anything read or seen, relative or pet names, biographical information, or persons known to the user.
  • Avoid Short Passwords: Passwords should not be less than 12-14 characters in length; longer passwords are exponentially more difficult to crack than shorter ones. [22]
  • Generate True Password Randomness: Random passwords require the use of specialized tools like diceware. The human brain is poor at creating passwords which are both easy to memorize and also secure.
  • Online Services vs FDE: Passwords used for online services do not need to be extremely long, since the server rate-limits how many passwords an attacker can attempt. However, passwords used for offline encryption such as full disk encryption should be far stronger, since the threat model is different. An attacker can parallelize brute-forcing the password and is only limited by available system resources. Edward Snowden estimated in 2013 that serious adversaries are capable of one trillion guesses per second. [23]
  • Password Variety: If the user is not relying on diceware passwords, then include upper and lower case characters, special characters, digits, spaces, underscores and brackets.

Poor Habits[edit]

  • Avoid Personal Information: Any information that might be publicly linked to the user or the user's account, or which is known by friends or acquaintances, should never be used for passwords.
  • Avoid SMS-based Two-factor Authentication: Contrary to conventional wisdom, SMS-based 2FA gives away a user's identity, and also makes it easier for third parties to break into an account; for example, by performing sim-cloning or conducting social engineering attacks on the cellular provider. [24]
  • Do not Re-use Passwords: Even slight variations of a password allows the linking of multiple identities back to an individual. Attackers can use these discoveries to make templates which do not completely rely on brute-force attacks.
  • Never Use Online Password Generators: These tools are only useful for satisfying curiosity or additional learning, since it is possible for the server to log the passwords. The only place where passwords should be generated is locally, and ideally by using physical measures (like dice) or via software in a VM disconnected from the Internet.

Storage[edit]

  • Password Managers: Consider using a secure password manager, so hundreds of different passwords can be kept stored in an encrypted password database. Access only requires one master password, which should be cryptographically strong to protect the contents.
  • Physical Records: If passwords are written down, they should be stored securely and not be left in obvious places.

Forum Discussion[edit]

https://forums.whonix.org/t/password-advice-wiki-page-enhancements

See Also[edit]

Footnotes[edit]

  1. https://www.password-depot.com/know-how/brute-force-attacks.htm
  2. https://theintercept.com/2015/03/26/passphrases-can-memorize-attackers-cant-guess/
  3. https://en.wikipedia.org/wiki/Password_strength#Random_passwords
  4. https://en.wikipedia.org/wiki/Diceware
  5. The list has also been improved so the words are easier to memorize, and vulgar, profane, insulting or emotionally-charged words have been removed.
  6. http://world.std.com/~reinhold/dicewarefaq.html#entropy
  7. https://www.rempe.us/diceware/#eff
  8. One trillion guesses per second.
  9. Safe until at least the year 2050.
  10. Assuming Grover's algorithm halves the number of iterations required to brute-force a key. This means doubling the length of symmetric keys to protect against future (hypothetical) quantum attacks.
  11. https://en.wikipedia.org/wiki/Password_strength#Required_bits_of_entropy
  12. As is the case for full disk encryption.
  13. Community wiki contributions outlining this technique are welcome.
  14. https://hackaday.com/2015/09/29/quantum-computing-kills-encryption/
  15. http://world.std.com/%7Ereinhold/dicewarefaq.html
  16. Admittedly infection is a low probability scenario, particularly if a fresh VM was created solely for this purpose.
  17. http://world.std.com/~reinhold/dicewarefaq.html#casino
  18. Board dice typically favor rolls of 4, 5, and 6 because excess material has been drilled from those sides and they have not been properly counterbalanced. Crooked dice also have asymmetrical edges, uneven weight, non-parallel sides, or vary in smoothness.
  19. http://world.std.com/~reinhold/dicewarefaq.html#
  20. The consequence is that selecting a word from the diceware list takes 13 coin tosses, instead of 5 dice rolls.
  21. https://en.wikipedia.org/wiki/Password_strength#Guidelines_for_strong_passwords
  22. https://www.password-depot.com/know-how/brute-force-attacks.htm
  23. https://theintercept.com/2015/03/26/passphrases-can-memorize-attackers-cant-guess/
  24. https://www.wired.com/2016/06/hey-stop-using-texts-two-factor-authentication/

Random News:

Check out the Whonix blog.


https | (forcing) onion

Share: Twitter | Facebook

This is a wiki. Want to improve this page? Help is welcome and volunteer contributions are happily considered! See Conditions for Contributions to Whonix, then Edit! IP addresses are scrubbed, but editing over Tor is recommended. Edits are held for moderation.

Whonix is a licensee of the Open Invention Network. Unless otherwise noted, the content of this page is copyrighted and licensed under the same Libre Software license as Whonix itself. (Why?)