diff options
author | Jesse Luehrs <doy@tozt.net> | 2015-04-03 20:33:25 -0400 |
---|---|---|
committer | Jesse Luehrs <doy@tozt.net> | 2015-04-04 01:34:22 -0400 |
commit | 7bcccede3eaa3d2ef01aa274e46f27e1673a1f21 (patch) | |
tree | a0a2b8b097b3e23049e67c7cc613ac7a977b0fce /tests | |
parent | abb70d2f9bf9fe74397a5f644aca5fabbacc77dc (diff) | |
download | matasano-7bcccede3eaa3d2ef01aa274e46f27e1673a1f21.tar.gz matasano-7bcccede3eaa3d2ef01aa274e46f27e1673a1f21.zip |
refactor to allow specifying the keysize
Diffstat (limited to 'tests')
-rw-r--r-- | tests/lib.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/lib.rs b/tests/lib.rs index 08fb2a9..65380cf 100644 --- a/tests/lib.rs +++ b/tests/lib.rs @@ -105,7 +105,8 @@ fn problem_5 () { fn problem_6 () { let ciphertext = read_as_base64("data/6.txt"); let plaintext = read("data/6.out.txt"); - let got = matasano::crack_repeating_key_xor(&ciphertext[..]); + let key = matasano::crack_repeating_key_xor(&ciphertext[..]); + let got = matasano::repeating_key_xor(&ciphertext[..], &key[..]); assert_eq!(got, plaintext); } |