r/programming • • Jun 02 '17

Hacker, Hack Thyself | Coding Horror

https://blog.codinghorror.com/hacker-hack-thyself/
1.1k Upvotes

205 comments sorted by

View all comments

Show parent comments

0

u/Stoic_stone Jun 02 '17

Doesn't hashing passwords protect against that?

14

u/masklinn Jun 02 '17 edited Jun 02 '17

Depends on the hash, which is the essay's point.

A non-PRF cryptographic hash (e.g. straight MD5 or SHA) can be cracked at a few billion hashes/second. Note that MD5 and SHAs are in 4~5 figures million hashes per second per GPU. A proper KDF with a proper work factor (e.g. last time I checked Django used PBKDF2-SHA256 with 36000 iterations) is 4~5 figures hashes per second.

0

u/[deleted] Jun 02 '17

[deleted]

3

u/recycled_ideas Jun 02 '17

The problem with a salt is that you have to know what it is or be able to generate it, which means either it or the algorithm generating it and the inputs to that algorithm have to be stored somewhere and accessible to the application.

If your system is sufficiently compromised that your password hashes aren't safe, your salt probably isn't either.

→ More replies (2)