cryptopals

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs

commit c6a9afd1540bd67a3b35a584e64910d75ab331a5
parent 1fad9e324e885a7f1f5730b6a891b92790d78116
Author: mpizzzle <michael770211@gmail.com>
Date:   Fri,  6 Oct 2017 17:17:24 +0100

updated set 1 challenge 3

Diffstat:
Mset1/single_byte_xor_cipher.py | 3+--
1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/set1/single_byte_xor_cipher.py b/set1/single_byte_xor_cipher.py @@ -2,7 +2,6 @@ import sys hex = "1b37373331363f78151b7f2b783431333d78397828372d363c78373e783a393b3736" -for x in range(128): - plaintext = ''.join([chr(x ^ ord(a)) for a in hex.decode("hex")]) +for plaintext in [''.join([chr(x ^ ord(a)) for a in hex.decode("hex")]) for x in range(128)]: if " a " in plaintext: print plaintext \ No newline at end of file