Lion Cipher Lab

See how encryption fails: ECB leaks, IV reuse, and why you need authenticated encryption

Why it matters

"We encrypted it" is one of the most dangerous half-truths in security. Encryption keeps a secret ONLY if you pick the right mode and use it correctly — and the defaults people reach for are full of traps. This lab is specifically about symmetric encryption MODES and how they fail, which is different from the neighbouring basics: encoding (gs-encoding-basics) is reversible-by-anyone and not encryption at all; hashing (gs-password-hashing-basics) is one-way and not reversible; verifying a hash (gs-hash-and-verify) proves integrity but hides nothing. Here you'll watch a supposedly-encrypted…

What you'll learn

Steps in this lab

  1. What you're about to prove (and why it isn't obvious)
  2. Set up and generate a test image
  3. Encrypt with ECB — and watch the picture survive
  4. Switch to CBC with a random IV — the pattern disappears
  5. Reuse the IV — and leak that two messages match
  6. CBC hides the message — but does NOT protect it
  7. AES-GCM — authenticated encryption that catches the tampering
  8. The judgment: don't assemble primitives — pick a safe default

Open the full interactive lab →