We currently believe that 128 bits of security should be sufficient for current and future needs. Much of this is due to physical constraints: using the theoretical minimum energy to store 2^128 bits of data would require more energy than is required to boil the world's oceans.

If you're using a password manager, that means that a 20 character truly random password using the 94 non-whitespace ASCII characters, and 22 characters if you're using the Base64 characters. If you're not using a password manager, you probably should be.

If you want to protect against even the most unlikely scenarios, then you can use a password with 256 bits of entropy. I do this on sites where I can, and since I use a password manager, there's no need for me to remember it.

Note, however, that in many cases, there are likely easier attacks than brute force. For example, it may be easier to compromise the site or service in question than conduct a brute force attack on the password. That being said, it's easy to use strong passwords in most cases, so there's little reason not to.

Answer from bk2204 on Stack Exchange
🌐
PasswordMonster
passwordmonster.com › home
Password Strength Meter
March 3, 2022 - A passphrase is simply a password, that’s longer, it could be a sentence, with spaces and punctuation in it. The benefit of a passphrase is that typically they’re easier to remember, but more difficult to crack due to their length. For every additional character in the length of a password or passphrase, the time it would take to break increases exponentially.
🌐
Baeldung
baeldung.com › home › security › how to determine the entropy of a password?
How to Determine the Entropy of a Password? | Baeldung on Computer Science
March 18, 2024 - However, a 10-character long password that contains at least one uppercase letter, one lowercase letter, one number, and one symbol takes 5 years to crack. Hence, the password’s strength increases exponentially with a higher number of characters.
Top answer
1 of 2
19

We currently believe that 128 bits of security should be sufficient for current and future needs. Much of this is due to physical constraints: using the theoretical minimum energy to store 2^128 bits of data would require more energy than is required to boil the world's oceans.

If you're using a password manager, that means that a 20 character truly random password using the 94 non-whitespace ASCII characters, and 22 characters if you're using the Base64 characters. If you're not using a password manager, you probably should be.

If you want to protect against even the most unlikely scenarios, then you can use a password with 256 bits of entropy. I do this on sites where I can, and since I use a password manager, there's no need for me to remember it.

Note, however, that in many cases, there are likely easier attacks than brute force. For example, it may be easier to compromise the site or service in question than conduct a brute force attack on the password. That being said, it's easy to use strong passwords in most cases, so there's little reason not to.

2 of 2
4

One trillion passwords per second sounds like a good rule of thumb and jibes with the number I found when researching my table of pw cracking times in 2015 (I found an estimated 23 billion per second per node, which is plausible since the NSA could easily have a few dozen nodes).

When calculating this sort of thing, I prefer to assume Moore's Law applies directly to crack efficiency (it doubles every 18mo). There have been 2344 days since the 2015-07-01 (the mid-point of 2015), which accounts for 4.3 periods of 18mo since mid-2015, so 1T pw/s in 2015 becomes 24.3 = 19.4T pw/s. Since pessimism fits here, Let's round that to 20T pw/s (in scientific notation, 2e13).

When calculating crack time for entropy, assume an attacker will get the password in half of the number of tries needed, so an entropy of 80, which refers to 280 passwords, can be cracked in 280pw / 2e13pw/s / 2 / 86400s/d / 365.25d/y = 957.7 years with November 2021 upgrades to the same cluster size.

I've lost the math I used to determine how to account for upgrades every 18mo, but it's easier just to fast-forward ten years: 2e13 × 210/1.5 = 2e15, an increase of two orders of magnitude. 280 / 2e15 / 2 / 86400 / 365.25 = 9.58 years, with an expected crack around 2041.

However, an entropy of 80 is very unwieldy when it comes to human memory. Diceware (7776 entries) would require six words (for entropy 77, add a random alphanumeric to make that 83). Using a standard spelling dictionary (100k entries), you'd need five words (for entropy 83). Using random printable ASCII characters, you'd need twelve (for entropy 78, thirteen yields 85).

At that point, is memorizing six random words or thirteen random characters really feasible for every account you use?


Use authenticators on accounts that allow it. For most systems, that's multi-factor or 2FA. Sometimes, there's a passwordless login that uses a 2FA technology on its own. For most services, cryptographic authentication apps provide sufficient security and we'll see a lot of transition away from passwords in the very near future. Higher-security concerns (like your email, bank, and password manager) will still need both a secure authenticator and a password.

Use a password manager with a passcode generator that uses 16+ random characters including a minimum of 1 lower, 1 upper, and 1 special, yielding an entropy of log₂(94¹³×26×26×32) = 99. To get to bk2204's suggested 128 bit entropy, you'd need 21 total characters.

