]> git.cryptolib.org Git - avr-crypto-lib.git/blobdiff - twister/twister.c
a lot of fixes
[avr-crypto-lib.git] / twister / twister.c
index 0135811ecc3e2503c58f2b375f3c209498d5368b..b19c0d0f6257a91e0df023d37a8833b9238a3d3b 100644 (file)
@@ -107,7 +107,7 @@ void twister_ctx2hash(void* dest, twister_state_t* ctx, uint16_t hashsize_b){
                memxor(ctx->s, tmp, 64);
                twister_blank_round(ctx);
                for(j=0; j<4; ++j){
-                       *((uint8_t*)dest) = ctx->s[3-j][0] ^ tmp[3-j][0];
+                       *((uint8_t*)dest) = ctx->s[7-j][0] ^ tmp[7-j][0];
                        dest = (uint8_t*)dest + 1;
                }
        }