liveBook · Manning

Time-space tradeoff

As explained in Hacking Cryptography

A design trade-off in which additional storage or memory reduces computation time, or reduced storage increases computation time.

A time-space tradeoff exchanges storage for computation: storing fewer guesses saves space but requires more hashing during a dictionary attack. section 6.0 section 6.4.2

Hash chains apply a hash function and a deterministic reduction function repeatedly, retaining chain endpoints and reconstructing candidates when a target digest matches. section 6.4.2

The tradeoff appears in the attack workflow:

  • Store complete password-to-digest mappings for immediate lookups, or store compact chain representations that require recomputation. section 6.4.2
  • Generate chains from candidate passwords, alternating SHA-256 hashing with reduction; rainbow tables vary the reduction by column to limit collisions. section 6.4.2
  • Search backward from the target digest, locate a matching endpoint, then traverse the chain to verify the recovered password. section 6.4.2

Rainbow-table attack

The Go implementation generates five million chains for six-character passwords, stores their endpoints, and tests the resulting table against 100 unsalted SHA-256 password digests.

Figure 6.10 Hash chains alternatively apply a hash function and a reduction Function.
figure

Shows the alternating hash-and-reduction structure that makes chain storage smaller than complete guess tables. section 6.4.2

How Hacking Cryptography covers it

How deep it goes
Explains chain construction, collision reduction, endpoint lookup, and verification through executable Go implementations.
Examples
Uses PIN dictionaries, SHA-256 chains, Go code, stored table endpoints, and a 100-user cracking test.
What it assumes
Assumes hash digests and one-wayness while defining reduction functions and chain mechanics through examples.
What you can do after
Evaluate/understand how attackers compress password-guessing tables and recover candidates through recomputation.
How it connects
Connects hash functions, one-wayness, dictionary attacks, rainbow tables, password hashing, and salts.

Also explained in

Compare how 2 books explain time-space tradeoff →

This explainer was generated by Manning's knowledge graph from the text of Hacking Cryptography. The section links point to the parts of the book it draws on.