X-Git-Url: https://bilbo.iut-bm.univ-fcomte.fr/and/gitweb/Cipher_code.git/blobdiff_plain/8a13d49e7c75bb6aded0b7e038d4d8513d6c47cb..e8291c5548e7edd0beb647e84f4a4585f32b5265:/OneRoundIoT/OneRound/rc4_hash3.cpp?ds=sidebyside diff --git a/OneRoundIoT/OneRound/rc4_hash3.cpp b/OneRoundIoT/OneRound/rc4_hash3.cpp index 243fc1e..3cb1e07 100644 --- a/OneRoundIoT/OneRound/rc4_hash3.cpp +++ b/OneRoundIoT/OneRound/rc4_hash3.cpp @@ -163,34 +163,18 @@ inline static uint64_t splitmix64(uint64_t index) { //the proposed hash function, which is based on DSD structure. Sensitivity is ensured by employing the binary diffusion -void hash_DSD_BIN(uchar* seq_in, uchar* RM1,int len, uchar *S, int h) { +void hash_DSD_BIN(uint64_t * ss, uint64_t* rm,int len,int h) { - // Goal: Calculate the hash value - // Output: RM (hash value) - //uchar X[h]; - //uint64_t rm2[h>>8]; int ind1=0; - - - uint64_t *rm=(uint64_t*)RM1; - // uint64_t *xx=(uint64_t*)X; - uint64_t *ss=(uint64_t*)seq_in; - - - int a=0; for(int it=0;it>3); + hash_DSD_BIN(ss, rm,len,h>>3); }