Skip to content
/ enigma Public

An Enigma machine simulator written in python

Notifications You must be signed in to change notification settings

gjdanis/enigma

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 

Repository files navigation

enigma

An Enigma machine simulator written in python. Example of use:

>>> r1 = Rotor("VEADTQRWUFZNLHYPXOGKJIMCSB", 1)
>>> r2 = Rotor("WNYPVJXTOAMQIZKSRFUHGCEDBL", 2)
>>> r3 = Rotor("DJYPKQNOZLMGIHFETRVCBXSWAU", 3)
>>> reflector = Reflector("EJMZALYXVBWFCRQUONTSPIKHGD")
>>> machine = Machine([r1, r2, r3], reflector)
>>> machine.encipher("ATTACK AT DAWN")
'TFKZAX KV LCBG'
>>> machine.decipher('TFKZAX KV LCBG')
'ATTACK AT DAWN'

About

An Enigma machine simulator written in python

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages