X-Git-Url: https://bilbo.iut-bm.univ-fcomte.fr/and/gitweb/Cipher_code.git/blobdiff_plain/dd7e31dbabc6d63dfeba3806362b757237f2e71e..eff7c8ed3a5515ef551c85075c5532c6f6f5c7d4:/OneRoundIoT/EnhancedOneRound/Simon_speck/C/user_tool.c diff --git a/OneRoundIoT/EnhancedOneRound/Simon_speck/C/user_tool.c b/OneRoundIoT/EnhancedOneRound/Simon_speck/C/user_tool.c index 1d5187a..33cebf7 100644 --- a/OneRoundIoT/EnhancedOneRound/Simon_speck/C/user_tool.c +++ b/OneRoundIoT/EnhancedOneRound/Simon_speck/C/user_tool.c @@ -1,3 +1,6 @@ +////USAGE : ./user speck_256_128 ECB -e key lena.ppm tests.cip + + //user simon_64_32 12 -e key tests tests.cip // @@ -169,12 +172,13 @@ int main(int argc, char *argv[]) { uint8_t *backup_buffer; + uint8_t *start=working_buffer; double t=TimeStart(); for(int i=0;i<100;i++) { - - *backup_buffer = working_buffer; + working_buffer=start; + backup_buffer = working_buffer; for(int block=0; block < input_size / block_size; block++){ (*operationPtr)(my_cipher, working_buffer, working_buffer); working_buffer += block_size;