https://blog.agilebits.com/2011/05/05/defending-against-crac...
How to Safely Store Your Users' Passwords in 2016
31–40 of 321 posts
Re: How to Safely Store Your Users' Passwords in 2016
#32> ...
> The above construction may invite theoretical concerns about entropy reduction (i.e. 72 characters of raw binary without any NUL bytes comes out to about 573 bits of possible entropy, but a SHA-384 hash outputs are clearly limited to 384 bits).
Given BCrypt hashes are a mere 184 bits, I don't see how this is a meaningful concern even in principle. If you're brute-forcing search spaces this big you're no longer looking to recover a password, but find a collision.
Re: How to Safely Store Your Users' Passwords in 2016
#33Re: How to Safely Store Your Users' Passwords in 2016
#34Earlier quoted context omitted.
Everything is asynchronous but the linked article uses the synchronous versions of the functions for some reason... async versions exist and are recommended[1] [1] https://github.com/ncb000gt/node.bcrypt.js#async-recommended
Do the async methods actually execute on a thread pool though? Or do they use enough async methods internally to periodically release the main thread enough to keep it responsive? From a quick glance at the source, the answer to the first is no.
Re: How to Safely Store Your Users' Passwords in 2016
#35> base64_encode(hash('sha384', $password, true)) > ... > The above construction may invite theoretical concerns about entropy reduction (i.e. 72 characters of raw binary without any NUL bytes comes out to about 573 bits of possible entropy, but a SHA-384 hash outputs are clearly limited to 384 bits). Given BCrypt hashes are a mere 184 bits, I don't see how this is a meaningful concern even in principle. If you're bru…
This was added in response to a point that a couple people (or perhaps a convincing sockpuppeteer) raised and tried to use to decry the entire article. You're lucky to get 60 bits of information entropy in any given user's password, as is. The "theoretical weakening" here isn't a practical concern: "2^192 security" is still boring crypto.
Re: How to Safely Store Your Users' Passwords in 2016
#36Does Argon2 have an official website and repo or is it just the PHC repo?
Re: How to Safely Store Your Users' Passwords in 2016
#37For some reason the article completely fails to link to libsodium: https://download.libsodium.org/doc/
The "bindings for most programming languages" link goes to the libsodium documentation, but I'll add a link in more contexts.
Re: How to Safely Store Your Users' Passwords in 2016
#38I had no idea that PBKDF2 had fallen so much in recent years. I still remember the 1Password team extolling its virtues five years ago: https://blog.agilebits.com/2011/05/05/defending-against-crac...
PBKDF2 is an improvement over PBKDF1 (and other naive iterated hash constructions), but attacks got better and better defenses are called for.
Re: How to Safely Store Your Users' Passwords in 2016
#39Don't. Unless it's 100% absolutely necessary.
If you must, continue reading on.
Re: How to Safely Store Your Users' Passwords in 2016
#40For anyone who reads the comments before clicking the article, the subject is storing your users' passwords, not managing your passwords for a variety of services. I had interpreted it as the latter. A better title might be "How to Safely Store Your Users' Passwords in 2016". (Title is currently: "How to Safely Store a Password in 2016")