Running popular cryptographic hash functions

A cryptographic hash function has specific properties that make it different from other hash functions. First of all, producing a possible input message from a given hash digest output should be intractable, meaning that it must take an exponentially long time to solve in practice.

For example, if a hash produces the digest 66fc01ae071363ceaa4178848c2f6224, then in principle, discovering the content used to generate a digest should be difficult.

In practice, some hash functions are easier to crack than others. For example, MD5 and SHA-1 are considered trivial to crack and should not be used, but are demonstrated later for completeness. More information about how MD5 and SHA-1 are insecure can be found ...

Get Haskell Data Analysis Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.