awesome-everything RU
↑ Back to the climb

Security

Password hashing: free-recall review

Crux Free-recall prompts across the password-hashing unit. Answer each in your own words first, then reveal the model answer and compare.
Your altitude — climbing toward senior
ZeroJuniorMiddleSenior
You are at senior altitude — in orbit
◷ 14 min

Retrieval beats re-reading. For each prompt, say or write a full answer from memory before you open the model answer — the effort of recall is what makes the material stick.

Goal

Reconstruct the unit’s core mechanisms — why fast hashes lose, what a salt and a pepper each do, why memory-hardness beats raw slowness, how the work factor migrates, and why you never roll your own compare — without looking back at the lesson.

Recall before you leave
  1. 01
    Why is a fast general-purpose hash like SHA-256 the wrong tool for storing passwords, even with a per-user salt?
  2. 02
    What is the difference between a salt and a pepper, and where does each one live?
  3. 03
    Why does memory-hardness cripple an attacker more than simply raising a CPU-bound iteration count?
  4. 04
    Name the three accepted modern algorithms with their OWASP parameters, and say when PBKDF2 is the right call.
  5. 05
    What is bcrypt's 72-byte trap, how has it caused real auth bypasses, and what is the correct fix?
  6. 06
    How do you keep the work factor current over time, and why must password comparison be constant-time?
Recap

If you could reconstruct each answer from memory, you hold the unit’s spine: the defended attack is offline cracking at full hardware speed, which makes fast hashes the wrong tool; a per-user salt (public, in the row) defeats rainbow tables while a pepper (secret, outside the DB) defends a DB-only leak; memory-hardness beats raw slowness by attacking GPU parallelism; the accepted algorithms are Argon2id (preferred), scrypt, and bcrypt (with PBKDF2 only under FIPS), each with named OWASP parameters; bcrypt’s 72-byte truncation is a real footgun; and the work factor rises on a schedule via rehash-on-login, with every comparison done in constant time by the library, never by hand.

Continue the climb ↑Password hashing: code review
shortcuts expand
search
K
prev piece
k
next piece
j
cycle tier
t
this menu
?
sources2
expand
  1. 01
  2. 02

Trademarks belong to their respective owners. Editorial reference only.