About Lorenz
The Lorenz SZ40/42 cipher attachment was a WW2 German rotor cipher machine with twelve rotors which attached in-line between remote teleprinters. It used the Vernam cipher with two groups of five rotors (named the psi(ψ) wheels and chi(χ) wheels at Bletchley Park) to create two pseudorandom streams of five bits, encoded in ITA2, which were XOR added to the plaintext. Two other rotors, dubbed the mu(μ) or motor wheels, could hold up the stepping of the psi wheels meaning they stepped intermittently. Each rotor has a different number of cams/lugs around their circumference which could be set active or inactive changing the key stream. Three models of the Lorenz are emulated, SZ40, SZ42a and SZ42b and three example wheel patterns (the lug settings) are included (KH, ZMUG & BREAM) with the option to set a custom set using the letter 'x' for active or '.' for an inactive lug. The input can either be plaintext or ITA2 when sending and ITA2 when receiving. To learn more, Virtual Lorenz, an online, browser based simulation of the Lorenz SZ40/42 is available at lorenz.virtualcolossus.co.uk. A more detailed description of this operation can be found here.
Input: text. Output: text.
Format reference: Lorenz background and specification
Example
Use “Try example” to load this public sample and its settings, then run it.
Settings used in this example
| Parameter | Example value | Input and choices |
|---|---|---|
| Model | SZ40 | SZ40, SZ42a, SZ42b |
| Wheel Pattern | "No Pattern" | KH Pattern, ZMUG Pattern, BREAM Pattern, No Pattern, Custom |
| KT-Schalter | false | On or off |
| Mode | "Send" | Send, Receive |
| Input Type | Plaintext | Plaintext, ITA2 |
| Output Type | Plaintext | Plaintext, ITA2 |
| ITA2 Format | 5/8/9 | 5/8/9, +/-/. |
| Ψ1 start (1-43) | 1 | Number |
| Ψ2 start (1-47) | 1 | Number |
| Ψ3 start (1-51) | 1 | Number |
| Ψ4 start (1-53) | 1 | Number |
| Ψ5 start (1-59) | 1 | Number |
| Μ37 start (1-37) | 1 | Number |
| Μ61 start (1-61) | 1 | Number |
| Χ1 start (1-41) | 1 | Number |
| Χ2 start (1-31) | 1 | Number |
| Χ3 start (1-29) | 1 | Number |
| Χ4 start (1-26) | 1 | Number |
| Χ5 start (1-23) | 1 | Number |
| Ψ1 lugs (43) | ".x...xx.x.x..xxx.x.x.xxxx.x.x.x.x.x..x.xx.x" | Text |
| Ψ2 lugs (47) | ".xx.x.xxx..x.x.x..x.xx.x.xxx.x....x.xx.x.x.x..x" | Text |
| Ψ3 lugs (51) | ".x.x.x..xxx....x.x.xx.x.x.x..xxx.x.x..x.x.xx..x.x.x" | Text |
| Ψ4 lugs (53) | ".xx...xxxxx.x.x.xx...x.xx.x.x..x.x.xx.x..x.x.x.x.x.x." | Text |
| Ψ5 lugs (59) | "xx...xx.x..x.xx.x...x.x.x.x.x.x.x.x.xx..xxxx.x.x...xx.x..x." | Text |
| Μ37 lugs (37) | "x.x.x.x.x.x...x.x.x...x.x.x...x.x...." | Text |
| Μ61 lugs (61) | ".xxxx.xxxx.xxx.xxxx.xx....xxx.xxxx.xxxx.xxxx.xxxx.xxx.xxxx..." | Text |
| Χ1 lugs (41) | ".x...xxx.x.xxxx.x...x.x..xxx....xx.xxxx.." | Text |
| Χ2 lugs (31) | "x..xxx...x.xxxx..xx..x..xx.xx.." | Text |
| Χ3 lugs (29) | "..xx..x.xxx...xx...xx..xx.xx." | Text |
| Χ4 lugs (26) | "xx..x..xxxx..xx.xxx....x.." | Text |
| Χ5 lugs (23) | "xx..xx....xxxx.x..x.x.." | Text |
Input
HELLO WORLD, THIS IS A TEST MESSAGE.
Result
HELLO9WORLD55N889THIS9IS9A9TEST9MESSAGE55M
Parameters
| Parameter | Default value | Input and choices |
|---|---|---|
| Model | SZ40 | SZ40, SZ42a, SZ42b |
| Wheel Pattern | "KH Pattern" | KH Pattern, ZMUG Pattern, BREAM Pattern, No Pattern, Custom |
| KT-Schalter | false | On or off |
| Mode | "Send" | Send, Receive |
| Input Type | Plaintext | Plaintext, ITA2 |
| Output Type | Plaintext | Plaintext, ITA2 |
| ITA2 Format | 5/8/9 | 5/8/9, +/-/. |
| Ψ1 start (1-43) | 1 | Number |
| Ψ2 start (1-47) | 1 | Number |
| Ψ3 start (1-51) | 1 | Number |
| Ψ4 start (1-53) | 1 | Number |
| Ψ5 start (1-59) | 1 | Number |
| Μ37 start (1-37) | 1 | Number |
| Μ61 start (1-61) | 1 | Number |
| Χ1 start (1-41) | 1 | Number |
| Χ2 start (1-31) | 1 | Number |
| Χ3 start (1-29) | 1 | Number |
| Χ4 start (1-26) | 1 | Number |
| Χ5 start (1-23) | 1 | Number |
| Ψ1 lugs (43) | ".x...xx.x.x..xxx.x.x.xxxx.x.x.x.x.x..x.xx.x" | Text |
| Ψ2 lugs (47) | ".xx.x.xxx..x.x.x..x.xx.x.xxx.x....x.xx.x.x.x..x" | Text |
| Ψ3 lugs (51) | ".x.x.x..xxx....x.x.xx.x.x.x..xxx.x.x..x.x.xx..x.x.x" | Text |
| Ψ4 lugs (53) | ".xx...xxxxx.x.x.xx...x.xx.x.x..x.x.xx.x..x.x.x.x.x.x." | Text |
| Ψ5 lugs (59) | "xx...xx.x..x.xx.x...x.x.x.x.x.x.x.x.xx..xxxx.x.x...xx.x..x." | Text |
| Μ37 lugs (37) | "x.x.x.x.x.x...x.x.x...x.x.x...x.x...." | Text |
| Μ61 lugs (61) | ".xxxx.xxxx.xxx.xxxx.xx....xxx.xxxx.xxxx.xxxx.xxxx.xxx.xxxx..." | Text |
| Χ1 lugs (41) | ".x...xxx.x.xxxx.x...x.x..xxx....xx.xxxx.." | Text |
| Χ2 lugs (31) | "x..xxx...x.xxxx..xx..x..xx.xx.." | Text |
| Χ3 lugs (29) | "..xx..x.xxx...xx...xx..xx.xx." | Text |
| Χ4 lugs (26) | "xx..x..xxxx..xx.xxx....x.." | Text |
| Χ5 lugs (23) | "xx..xx....xxxx.x..x.x.." | Text |
Before interpreting the result
Use the exact key encoding, mode, padding and IV expected by the source system. Historical ciphers are useful for learning and analysis. Encoding alone provides no confidentiality.
How to use this page
- Paste your input or open a local file.
- Adjust tool options if needed, then choose Run tool.
- Copy the result or download the original output bytes.
Inputs and results are not added to the public catalogue or saved in the URL. Processing happens in your browser; HTTP Request and DNS over HTTPS send the requests you explicitly run. Files up to 128 MiB can be opened; decompression and image tools may have smaller processing limits. Large results have a shortened preview. Text and HTML downloads use UTF-8; binary downloads preserve output bytes. Pasted text follows browser newline handling; open a file when exact input bytes matter.