All Projects → emedvedev → enigma

emedvedev / enigma

Licence: other
Enigma cipher machine emulator (CLI + library) written in Go

Programming Languages

go
31211 projects - #10 most used programming language

Projects that are alternatives of or similar to enigma

pyEnigma
Python Enigma cypher machine simulator.
Stars: ✭ 44 (-12%)
Mutual labels:  enigma, enigma-simulator, enigma-machine
ultra
Cryptanalysis of the Enigma machine in Rust.
Stars: ✭ 14 (-72%)
Mutual labels:  enigma, enigma-machine
ENIGMA
The ENIGMA Toolbox is an open-source repository for accessing 100+ ENIGMA statistical maps, visualizing cortical and subcortical surface data, and relating neuroimaging findings to micro- and macroscale brain organization. 🤠
Stars: ✭ 66 (+32%)
Mutual labels:  enigma
enigma-docker-network-deprecated
A containarized Enigma Protocol environment to start writing secret contracts
Stars: ✭ 50 (+0%)
Mutual labels:  enigma
SecretNetwork
𝕊 The Secret Network
Stars: ✭ 466 (+832%)
Mutual labels:  enigma
discovery-cli
Command Line Interface (CLI) for the Discovery Enigma Protocol developer testnet
Stars: ✭ 12 (-76%)
Mutual labels:  enigma
enigma-go
Go library for consuming Qlik's Associative Engine.
Stars: ✭ 36 (-28%)
Mutual labels:  enigma

Enigma cipher machine emulator

This is a neat little emulator of various Enigma machines with a lot of confugurable parameters. Somebody hurt your feelings by saying "my grandmother encrypts better than you"? I've got you covered! With this port of the amazing 1940's technology you'll be just as good at encrypting things as anyone's grandmother.

Usage

This repository contains both the CLI tool and its underlying library written in Go. The library is documented on GoDoc.

As for the CLI tool, a simple go get should do it:

go get github.com/emedvedev/enigma/cmd/enigma

While the full CLI syntax is a bit verbose, it's actually possible to use the tool without any source code modifications, config files, or Enigma knowledge:

enigma Never gonna give you up, never gonna let you down!

Using an Enigma machine with default settings is somewhat similar to setting your password to 0000. Let's up our security game:

enigma youtu.be/dQw4w9WgXcQ --rotors Beta VI I III --reflector C-Thin --plugboard AD SF ET RY HK JL QZ WX UM OP --rings 10 5 16 10

Much better! And of course, enigma -h will give you the complete description of parameters and usage.

Importantly, since Enigma machines only have 26 keys, spaces are replaced with X, and everything outside of the English alphabet is discarded. It's up to you to come up with a suitable encoding.

Enjoy!

Enigma models and features

Almost everything from the German Enigma machines can be configured in this emulator:

  • Rotor set: rotors from M3 and M4, the most famous Enigma machines, are pre-loaded.

  • Reflector: reflectors A, B, C (as well as thin B and C versions for M4) are supported.

  • Plugboard: any number of letter pairs is accepted. Plugboard configuration is optional.

  • Ring offsets and starting position of the rotors.

M3 and M4 can be fully emulated with the right parameters, and if it's not enough, new rotors and reflectors can be added quite easily: just add a new entry to the list in rotors.go, and that's it. Notches for rotor turnover are optional.

Some exotic Enigma variants and implementations, as well as devices such as Uhr, are not supported due to my chronic lack of spare time. Your pull requests would be most welcome!

Further reading

A bunch of material on Enigma machines, in no particular order. Explanations, specs, other emulators.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].