Skip to main content
Cipher Visualizers home

Tag

#Hill Climbing

3 articles with this tag.

A visual representation of the four-square cipher breaker recovering two key squares
Basic Classic Symmetric Breakers Advanced

Breaking the Four-Square Cipher with Two Key Squares

The four-square cipher hides letter frequencies behind two keyed grids, but it is still a pencil-and-paper cipher. Learn how simulated annealing with quadgram statistics recovers both secret squares from the ciphertext alone, with runnable Python.

14 min read

A visual representation of the two-square cipher breaker recovering two key squares from a crib
Basic Classic Symmetric Breakers Advanced

Breaking the Two-Square Cipher with a Crib

The two-square cipher resists the ciphertext-only search that breaks Playfair and four-square, because it has no fixed reference squares. But a crib of known plaintext breaks it in seconds. Learn the known-plaintext attack, with runnable Python.

13 min read

A visual representation of breaking the monoalphabetic Substitution Cipher
Basic Classic Symmetric Breakers Advanced

Breaking the Substitution Cipher

A monoalphabetic substitution key is one arbitrary permutation of 26 letters: 26! of them, far too many to brute force and immune to Kasiski or the Index of Coincidence since there's no repeating key. Here's how frequency analysis and a hill-climbing search crack it anyway.

26 min read

← All tags