X-Git-Url: http://git.euphorik.ch/?a=blobdiff_plain;ds=sidebyside;f=lab1_rust%2Fsrc%2Fmain.rs;h=2e15908baccd16f900399babf3bc1c14adaa61aa;hb=d7f0bb987b21e93a5798403d294f7905151682f7;hp=3beee951341cb960aeb0f3624257da23aa5da55f;hpb=4d892f864a1f47eb1aab23f1c70ccb143081849c;p=crypto_lab1.git diff --git a/lab1_rust/src/main.rs b/lab1_rust/src/main.rs index 3beee95..2e15908 100644 --- a/lab1_rust/src/main.rs +++ b/lab1_rust/src/main.rs @@ -8,6 +8,7 @@ use std::os; use end_point::{ Client, Server }; +mod utils; mod crypto; mod packet; mod end_point; @@ -28,7 +29,7 @@ fn do_oracle_attack(address: &str, variant: packet::Variant) { */ match oracle_machine::decipher(address, PORT, &xor_operand, &cipher_block, variant) { - Some(ref deciphered) if deciphered.as_slice() == &expected_plain_block => { + Some(ref deciphered) if deciphered.as_slice() == expected_plain_block => { println!("The oracle machine has found the plain block!:"); println!(" Expected block: {}", expected_plain_block.to_vec()); println!(" Decrypted block: {}", deciphered)