by FredericJ · 13y ago · 0 comments
How do you store the Buffer passwords? SHA1(password+salt)?
Edit (T+7 minutes): Rewritten to not be a jerk.
Every little bit helps.
This is exactly why they are not particularly well suited to passwords. A brute-force attack (since you're salting your passwords I'm sure!) against them isn't a huge undertaking. Just with the equipment in the computer I'm on right now, I'm looking at generating about 11.5b MD5 hashes per second, or 3.1b SHA1 hashes per second.
At eight characters a-zA-Z0-9, I'm looking at about 5 and a half minutes to brute force every combination with MD5. Under a day for SHA1.
Hashes like bcrypt and scrypt, on the other hand, are designed to be slow. Their complexity factors actually provide means to slow the hashes down even further as hardware becomes faster. Instead of 11.5b/second, you can increase the complexity until you're only able to generate one hash per second... Now it takes you over three and a half centuries to hash what might take one second with MD5.
Even ignoring the possibilities of MD5/SHA1 being 'broken', they're simply too fast to be considered for hashing passwords.
(Estimates of GPU hashing speed taken from http://golubev.com/gpuest.htm).
How To Safely Store A Password http://codahale.com/how-to-safely-store-a-password/