void Decrypt(uint8_t *block, uint8_t *roundKeys) { int8_t i; int8_t* prk = roundKeys + 132; DecryptFinalTransfomation(block, roundKeys); for(i = 0; i < NUMBER_OF_ROUNDS; ++i) { DecryptRoundFunction(block, prk); prk -= 4; } DecryptInitialTransfomation(block, roundKeys); }
void Decrypt(uint8_t *block, uint8_t *roundKeys) { int8_t i; DecryptFinalTransfomation(block, roundKeys); for(i = NUMBER_OF_ROUNDS - 1; i >= 0; i--) { DecryptRoundFunction(block, &roundKeys[8 + (i << 2)]); } DecryptInitialTransfomation(block, roundKeys); }