A modern software simulation of Alan Turing's legendary Bombe machine — breaking Enigma encryption through cryptanalysis
This project is an interactive cryptography simulator that demonstrates how the Enigma machine worked and how the Bombe algorithm cracked it during WWII.
| Feature | Description |
|---|---|
| Enigma Simulation | Authentic 3-rotor encryption machine with historical wiring |
| Bombe Cracking | Brute-force cryptanalysis using known plaintext attacks |
| Web Interface | No installation needed — just open index.html in a browser |
| Educational | Learn about cryptography, algorithms, and computing history |
Just open index.html in your web browser — that's it!
No Python installation, no server setup required. The entire application runs directly in your browser.
enigma-bombe-project/
├── index.html ← Open this in your browser!
└── README.md ← This file
- Configure rotor settings (III, II, I)
- Set rotor positions (AAA to ZZZ)
- Optional plugboard for advanced encryption
- Real-time encryption of plaintext to ciphertext
- Input ciphertext you want to crack
- Provide known plaintext (crib) fragment
- Specify crib position in the message
- Find matching rotor settings automatically
- View all valid solutions instantly
- Step-by-step guide with examples
- Historical context about the Enigma machine
- Tips for using the simulator effectively
The encryption signal flows through:
Plain Text
↓
┌─────────────┐
│ Plugboard │ (optional letter swap)
└──────┬──────┘
↓
┌─────────────────────────────────────┐
│ Rotor I → Rotor II → Rotor III │ (character substitution)
│ ↓ │
│ Reflector ← │ (bounces signal back)
└──────┬──────────────────────────────┘
↓
┌─────────────┐
│ Plugboard │ (swap back)
└──────┬──────┘
↓
Cipher Text
Each rotor contains 26 internal wiring connections that scramble the signal. The rotors rotate with each keystroke, creating an enormously complex encryption system.
The Bombe exploits weaknesses by testing combinations:
- Take a known plaintext fragment (crib) — e.g., "HELLO"
- Try all 17,576 rotor positions (26³)
- For each position, check if encrypting the crib produces the matching ciphertext
- Return matching settings that successfully decrypt the message
Complexity: O(n) where n = 17,576 rotor position combinations
| Setting | Value |
|---|---|
| Rotors | III, II, I |
| Positions | AAA |
| Plaintext | HELLOWORLD |
| Ciphertext | EEMLKMNFMQ |
| Input | Value |
|---|---|
| Ciphertext | XQYTUHWQD |
| Known Plaintext (Crib) | HELLO |
| Crib Position | 0 |
| Found Settings | Rotors III, II, I @ BEF ✓ |
Based on actual German Enigma machines:
Rotor I: EKMFLGDQVZNTOWYHXUSPAIBRCJ
Rotor II: AJDKSIRUXBLHWTMCQGZNPYFVOE
Rotor III: BDFHJLCPRTXVZNYEIWGAKMUSQO
Reflector: YRUHQSLDPXNGOKMIEBFZCWVJAT
| Metric | Value |
|---|---|
| Search Space | 17,576 positions |
| Time per check | O(1) constant |
| Total positions | 26³ |
| Rotor combinations | 6 (3!) |
| Max configurations | 105,456 |
This simulator teaches:
- Cryptography fundamentals — how encryption algorithms work
- Cryptanalysis techniques — breaking codes using weaknesses
- Algorithm optimization — efficient brute-force searching
- Computing history — early automated cryptanalysis machines
- Mathematical logic — rotor stepping and signal flow
Alan Turing and the Bletchley Park team (1940–1945)
The original Bombe machine was an electromechanical device that could test hundreds of rotor configurations per second. This breakthrough was crucial to WWII intelligence and is considered one of the earliest examples of large-scale automated cryptanalysis.
The Enigma was thought unbreakable by the Nazis, but the Bombe proved them wrong. The intelligence gained from breaking Enigma is estimated to have shortened WWII by several years.
GitHub: github.com/Strongf-bob/enigma-solver
| Field | Details |
|---|---|
| Name | Karsakov Ilya Vyacheslavovich |
| Year | 2025 |
| GitHub | @Strongf-bob |
| karsakovillya@yandex.ru | |
| Telegram | @nicto999 |
This is an educational project created for portfolio purposes. Use freely for learning and teaching cryptography!
- Turing, A. M. (1936). "On Computable Numbers" — Proceedings of the London Mathematical Society
- Welchley, G. (1946). "From Polish Bomba to British Bombe" — History of Computing Project
- Gannon, P. (2006). "Colossus: Bletchley Park's Greatest Secret and the Birth of the Modern Computer"
- The National Museum of Computing — "The Enigma Machine and the Bombe"
Learn cryptography by breaking the unbreakable.