For items you can't put into the password manager (like the password manager's entry code itself), I recommend a 8-ish character passcode put in a random place within a passphrase of 5 dictionary words or 6 Diceware words. Use a generator, humans are very bad at understanding that random ≠ arbitrary ≠ obscure. For example, I just popped open Bitwarden (Diceware) and generated reversion junkie unknotted opposite litter stamina as a passphrase and 7!&CPc9T as a passcode (requiring one upper, one lower, and one special), then I got 3 as a random number from 0-6 (echo $(($RANDOM%7)) in bash), so I can combine those to add the code after the 3rd word: reversion junkie unknotted 7!&CPc9T opposite litter stamina. Make a story to remember the words and write the code down on a piece of paper that lives in your wallet.

This has an entropy of log₂(7776⁶×94⁵×26×26×32) = 125.

(Update: Bitwarden uses Diceware, which is unnecessarily limiting. I've added a word to get a more robust entropy value until Bitwarden gains support for larger dictionaries.)

Don't fully trust your cloud-connected password manager for your most trusted items (PGP key, bank, email, etc)? Generate random 16-char codes and save them as the password, then generate another 5-char (or 2-word) code that you write down in your wallet with cryptic clues about what it is. Append that to your password after filling in the login form with your pw manager.

Just be careful not to lock yourself out with a scheme you don't recall, especially with sites like banks that lock you out after a small number of login attempts.

🌐
TechTarget
techtarget.com › whatis › definition › password-entropy
What is password entropy? | Definition from TechTarget
For example, a brute-force attack might be able to crack the password accidental in about 58 minutes, according to Security.org, but it might take 7 quadrillion years to crack the password ac@xC1d!3aTlx4$3Hg using today's technology.
🌐
Bitwarden
bitwarden.com › password-strength
Password Tester | Test Your Password Strength | Bitwarden
Using long passwords is critical to password strength. An 8-character password will take anywhere from a few minutes to a couple of hours to crack, while a 16-character password will take a hacker a billion years to crack.
🌐
Reddit
reddit.com › r/cryptography › question about password entropy and brute forcing
r/cryptography on Reddit: Question about password entropy and brute forcing
March 13, 2022 -

I'm setting up full disk encryption with LUKS2 for the first time and have to choose a passphrase. Before I do this I'd like to clear my confusion about brute forcing.

Using https://www.security.org/how-secure-is-my-password/ to check password strength, a 14 character password like $8wtS!^9C6voA2 takes 2 hundred million years to brute force whereas a passphrase such as Emphasis-Tubby3-Boat takes 42 quintillion years. I'm not sure how accurate this is though, but it sure is surprising to see such a ginormous difference.

At first I considered using a password like the former because it looks far more complex than the passphrase. Although I prefer a passphrase because it is easier to remember, before checking its strength I thought it to be a worse option because it primarily consists of dictionary words!

Now with some effort I can remember long and complex passwords like the former, I did it before but it took me several months.

Can anyone explain why a passphrase containing dictionary words and a mere amount of 3 non-alphabetic characters is deemed much stronger than a 14 character randomly generated password?

Edit: 91 bit vs 150 bit entropy. So it makes sense that the passphrase would be deemed as stronger, however doesn't the fact that it contains primarily dictionary words negate its perceived security?

Top answer
1 of 5
7
Can anyone explain why a passphrase containing dictionary words and a mere amount of 3 non-alphabetic characters is deemed much stronger than a 14 character randomly generated password? The password checker probably doesn't accounts for dictionary words. It simply calculates the difficulty based on length and general complexity.
2 of 5
4
The honest answer basically breaks down like this: Password strength is determined by a single number, called "entropy". Entropy increases with the number of possible outcomes you have and is counted in a unit called "bits". The standard unit of mass is kilograms. But another unit of mass that might be familiar to you is "pounds". Even though it's not the SI unit, it's a completely valid unit with a single conversion ratio to the SI one of "kilograms". Similarly, the SI unit of length is "meters", but another unit of length that might be familiar to you is "feet", which is a valid unit with a conversion ratio to the SI one. The standard unit of entropy is "bits". But a completely valid alternative unit of entropy which you might be familiar with is "digits" A "digit" of entropy is the number of digits in the number of unknown possibilities there are. Lets look at an example. Suppose you put all the playing cards A2345678910 but no face cards into a bag. Suppose I drew one at random and didn't show you what it was. What is the value of my card? You don't know what it is, there are 10 possibilities. The number of digits in a number from 1-10 is "1". So the "digits" of entropy of my unknown playing card is 1. Lets say I wrote a random 10-character number down and buried it. You don't know what number I wrote except that it's got 10 characters. Therefore, the number has 10000000000 possibilities, or equivalently 10 digits of entropy. If I tell you that the number starts with 301, now the number has 10000000 possibilities and therefore has 7 digits of entropy. If I tell you that it's a phone number, now it has even fewer possibilities, because only some 10 digit numbers are valid phone numbers, and therefore it has even less entropy (because you know that there are fewer possibilities). A 6- sided dice doesn't have 0 digits of entropy, because you have 6 possibilities. But it doesn't have 1 digit of entropy, because 1 digit of entropy is 10 possibilities. Just like meters, entropy can be measured in fractional parts. The equation is Entropy (digits)=log10(possibilities). So a 6-sided die is 0.77815125038 digits of entropy Since entropy counts the number of digits in the number of possibilities, the number of possibilities increases exponentially with each additional digit of entropy. For example, 5 digits of entropy is 100000 possibilities. But 6 digits of entropy is 1000000 possibilities. This is all relevant to your question because when you look at the strength of a password w.r.t. brute force, you care about how many possibilities it could be assuming that the attacker can try all possibilities. You also assume that the attacker is smart and will try possibilities with structure first. For example of "structure": knowing that it was a password, it would be silly to try all 10-digit numbers, that's 10 billion numbers. Instead, you should recognize that human beings with numeric passwords are more likely to choose memorable numbers, such as phone numbers. So you wouldn't try all possible numbers 1-10bn, you'd start with all valid phone numbers first, (and you'd try 8675309 absolutely first). So when choosing a password there's 2 different ways to compute an estimate of the entropy. The first is to merely just look at how long it is and assume that the attacker is trying all possible combinations of letters and numbers in order. Using that metric, "iamthewalrus" is equally strong as "irp29fj28!", because they are the same length. Obviously, that's not a good metric and that's why most of these "tools" are really stupid. The better metric would be to assume that the attacker is exactly as smart as you and is trying common things first. Which is how you should be estimating your password strength. Most of these "password checkers" don't know how to do that because they aren't super advanced AIs that know everything about human knowledge. So lets look at "$8wtS!^9C6voA2". I don't see any obvious patterns here. So the only way to generate this would be if you were just trying random characters. If there are say 80 letters numbers and punctuation, then each letter adds 80 possibilities, so this password would only be found after trying 8014 possibilites. log10(8014) =26.6432598179 digits of entropy, or something like 10e26 possibilities. Using the "length" method where it doesn't recognize patterns at all, "Emphasis-Tubby3-Boat" has 21 characters. So this would be log10(8021) digits of entropy, or 10e40 possibilities. But of course we don't want to do the length method. We want to assume that the hacker is trying patterns. So we assume that the hacker knows to put "-" in repeat groups. If our dictionary has 2048 words, and the number is 0-10 (or optionally not present), then each group is 2048x11 possibilities. So three of them would be (2048x11)3 = 10e13. Which is YES a lot weaker than 10e40 or even 10e26. But here's the thing: by adding more groups you can make your entropy go up significantly. Entropy increases exponentially, so every group you add multiplies the number of possibilities times 2048x11. If you increase the number of groups to 6, such as "Emphasis-Tubby3-Boat-Enhance7-Person1-Rage" then even with the knowledge of the underlying dictionary and the group pattern, in order to get to that specific 6-group pattern the attacker would have to try all 6-group patterns. And (2048x11)6 is about 10e27 possibilities. Which is more secure than "$8wtS!^9C6voA2"! So yes, knowing that they are dictionary words does in fact decrease their security, and your password checker isn't calculating it correctly. However, a passphrase based on random dictionary words can be made to be as secure or more as a password with random characters, and its a lot easier to remember at the same security level.
🌐
Wikipedia
en.wikipedia.org › wiki › Password_strength
Password strength - Wikipedia
1 day ago - In 1999, an Electronic Frontier Foundation project broke 56-bit DES encryption in less than a day using specially designed hardware. In 2002, distributed.net cracked a 64-bit key in 4 years, 9 months, and 23 days.
🌐
NordVPN
nordvpn.com › blog › what-is-password-entropy
Password entropy and how to calculate it | NordVPN
September 2, 2025 - The best way to protect your account is to use a long and intricate password that takes ages to crack. The number of attempts an attacker would need to guess your password is a good measure of password strength, and this measure is known as password entropy.
Find elsewhere
Top answer
1 of 4
32

Assume you have no rainbow table (or other precomputed list of hashes), and would actually need to do a brute-force or dictionary attack.

This program IGHASHGPU v0.90 asserts to be able to do about 1300 millions of SHA-1 hashes (i.e. more than 2^30) in each second on a single ATI HD5870 GPU.

Assume a password of 40 bits of entropy, this needs 2^10 seconds, which is about 17 minutes.

A password of 44 bits of entropy (like the one in the famous XKCD comic) takes 68 minutes (worst case, average case is half of this).

Running on multiple GPUs in parallel speeds this up proportionally.

So, brute-forcing with fast hashes is a real danger, not a theoretical one. And many passwords have a much lower entropy, making brute-forcing even faster.

If I use a truly random salt for each user, on what order of magnitude will this affect the length of time to crack my password?

The salt itself is assumed to be known to the attacker, and it by itself doesn't much increase the cracking time for a single password (it might increase it a bit, because the hashed data becomes one block longer, but that at most doubles the work).

The real benefit of a (independent random) salt is that an attacker can't use the same work to attack the passwords of multiple users at the same time. When the attacker wants just any user's password (or "as many as possible"), and you have some millions of users, not having a salt would could down the attack time proportionally, even if all users would have strong passwords. And certainly not all will have.

As a bonus, which hashing algorithms are safest to use?

The current standard is to use a slow hashing algorithm. PBKDF2, bcrypt or scrypt all take both a password and a salt as input and a configurable work factor - set this work factor as high as your users just accept on login time with your server's hardware.

  • PBKDF2 is simply an iterated fast hash (i.e. still efficiently parallelizable). (It is a scheme which can be used with different base algorithms. Use whatever algorithm you are using anyways in your system.)
  • Bcrypt needs some (4KB) working memory, and thus is less efficiently implementable on a GPU with less than 4KB of per-processor cache.
  • Scrypt uses a (configurable) large amount of memory additionally to processing time, which makes it extremely costly to parallelize on GPUs or custom hardware, while "normal" computers usually have enough RAM available.

All these functions have a salt input, and you should use it.

2 of 4
7

If you don't use salts, the hacker can simply type them into Google and likely find it. MD5 encrypt your password, then Google the result, and you'll see what I mean.

If you've chosen a sufficiently complex password, then it probably won't be on Google, but it will still be in pre-computed tables called "rainbow tables" (the full tables would take too much space, so the "rainbow" technique is used to compress them).

If no tables are being used, then it doesn't matter if the password is salted or not. Of course, tables are always used, so yes, you should salt the passwords.

A desktop machine, with a gaming card (which can also be used to accelerate password cracking), and calculate a billion hashes/second. How fast this cracks your password depends. It can calculate all combinations for short passwords within a few minutes. But the, the problem is exponential, so that it cannot calculate all possible combinations for long passwords, even if you used a billion computers over a billion years.

Instead, what hacker do is a "mutated dictionary" crack. They start with a list of well-known words. It's called a "dictionary", but such lists contain a lot of words that you wouldn't find in a real dictionary, like "ncc1701", the designation for the Star Trek Enterprise. For each word, it does a number of mutations, such as capitalizing some letters, changing some letters to numbers, like "p4ssw0rd", or appending characters, like "password1234". How fast this works depends upon the skill of the hacker choosing just the right dictionary and just the right mutations. This can also change depending upon the hacker's knowledge of you. For example, if you are Hispanic, the hacker will add Spanish words and names to the dictionary.

You can expect that if your password database is stolen, the hacker will be able to crack about half of the salted passwords with a couple day's worth of work.

Top answer
1 of 2
2

As others have mentioned, for entropy to be well-defined, you need to have some underlying probability distribution $D$. If you are willing to look around some unsavory places, you could look for a moderately-large data breach to get an empirical distribution of passwords that you can compute the entropy of. Alternatively there might be some user studies that have computed things like this.

The main point of this answer is to mention that there are multiple inequivalent notions of entropy, and that the traditional (shannon) entropy is not always the best one in cryptography. Shannon entropy is defined as

$$H(X) = \sum_{x\in \mathsf{supp}(X)} p(x)\log(1/p(x))$$

Another fairly-common notion of entropy is the min-entropy, defined as

$$H_\infty(X) = \max_{x\in \mathsf{supp}(X)} \log(1/p(x))$$

This roughly captures the most likely output under $X$. It is often much better to use for cryptographic purposes, which can be demonstrated via a simple example.

Let $X$ be a random variable that is

  1. $0$ with probability $1/2$, and
  2. uniform over $\{1,\dots,2^k\}$ with probability $1/2$.

The min entropy of this is very small (it is $1$). The shannon entropy of it is much larger (I believe it is something like $k-O(1)$, I am too lazy to compute the constant). So if you are measuring the quality of a distribution over passwords via

  • min entropy, you will think that $X$ is quite bad, vs
  • shannon entropy, you will think $X$ is quite good.

Of course, half of all users sampling passwords from $X$ can be trivially attacked, so it should perhaps be considered "bad" (in accordance to what min entropy would predict).

2 of 2
3

The answer depends on many factors. In particular:

  • If a human has generated it, the probability of some value will be higher that the probability of the others.
  • If random generator was used, it depends on what is known about its properties. If it is known that it generates some values more often that the others, this can affect the probability to guess.
  • It depends on correctness of implementation of password generator. Implementation bugs can affect the probability of some values.
  • It depends on how guessing is organized. If human is guessing, then even knowing the information above, it will have one probability. If some application is guessing, it will have another probability.

The formula 1/2entropy is correct. But, as Royce Williams said, in many cases it is hard to calculate the entropy. Entropy is not something absolute. It depends on the context, on the factors mentioned above. For instance, password is generated randomly using lower case English letters. One person knows this exactly. Another person knows only that password can contain English letters in both cases and digits. The probability to guess for the first person will be higher.

Thus the actual question is: How to calculate entropy?

🌐
Okta
okta.com › identity-101 › password-entropy
Password Entropy: The Value of Unpredictable Passwords | Okta
E stands for password entropy. R stands for possible characters within the password. L stands for the number of characters in your password. ... Add more character types. Include uppercase and lowercase letters, special characters, and numbers. Increase the length. Longer passwords have higher scores than shorter versions. Aim for a score of 60 or higher. But remember: Don't make the password so long and complicated that you'll never remember it.
🌐
Omni Calculator
omnicalculator.com › other › password-entropy
Password Entropy Calculator
March 20, 2024 - So your only chance is to use a password that would take a very long time to guess (optimally, several millions of years). The number of trials an adversary would need to guess your password is an excellent measure of password strength. This measure is known as password entropy.
🌐
Auth0
auth0.com › blog › defending-against-password-cracking-understanding-the-math
Defending Against Password Cracking: Understanding The Math
To give you an idea, assuming you generated a password completely randomly, here's how much time it takes to crack passwords of different entropies with 170 billion attempts per second:
🌐
Proton
proton.me › blog › what-is-password-entropy
What is password entropy? | Proton
October 5, 2023 - The example from above, kmXz2=zs[m%7?y4A, meets all these requirements and creates a password with roughly 105 bits of entropy, which would take an impossibly long time to crack by brute force.
🌐
Pleacher
pleacher.com › mp › mlessons › algebra › entropy.html
Password Entropy
Password entropy is a measurement of how unpredictable a password is. The formula for entropy is: E stands for "entropy," which is the opposite of an ordered pattern. Entropy is good: the bigger the E, the harder a password is to crack · We calculate password entropy by first looking at the ...
🌐
Password Generator
generatepasswords.org › how-to-calculate-entropy
How to Calculate Password Entropy? - Password Generator
June 10, 2019 - Password entropy predicts how difficult a given password would be to crack through guessing, brute force cracking, dictionary attacks or other common methods. Entropy essentially measures how many guesses an attacker will need to make to guess your password. As computing power grows, the amount of time required to guess large amounts of passwords decreases significantly, therefore it is useful to make certain assumptions at the time of a given calculation as to number of guesses per second a computer can make (a factor which varies over time).
🌐
GRC
grc.com › haystack.htm
GRC's | Password Haystacks: How Well Hidden is Your Needle?
Yet the Search Space Calculator above shows the time to search for those two passwords online (assuming a very fast online rate of 1,000 guesses per second) as 18.52 minutes and 17.33 centuries respectively! If “123456” is the first password that's guessed, that wouldn't take 18.52 minutes.
🌐
IEEE Xplore
ieeexplore.ieee.org › document › 7043593
Random password entropy and crack time calculation for South Asian languages | IEEE Conference Publication | IEEE Xplore
This paper analyses the effectiveness of random passwords used in South Indian languages in terms of their entropy value with an objective of recommending passwords with mandatory minimum length to enhance the security aspects in relation to their predictability.