Hacker News new | ask | show | jobs
by tashbarg 667 days ago
MD5 is “broken” as a cryptographic hash function. It still is perfectly fine as a non-cryptographic hash function.
2 comments

Not really, it's slower than truncated blake3 for no gain and much loss.
There's some gain to be had in that I can reliably expect md5 to be available and compatible with pretty much anything back as far as Perl4 or PHP from the 90s, right up to bleeding edge version of Rust or Clojure or exotic language de jour.

Whether that's actually worth anything for a particular use case is a good question, and the answer will mostly be "not just no but HELL NO!"

But is it slower than sha1? Which is the alternative if you don't roll your own in V8.
About six times faster compared to sha1. Depends on the hardware/cache environment.
Yeah, if you really need non-guessability, you should be using the version that’s completely random anyways.
If you rely on non-guessability you use it as a security measure? So your sentence doesn’t invalidate previous poster.