X-Git-Url: https://bilbo.iut-bm.univ-fcomte.fr/and/gitweb/Cipher_code.git/blobdiff_plain/37beaada3c7aafc63b4e75fb4e37e2621c23caa3..fb12494aee99738f9daab81fad888d1a45b5cb34:/OneRoundIoT/EnhancedOneRound/test_substitution.cpp?ds=sidebyside diff --git a/OneRoundIoT/EnhancedOneRound/test_substitution.cpp b/OneRoundIoT/EnhancedOneRound/test_substitution.cpp index 48ea63f..978876b 100644 --- a/OneRoundIoT/EnhancedOneRound/test_substitution.cpp +++ b/OneRoundIoT/EnhancedOneRound/test_substitution.cpp @@ -206,7 +206,8 @@ int main(int argc, char** argv) { uchar Sbox1[256]; - uchar Sbox2[256]; + uchar Sbox2[256]; + uchar Sbox3[256]; uchar Temp[256]; @@ -214,27 +215,36 @@ int main(int argc, char** argv) { double time=0; - rc4key(DK, Sbox1, 8); + rc4key(DK, Sbox1, 16); - rc4key(&DK[8], Sbox2, 8); + rc4key(&DK[16], Sbox2, 16); + rc4key(&DK[32], Sbox3, 16); + + + for(int i=0;i<256;i++) + cout<<(int)Sbox1[i]<<" "; + cout<