CODEX ARCANUM — CIPHERS
← BACK TO CONTROL CENTER

// CODEX ARCANUM //

secrets from all time.
Ancient Times
Before what we know as encryption, people were creative about how to keep secrets. They shifted letters, mirrored the alphabet or encoded messages in a grid. These systems were not unbreakable to the educated enemy, but same as we have today, it was a cat and mouse game of good guy/bad guy...invention and code breaking.
[ CAESAR CIPHER ]
circa 58 BC — Roman Republic
Julius Caesar allegedly used a shift-of-three cipher whenever he needed to send private messages to his people or the Roman Army. Suetonius, cough, documented it in The Life of Julius Caesar: "If he had anything confidential to say, he wrote it in cipher, that is, by so changing the order of the letters of the alphabet, that not a word could be made out." It is really simple. Each letter shifts forward by a fixed number. with a shift of 3, A=D, B=E, Z=C. Broken easily by frequency analysis (finding the frequent letters or groups in a ciphertext. Think "of","I" etc and pretty soon you know how to break the cipher), but possibly effective against an enemy who had never seen anything like it. You usually see a ROT 13 variant of this in quiz or crossword answers.
SHIFT:
[ ATBASH CIPHER ]
circa 600 BC — Hebrew scribes
Atbash could be the oldest cipher, it was initially used by the bible dorks of old. We still have those guys even today. Its name comes from first 2 and last 2 letters of the Hebrew alphabet: First:Aleph Last:Taw, 2nd:Beth,2ndLast:Shin. In the english alphabet the cipher is like A=Z B=Y, C=X. Its a mirror of the alphabet. The ancient book of Jeremiah has some Atbash, and it was written before 600bc. Encoding and decoding are actually the same in this case due to it being a perfect mirror of itself.
ABCDEFGHIJKLM
ZYXWVUTSRQPON
NOPQRSTUVWXYZ
MLKJIHGFEDCBA
[ POLYBIUS SQUARE ]
circa 150 BC — Ancient Greece
Invented by the Greek historian, Polybius, this cipher encodes each letter as a pair of coordinates in a 5×5 grid. Polybius thought it could be used for long-distance fire signaling using torches. The grid, and actually a lot of ciphers do something like this, merges I and J into one cell to fit 25 letters. Each letter becomes row/column digits — "HELLO" becomes 23 15 31 31 34. Later adapted into the famous tap code used by American POWs 🫡. PBS has a cool article on this. In this example, spaces are represented by / when enciphered.
Renaissance / Early Modern
As time progressed, ciphers naturally became more complex. Cryptographers moved beyond simple substitution toward polyalphabetic systems — morphing different strategies which defeated frequency analysis.
[ VIGENÈRE CIPHER ]
1553 AD — Giovan Battista Bellaso
Named after Blaise de Vigenère. The actual person that came up with this was Giovan Battista Bellaso. This is an example of a polyalphabetic cipher. This is a cipher where you use a key to determine different ROT Caesar ciphers. The keyword determines the shift for each letter. If the key is KEY, then the 1st letter shifts by K(10), the 2nd by E(4), the 3rd by Y(24), then repeats. If you get to the end of the alphabet you wrap around. This caused frequency analysis to not be possible and was even called "le chiffre indéchiffrable" French for the undecipherable cipher. It wasn't broken for over 300 years until Charles Babbage broke it in the 1800s. Weirdly enough he didn't publish the solution, probably because he was an advisor and a spy and wanted to use it for himself. Later, Friedrich Kasiski published the solution in 1863. The Vigenère cipher is used a lot for teaching modern cryptography, but it has been cracked, and is not secure for any real use.
KEY:
[ ROT13 ]
1980s — Usenet bulletin boards
ROT13 is a Caesar cipher with a shift of 13. The alphabet has 26 letters, doing it twice causes it to be deciphered. Encode and decode are the same. It emerged on Usenet newsgroups in the early 1980s to hide offensive jokes, answers and spoilers. Anyone who knows the system can read it instantly.
The Telegraph Era
The electric telegraph was invented in the 1800s as the first modern long distance instant communication. New codes emerged not for secrecy but for ease of transmission
[ MORSE CODE ]
1837 AD by Samuel Morse & Alfred Vail
created specifically for the electric telegraph, Morse code maps letters and numbers to short (·) and long (−) signals. The first official Morse message ; "What hath God wrought" was sent between Washington DC and Baltimore MD on May 24, 1844. Common letters got short codes (E = · , T = −) based on their frequency in English. The distress signal SOS (··· −−− ···) was chosen because it is simple, it does not actually stand for anything. Morse is still used in amateur radio, aviation beacons, and maybe the military. Use / to separate words when decoding.
Industrial era & First and second World Wars
The big wars of the 20th century were a boom for cryptography. Actual mechanical cipher machines started to be created and used, able to create ciphertexts of with extra complexity. Adversaries had to create complex machines to try and break the new ciphers. Some say this was the beginning of modern computing.
[ ENIGMA MACHINE ]
1930 AD The Enigma Machine
The Enigma machine had rotors that could be picked and their values changed, ring settings (Ringstellung), a reflector, starting positions (Grundstellung), and a plugboard (Steckerbrett). There were several versions of these machines which were generally compatible with each other. The Cipher Bureau of Poland actually started breaking some cyphers created on the Enigma in 1932 and had major success. By 1939 they even shared their work with the French, which would be instrumental in winning WWII. Their work was the beginning of modern cryptanalysis. Enigma is symmetric which means it is enciphers and deciphers the message with the same settings. The below example tries to model the common Wehrmacht three-rotor setup with rotors I-V, Reflector B, ring settings, double-stepping, and even the plugboard pairs in later machines.
ROTORS:
POSITIONS:
RINGS:
PLUGBOARD:
[ ONE-TIME PAD ]
1882 / 1917 AD — Frank Miller & Gilbert Vernam
The one-time pad is actually the only cipher that has been mathematically proven to be unbreakable. This is of course if the key is random, as long or longer than the message, and not reused. Gilbert Vernam patented it in 1919. Both the NSA and KGB used it for decades, even sending seemingly random numbers using short wave radio. This was referred to as a "numbers station." The Washington/Moscow hotline apparently used a one-time pad until 2008. Its fatal flaw is how to distribute the secret key. If your enemy gets the key, the cipher is easily broken. Wikipedia actually has an audio recording of one of these stations. Super cool to be able to put your secrets on main! Shows confidence and a sigma ayyitudeNumbers Station
KEY:
[ PLAYFAIR CIPHER ]
1854 AD — Charles Wheatstone / Lord Playfair
This cipher was invented by Charles Wheatstone but named after Lord Playfair, understandable. Actually though it is because he got the British Foreign Office to use it. It was the first cipher to encrypt letter pairs digraphs instead of single letters to defeat frequency analysis. The British used it in WWI and Australia used it in WWII. A keyword fills a 5×5 grid (I and J share a box cause 25 letters 5*5). Letter pairs are enciphered by their geometric relationship with the grid. In the same row you shift right, in the same column you shift down, each letter takes the other letter’s column while staying in its own row.
KEYWORD:
Modern & Digital Era
The computer era changed a lot of stuff. Unsurprisingly there was a new grade of cipher built on math and boolean logic instead of letter shifts. A lot of these are used in Capture the Flag (CTF) challenges.
[ XOR CIPHER ]
20th century the beginning of encryption
XOR (exclusive OR) is a boolean operation. Two identical bits produce 0, two different bits produce 1. When it is applied to text, each byte of the message is XORed against a repeating key byte. XOR is symmetric so the exact same operation deciphers it. XOR is the building block inside Advanced Encryption Standard (AES) and pretty much every modern cipher. On its own with a short repeating key it can be broken by frequency analysis, but with a key as long as the message (a one-time pad), it is unbreakable. Key and ciphertext are shown as hexadecimal.
KEY:
[ BACON'S CIPHER ]
1605 AD — Sir Francis Bacon
Francis Bacon devised this cipher as a form of steganography — the act of hiding a message in another message. Each letter is encoded as a unique 5 char sequence of A's and B's (A=AAAAA, B=AAAAB … Z=BABBB), which would then be concealed in text by alternating two fonts. The method could hide secret messages inside any book. It came back as during the computer age for binary encoding and it remains as another likely CTF puzzle variant. Historical Bacon alphabets have many variants. Most implementations use the commonly merged I/J form.
[ RAIL FENCE CIPHER ]
Civil War era... transposition by zigzag
The rail fence cipher is a transposition cipher. It re-orders the letters instead of substituting them. The text is written in a zigzag pattern across a number of "rails" (rows), then it is read off row by row. With 3 rails, "WEAREDISCOVERED" becomes "WECRLTEERDSOAIVD". Some evidence suggests it was used in the American Civil War. Once again this one does not offer any protection against a modern attacker or a wise old one, but it's a good intro to the rearrange vs. replace concept and it is another one that shows up in CTF challenges.
RAILS:
Simple substitution cipher: The cipher operates on single letters.
Polygraphic cipher: A cipher that uses larger groups of letters.
Monoalphabetic cipher: Fixed substitution over the entire message.
Polyalphabetic cipher: A number of different type substitutions in the message.
Cryptanalysis: The study of analyzing and breaking ciphers.
Frequency analysis: Studying how often letters or symbols appear in ciphertext to deduce the underlying substitution, effective against simple substitution ciphers.
Numbers Station: Broadcasting what seems like random numbers to decipher secret codes. See one-time pad communication.
Digraphs: Pairs of letters treated as a single unit in certain ciphers, popularized with the Playfair cipher.
Boolean logic: A form of algebra in which all values are either true or false, used by computers.
Capture the Flag (CTF): A type of cybersecurity competition where participants solve challenges, often involving cryptography. Find out more on the Wikipedia page.
Symmetric cipher: A cipher that uses the same key for both encryption and decryption.
Asymmetric cipher: An asymmetric cipher uses different keys for encryption and decryption, often referred to as public-key cryptography.
Hexadecimal: A base-16 number system using digits 0-9 and letters A-F, commonly used in computing and cryptography.
Steganography: The act of hiding a message or file in another medium such as text, images, or audio.
Transposition cipher: A cipher that rearranges the letters of the plaintext to create the ciphertext, without changing the actual letters.

Bonus words

Cryptographic primitives: Basic algorithms and protocols that serve as the building blocks for cryptographic systems, such as hash functions, encryption algorithms, and digital signatures.
Symmetric encryption: The same key is used for both encryption and decryption. It's fast and efficient, which is why it's used for the actual bulk encryption of data (e.g. AES) — this makes it the more common encryption in terms of amount of data encrypted.
Public-key cryptography (asymmetric encryption): Cryptography that uses key pairs: public keys, which are allowed to be shared, and private keys, which are a secret known only to the owner. It's slower and more computationally expensive than symmetric encryption, so it's typically used for smaller jobs like exchanging a key or signing data — like a certificate in your browser. This is the most common form of cryptography by number of transactions, and is used for secure communications on the internet via "certificates".
Integer factorization: The process of determining the prime factors of a composite number. This is a hard problem for normal computers, and is the basis for the security of RSA encryption.
Discrete logarithm problem: The challenge of finding the exponent in the equation \( g^x \equiv h \mod p \), where \( g \) is a generator of a finite group, \( h \) is an element of that group, and \( p \) is a prime number. This problem is considered hard for normal computers and is the foundation of security of many cryptographic systems like RSA or elliptic curve cryptography.

Double Bonus words

Diffie-Hellman key exchange: A method of securely exchanging cryptographic keys over a public channel. It relies on the difficulty of the discrete logarithm problem for its security.
Elliptic Curve Cryptography (ECC): A form of public-key cryptography based on the algebraic structure of elliptic curves over finite fields. It offers similar security to RSA but with smaller key sizes.
Rivest-Shamir-Adleman (RSA): A widely used public-key cryptosystem that relies on the difficulty of factoring large composite numbers. It is used for secure data transmission.
Gradient descent: An optimization algorithm used to minimize functions by iteratively moving towards the steepest descent as defined by the negative of the gradient. Used in machine learning.
Side-channel attack: An attack that exploits information gained from the physical implementation of a cryptosystem, such as timing information, power consumption, electromagnetic leaks, or even sound, rather than weaknesses in the algorithms themselves.
Kyber Crystals: The crystals used to power Lightsabers. Also now a NIST standard.
The Quantum Leap & Beyond
Current cryptography relies on being able to create encryption that computers cannot break. But quantum computers do not work the same way as what we know as computers today. A well performing quantum computer would be able to break most asymmetric encryption in hours. At the same time, AI is changing how we approach cryptography itself by pattern analysis, creating new cryptographic primitives and solving puzzles. The future of ciphers will require mathematics too hard for any machine to break.
[ THE QUANTUM THREAT ]
Shor's Algorithm — 1994 / Present
Almost all public-key cryptography in use today — RSA, Diffie-Hellman key exchange, elliptic-curve cryptography (ECC) etc. Works by relying on two problems that normal computers find particulary difficult to solve for: integer factorization and the discrete logarithm problem. A 2048-bit RSA key would take a normal computer longer than infinity plus one to crack by brute force.

In 1994 a mathematician by the name of Peter Shor published an algorithm that potentially solves both problems exponentially faster on a quantum computer. A big enough quantum computer running Shor's algorithm could solve a 2048-bit RSA key in hours. It would be able to nuke ECC and break the entire certificate mechanism used for HTTPS (secure traffic on the web), SSH, and virtually every form of asymmetric encryption.

Three letter agencies are likely collecting all the data they can now to decrypt later, waiting for the quantum hardware that can break it. Timelines for actually getting good quantum have been talked about for years and they are still saying it could be even 30 years out.

Symmetric encryption (AES) and hash functions (SHA-256) are actually pretty resilient to quantum. Grover's algorithm can speed up the process, cutting the time in half, which means AES-256 could survive quantum. The acute danger is in asymmetric and key-exchange cryptography.
[ AI THREAT ]
Present
Artificial intelligence can't break modern ciphers through brute force. AES and ChaCha20 have no weakness that gradient descent (a machine learning tactic) can exploit.

AI makes a known hardware-hacking technique called a side-channel attack faster and more efficient. Attackers need less data to steal a cryptographic key by "listening" to a chip's physical behavior. Neural networks have cracked hardware AES that were extremely difficult and time consuming to break with traditional methods.

Language models that are trained on leaked credential databases can generate highly targeted password guesses that far outperform dictionary and rule based attacks and rainbow tables. The weak point is the human that chose the password now.

While not specifically breaking cryptography itself, AI code analysis has increased the number of vulnerability findings in cryptographic libraries.

Machine learning is being used to detect encrypted traffic and even assist in the design of new algorithms.
[POST-QUANTUM]
NIST PQC Standards 2024
NIST — the US government's standards body for tech, spent a lot of time trying to get community support. In August 2024 they released official standards.

ML-KEM (formerly known as Kyber): the new way that two computers agree on a secret key over the internet. Already being used in Chrome and Cloudflare. There is a great slide deck that talks about how it is good and has plans to get better.

ML-DSA (formerly Dilithium) & FALCON: these are the new digital signatures which will be replacing RSA and ECDSA as the math that proves something actually came from the real sender.

SLH-DSA (formerly SPHINCS+): this is a signature built on totally different math, actually kept as a backup in case a flaw ever turns up in the others.

NIST isn't done. A fourth algorithm, HQC, was added in 2025 as a second, independent key-exchange option, also not used until needed.

The migration from RSA/ECC to post-quantum algorithms is one of the largest coordinated infrastructure changes in the history of the internet. And you are here to see it! Source: NIST Post-Quantum Cryptography Project
[ SPECULATION ]
What Lies Ahead
Obviously, quantum is not even here yet. But cryptography research continues.

Fully Homomorphic Encryption (FHE): Allows computation of encrypted data. A server could process your data without ever seeing it in plaintext. Proven as a concept by Craig Gentry's 2009 thesis at Stanford, FHE is extremely slow. Some day if we get the compute power we will be doing this kind of thing.

Quantum Key Distribution (QKD): Uses the laws of quantum physics. Measuring a quantum state disturbs the state. This would solve the age old secret key transfer problem. You could distribute a key and know for sure that no one has even attempted to observe it.

Zero-Knowledge Proofs (ZKPs): Allow a party to prove they know something like a password, a private key, or a transaction's validity without revealing any information about what they know. ZKPs are the bedrock of modern blockchain privacy protocols and are increasingly used in authentication. Once hardware is able to keep up, this could replace password authentication.

Indistinguishability Obfuscation (iO): ensures that programs computing the same function cannot be distinguished from one another. With iO, you could build encryption, signatures, and other crypto tools from scratch. Still just a theory.