436 points · by tambourine_man · 2y ago · 268 comments
The usual advice about character classes is only for casual users who don't know what makes a secure password. Entropy is the deciding factor: Ten random lower case letters is much more secure than "Summer2024!", which satisfies most password rules and has more characters.
Personally I stick to lower case letters for things like my Netflix password or Wifi key, because typing with a TV remote can be a huge pain. To keep a similar entropy, just increase the length by one or two characters.
Arguably, it was to make early rainbow tables less feasible.
> if you are already generating the password, please do not include special characters.
This would make your generator useless on most sites. Since it's not the generator making up this rule, it's the web site's password "complexity" requirements.
I do agree password strength tests should just measure bits of entropy and allow whatever's typed that's high enough.
There is a special place in hell for anyone who creates a maximum password length limit, however. That prevents passphrases and gains nothing. If you're working with some weird legacy system that can't handle long password (worst way: just truncating them and matching the first 8 characters), then add Argon2 or heck even SHA where you otherwise add the password length check.
There was a PayPal bug just a couple years ago where the reset-password page didn't enforce length like other pages did. So it allowed you to create an otherwise illegal password and then your account is completely locked out (I guess, unless you realized the truncation was happening...)
And so I would reset my password, generate a new one... and it would happen again. Took me a while to realize it was the length and not a special character I added messing up with bad encoding logic or something.
If they have some perverse check to make sure I am not re-using one of my last X passwords I just rotate in another permutation like A2!
'!' is a good one. Quotation marks are not. Currency signs are not.
Then you get my personal favorite, which is sites that force you to use symbols, but when you do, they say you've used illegal symbols, but don't even tell you what symbols they accept, or which of the ones you've used were illegal.
People abuse everything, you can be dossed trying to compute <pick your hashing algorithm-of-choice> of a password as big as the maximum body size your webserver accept (which is a limit btw, so remember to dress light :-p )
I understand where it comes from (having computer systems designed by people who never spend a second thinking about your language) but still.
It’s 2024!
Here’s a ‘not meaningful’ formula then: E = L × log₂(R)
• E is the entropy, in bits, representing how hard the password is to crack.
• L is the password length (number of characters).
• R is the size of the character set (e.g., 26 for lowercase letters, 52 for upper/lowercase, 62 if digits are included).
• log₂(R) is the number of bits needed to represent each character.
I hear your point: a single password might not actually use all character types, so the actual entropy could be less than its potential. Maybe they could have drawn from a wider range and didn’t.
But for everyday user feedback, assuming the fewest sets seems fine to nudge people toward picking stronger passwords.
It's possible to read "hunter2" from /dev/random.
To infer entropy from a single password, the best you can do is to see if it falls within the domain of some known, low-entropy systems. This works ok in practice, but is very far from perfect.
Finally? It's almost been a decade since since special publication 800-63B was published recommending against silly things like composition rules and arbitrary password rotations.
I realize I'm far from a typical use case, which is why I'm so glad when people consider password ergonomics. It makes life easier for me and does not make it harder for anyone else.
Software typing of password:
Linux - ydotool / xdotool. Win/Mac have similar tools:
$ sleep 5 ; xdotool type 'RC-A"c\EJe,0l@q'
>> physical device provided by the customer.Hardware : Rubber Ducky - https://shop.hak5.org/products/usb-rubber-ducky
sleep 3; xdotool type "abc123"In your obscure set of requirements (no paste?), yes you might have to copy it again, but at least you don't have to remember it.
Your comment was interesting to me, so I was trying to come up with the most "ergonomically unsound" password. How did I do?
Have you tried entering a random password using the buttons and dials on the back of a Sony camera? After three tries, I just gave up.
With that it would be easy to build a temporary "type my secret key" dongle.
An ESP32 S2 or S3 dev kit board from a reputable source along with the other necessary hardware would probably be under $20.
There are also some models of Arduino that have the necessary USB support such as the Arduino Leonardo [2], but the Leonardo is more than an EPS32 at the non-sketchy sellers I've seen.
Even if you've never played around with microcontrollers this would be a beginner level project.
[1] https://github.com/espressif/arduino-esp32/tree/master/libra...
But that usually requires some sort of two way communication between your computer or phone and the device you are setting up or requires that the device has a network connection to a server that your phone or computer can also connect to.
You may still need to manually enter the password for that network connection.
Many WiFi streaming TV boxes are like that if I recall correctly. Manual setup to give them network access, but then later when setting up apps on them for Disney+, Netflix, and the like the apps can use an authentication protocol that doesn't need manual password entry.
I make my WiFi password easy to type for that reason.
I use a password manager but generally set it to only upper, lower and numbers and 24 characters, because so many sites seem to be broken for symbols.
But I do live in fear of the sites that are broken for long passwords (or even worse, silently broken).
The iOS keyboard layout and behavior for many years undoubtedly made password rules like this a necessity - can't be mode switching all the time just to put in a password.
Edit: Xyzzy could also be used to generate plausible drug names or RPG character names.
But there's something bigger here that stood out and that kind of makes me angry: Apple, a multi-trillion dollar company, is influencing people to stop using products by small companies and small teams.
It's stuff like this, stuff like requirements to "sign in / pay with Apple", and stuff like the green text boxes that make you have to fit everything to Apple and give them their dues.
I really wish we'd regulate or break up the big tech companies. Innovation has barriers to entry because of them.
Apple shouldn't be making their own password standard. They should work in an industry consortium to agree across the board, and they should put in the extra effort to tell users when websites may not comply with their new rules. It's not the website's fault that they didn't get the new and unannounced memo.
Add a new HTML password form property to indicate compliance with the standard before you go generating uncompliant passwords. Do a graceful migration. Stop beating up the little players.
I'm starting to think that neither Google nor Apple should be allowed to have their own web browsers. They're only using them as a means to deepen their platform reach and hobble up more control.
Pretty soon Apple and Google won't generate passwords at all. They'll deprecate the password field and mark it dangerous. Then it'll be an Apple passkey where companies will have to negotiate payment rates and won't be privileged to know their own customer.
Reasonable sites should already allow passwords of the sort Apple generates, because they tick the usual boxes (length, entropy, and the pointless at-least-one-uppercase/digit/punctuation requirement). Now, many websites are not reasonable and enforce even-more-pointless requirements. Apple tries to mitigate this with a hardcoded list of popular websites’ password policies [1], which is used to tailor password generation for those websites. To be fair, this approach doesn’t scale for smaller websites. But there’s not much more Apple could do. In any case, at this point websites have had many years to adapt to Apple’s password manager and its password style (which has not changed recently).
Accepting passkeys doesn’t cost money, and they’re based on a web standard. There are valid objections to passkeys but this ain’t it.
[1] https://github.com/apple/password-manager-resources/blob/mai...
https://github.com/apple/password-manager-resources/tree/mai...
But you can also fix it yourself if it fails. How is detailed here: https://support.apple.com/en-au/guide/iphone/iphf9219d8c9/io...
https://www.stefanjudis.com/today-i-learned/safari-allows-to...
https://github.com/whatwg/html/issues/3518
Another cool feature Apple spearheaded was the ability for websites to indicate the change password page in standard manner: https://w3c.github.io/webappsec-change-password-url/
The password generators that generate me 20 characters of different character classes are crazy.
alias genpasswd='openssl rand -rand /dev/random -base64'
Additionally I have a function in Bash that takes words from particular languages which are separated, along with "gpw" ("Generate Pronounceable Password", a C program).include only one of each I/l/1, 0/O
soundalikes without phonetics - so include only one of the following e, p, c, v, t, 3
If you already know it's in apple password format, then you know 1/17 of the letters are capital, but not which one so the number of combinations you have to try is multiplied by 17, for just over 4 additional bits of entropy.
Extra character classes can help if you're stuck needing to make a really short password for some reason, but if you're randomly generating each symbol anyway, just tossing a few more on the end is *far* more effective. You massively increase the brute force search space with each additional symbol.
On the other hand, any extra lowercase letter will increase the entropy by 4.7 bits (assuming a password on [a-z]).
Given that most passwords have at best 2 uppercase letters, I would argue it is safer to force longer passwords than passwords with at least one uppercase letter.
With the constraint that it has to be half upper/half lower you only get 252 times as many passwords instead of 1024 times as many.
"Summer2024!" is perfectly fine, if you use it for exactly one service. Frankly, "1235" is probably fine. No one is out there brute-forcing passwords.
They definitely are. I’ve been locked out of my own banks website twice because of people trying to guess the password too many times.
https://haveibeenpwned.com/Passwords says Summer2024! has been seen in two breaches, which means even if it weren't being brute forced it's less safe. 1235 has been seen significantly more times...
I'm curious if you're just being satirical here - it's not entirely obvious.
Respectfully, I disagree. "Summer2024!" is probably the second password I'd try after the username itself if I have to guess a password. Use it in a password spraying attack on a company with 500 users and you will get a few hits, I promise.
1Password should by default just always capitalize one word, and add “1” at the end of the memorable password. Since the words are separated by “-“ or “.”, you already hit the “at least one symbol” rule.
- Password must be at least 12 characters long.
- And the password must also contain either of the following:
- A phrase containing at least four unique words of three characters or longer
- or password contains at least 3 of the following qualities:
- uppercase letters
- lowercase letters
- numbers
- punctuation characters
- or more than 12 characters
I went with the phrase option.AgileBits obviously has done a lot more profiling, but it would be nice if they developed a universal password formula that was still memorable. So with words, “-“ separator (or maybe “.” separator?), maximum length 18, one whole word capitalized, random single digit at the end or beginning.
That way you keep maximum entropy, keep it readable, whilst fitting within the rules of “all” sites.
Although within 5-10 years I see passkeys having largely taken over, especially because mom and pop won’t be able to forget those, and they won’t be able to forget their fingerprint or face either.
The way it works is you have a hundred government regulators around the world, full of underpaid bureaucrats straight out of school, who introduce vague, poorly thought out requirements. The consequences of non-compliance often being existential for the business: you can lose your license, your clients, and in some cases, your freedom.
Next a bunch of lawyer/compliance-y types take those requirements from around the world and try to distil them down to a specific (but onerous) set of controls by interpreting the guidelines cautiously. Obviously all they care about is making sure that if you do get popped, you can claim you did everything in compliance with the regulations and you get to continue trading.
Often these rules are transitive too, so you need to have some level of certainty that the other parties in your supply chain are also compliant, so independent auditors spring up to provide some third party accreditation. Your CFO sees this purely as a cost and doesn't want to pay much for it, so the pressure is to make this auditing as simple as possible, so their checklists become oriented around things they can easily check to demonstrate compliance with a particular control.
So some original requirement like "it should not be possible to share passwords between multiple users" ends up being bastardised down the chain until the item on the checklist is "don't allow pasting into the password field". Obviously by this point, everyone's actually forgotten why that checklist item was created, so even if the original requirement disappears, the checklist item lives on, often, forever.
It's only in rare, high profile circumstances where a previous requirement is explicitly and noisily repudiated that old items tend to disappear. Even then it can take years. I'm still having to fight back auditors asking for mandatory monthly password changes, for example, in a system that uses passkeys...
I pity the folks who don’t know how to use dev tools.
One click and I can paste anyway. Nyah nyah nyah nyah nyah nyah.
Banks seem to really like to now allow you to paste direct deposit information, which is insane. I get that they likely are thinking, well we don't want you type it into the first field and copy it into the second.
But I am copying it right from my bank's website, being forced to type it twice is just going to make it more likely I enter an error and I can guarantee you I am looking at that first field when I am typing the verification one.
Here's the generator I built if you want to try it yourself:
That option isn't available anymore though.
I use 1Password to store it though and have since 1Password 7, maybe sooner.
[0] Not the one I'm currently using, and I don't remember which
Doing something like randomly sampling a range of a-zA-Z0-9 and all the symbols without order or structure is absolutely the worse way of doing it for passwords that humans need to type/read, or in fact anything that might get tripped by special characters (like shell scripts, etc)
Yes yes you might lose a bit of entropy, just add one or two characters to it and it will make up for it. Passwords are not so much bruteforced from zero anymore rather than leaked from places with bad password hashes
Their approach: ~71 bits per the article (I counted ~73 bits but I’m not using their exact algorithm)
I’d say it’s not too bad. With a good password hashing algorithm you’re looking at nearly 2^100 operations to bruteforce their passwords, which isn’t going to be feasible anytime soon. (Even with a crappy hash algorithm it’s still going to be over 2^80 operations).
And, in this case, that entropy trade off means the passwords are easier to remember and type in, making it more likely for humans to actually use those passwords.
Such as: i, I, l, L, o, O, 0,
Also, I think some website still have a relatively low upper limit for password length.
Website length limits are a problem though, in the worst case there are websites that silently truncate your password so you don't even realize that the first 12 (or whatever) characters are the only part that matters. If your first 12 characters are two words with a dash in the middle, that could be a real vulnerability.
Another benefit of passkeys is that it limits the ability of websites to do that kind of stupid shit.
Did you RTFA?
>> To make these passwords easier to type on suboptimal keyboard layouts like my colleague’s game controller, where the mode switching might be difficult, these new passwords are actually dominated by lowercase characters. And to make it easier to short-term have in your head little chunks of it to bring over to the other device, the passwords are based on syllables. That’s consonant, vowel, consonant patterns. With these considerations put together, in our experience, these passwords are actually a lot easier to type on a foreign, weird keyboard, in the rare instances where that might be needed for some of our users.
Having to enter a password on a streaming device is rare event for me at least. Almost all of the apps on my Roku support using an off device web browser to authenticate.
1password supports it as "memorable password".
curl https://raw.githubusercontent.com/danielmiessler/SecLists/refs/heads/master/Discovery/DNS/dns-Jhaddix.txt | grep "horse-battery-staple" sort -R /usr/share/dict/words | head -n 4| sed 's/.\*/&/;$!s/$// ' |tr '\n' '-' |sed 's/-$/\n/'
unsterilized-compoundedness-betrayer-pentathlonThere's a well-known reason for that (and for GPs comment): https://xkcd.com/936/
But you could always have an option for a different, more random-looking, style
3CatsHave12Legs!
Easy to memorize, and pretty strong.
Yet they still need to be typed on cell phone keyboards, TVs, or communicated over phone (shared passwords are the best compromise if asymmetric cryptography is not an option), in which case you usually need to spell it out anyway.
- the entity number (3)
- the kind of entity (Cats)
- the kind of part (Legs)
and that's not a huge number of combinations.
Safari also (sometimes) can recognize when “special” characters aren’t allowed, but doesn’t always work and doesn’t seem to detect password length limits, forcing me to manually adjust the password. Usually this just means deleting the hyphens and/or removing the last cluster to bring the length down to 16 or 12 characters.
Parsing out the password requirements from webpages seems like a good use for Apple Intelligence…
At the end of the day any password manager will do the job, the problem is getting people (friends & family) to use them.
And when reading this I was thinking, what about Chinese logographic writing system or Arabic alphabet? Apple has a similar password design solution but for those cases?
pwgen: aliased to pwgen --ambiguous --capitalize --numerals --symbols --secure pwgen --ambiguous --no-capitalize --secure 12
Your command produces passwords like this: X3_>r"9'
I can't even copy it by double clicking on it.Mine produces passwords like this:
stq7nt4nvh3g
It even has more entropy by one or two orders of magnitude.The main issue I face is that some web sites will either not allow passwords longer than a certain length or will only allow some special characters.
"This post briefly summarizes part of a talk I gave in 2018. All information in this post has been accessible on YouTube since then. There is no new information or news in this post."
username max 10
password min 32 - batteryhorsestaple structure - 3 languages
strong and easy
Archive.is snapshot of the article
<input type="password" passwordrules="minlength: 8; maxlength: 12; required: lower; required: upper; required: digit; required: [-];">
It seems implemented in Safari and UIKit, but I can’t find any implementation documentation for other brothers. Sad.https://developer.apple.com/password-rules/
https://developer.apple.com/documentation/security/customizi...
Oh dear, did I just reveal a secret password?
https://github.com/apple/password-manager-resources/tree/mai...
Here's a great password dictionary that only contains common English words [1]. Use 5 words and you have a 70-bit password.
It seems like many recommendations are to use at least 75-100, or even 128. Being fairly conservative, if you had 10k hosts hashing 1B passwords a second, it would take 7.5 years worst case to crack [1]. If a particular site neglects to use a slow hash function and salting, it's easy to imagine bad actors precomputing rainbow tables that would make attacks relatively easy.
You can rebut that that's still a crazy amount of computation needed, but since it's reusable, I find it easy to believe it's already being done. For comparison, if the passwords have 100 bits of entropy, it would take those same 10k servers over 4 billion years to crack the password.
[1]: (2*71 / 1e9 / 10000 / (606024*365)) ≈ 7.5
If that's not true and the password is being stored using MD5 (something that's been NIST-banned at this point for over a decade), then honestly all bets are off, and even 128 bits of entropy might not be enough.