CrackingCodes.Ch12 package¶
Submodules¶
CrackingCodes.Ch12.PracticeQuestions module¶
Chapter 12 Practice Questions
Answers Chapter 12 Practice Questions via Python code.
CrackingCodes.Ch12.transpositionHacker module¶
Transposition Cipher Hacker
Implements a function that can hack a transposition cipher encrypted message.
Note
- https://www.nostarch.com/crackingcodes/ (BSD Licensed)
-
CrackingCodes.Ch12.transpositionHacker.
hackTransposition
(message: str)[source]¶ Hacks transposition cipher encrypted messages
Brute-forces a given encrypted message by looping through all the keys, checking if the result is English, and prompting the user for confirmation of decryption.
Parameters: message – String with message to brute-force. Returns: Prints out possible results and prompts user for confirmation. If confirmed, prints out and returns full decrypted message, otherwise returns None.