Pre-image resistance means that, given a hash output or digest, an attacker should not be able to recover an input that produced it. Hashing behaves like blending ingredients: the result is easy to produce, but reversing it is computationally infeasible. section 2.2
Figure 2.3 Given the digest produced by a hash function (represented as a blender here), it is impossible (or technically so hard we assume it will never happen) to reverse it and find the original input used. This security property is called pre-image resistance.
Use the blender image to distinguish producing a digest from recovering the original input. section 2.2
Small spaces defeat the property
Hashing either “yes” or “no” does not hide the choice: an observer can hash both candidates and compare the results. The same weakness applies to predictable messages, such as variants of “I will be home on Monday at 3 a.m.” Pre-image resistance protects sufficiently unpredictable inputs, not tiny or guessable ones. section 2.2 section 2.3
Keep these neighboring properties separate:
- Second pre-image resistance starts with a known input and seeks a different input with the same digest. section 2.2
- Collision resistance lets the attacker choose both different inputs and seek a shared digest. section 2.2
- Digest size matters: extremely short outputs make collisions easy, while practical hash functions commonly use at least 256-bit outputs. section 2.3

