Projects
Home Projects About Me
Meaow! Building blocks...
Python Logo Python

My Python Projects…

Py-Enigma

Status: Completed, and published in the MagPi.

Summary: A Python program to emulate a Pocket Enigma Cipher Machine. This is a superbly designed toy, from Bletchley Park, that tries to demonstrate some of the principles of the real Enigma Cipher Machines used during WW2 by the German armed forces.

Details:

A cog.Analysis of the algorithm.

A cog.Analysis of the wheels.

A cog.How to encrypt a single character.

A cog.Building on this to encrypt a message.

A cog.Reversing the situation to decrypt a message.

A cog.Now to wrap it all up with a useful menu.

A cog.Here is the complete Python program. Have fun!

Warning: Remember that the Pocket Enigma Cipher Machine is not even close to an unbreakable cipher. It really is a trivial cipher to crack, but it is a lot of fun too.

I would encourage you to look here for a full review of the Pocket Enigma Cipher Machine, including a detailed description, a cryptanalysis and further reading:

http://www.savory.de/pocket_enigma.htm

Py-CiscoT7

Status: Completed.

Summary: A Python program to encrypt and decrypt Cisco Type 7 passwords. It re-uses a lot of supporting code from the Py-Enigma Python program.

Details:

A cog.Description of the Cisco Type 7 password algorithm.

A cog.Now for the completed Python program. Enjoy!

Front - The Pocket Enigma Cipher Machine Opened - The Pocket Enigma Cipher Machine Wheel I - The Pocket Enigma Cipher Machine Wheel II - The Pocket Enigma Cipher Machine

------------------------------
      P y - E N I G M A
      M A I N - M E N U
------------------------------

 1. Set Wheel      = 1
 2. Set Pointer    = D
 3. Set Code Start = J
 4. Set Increment  = 1
 5. Set Block Size = 5
 6. Encrypt a Message
 7. Decrypt a Message

 0. Exit program

------------------------------
Enter choice [1–-7 or 0]:

Published on