From 6acd65390954ce3f51b2581734fed033acbf18e6 Mon Sep 17 00:00:00 2001 From: kokke Date: Tue, 3 Jun 2014 00:08:07 +0200 Subject: Update aes.c --- aes.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/aes.c b/aes.c index dab6fe4..cca2049 100644 --- a/aes.c +++ b/aes.c @@ -179,10 +179,10 @@ static void KeyExpansion() tempa[3] = getSBoxValue(tempa[3]); } } - RoundKey[ i * 4 ] = RoundKey[(i - Nk) * 4 ] ^ tempa[0]; - RoundKey[(i * 4) + 1] = RoundKey[(i - Nk) * (4 + 1)] ^ tempa[1]; - RoundKey[(i * 4) + 2] = RoundKey[(i - Nk) * (4 + 2)] ^ tempa[2]; - RoundKey[(i * 4) + 3] = RoundKey[(i - Nk) * (4 + 3)] ^ tempa[3]; + RoundKey[i * 4] = RoundKey[(i - Nk) * 4] ^ tempa[0]; + RoundKey[i * 4 + 1] = RoundKey[(i - Nk) * 4 + 1] ^ tempa[1]; + RoundKey[i * 4 + 2] = RoundKey[(i - Nk) * 4 + 2] ^ tempa[2]; + RoundKey[i * 4 + 3] = RoundKey[(i - Nk) * 4 + 3] ^ tempa[3]; } } -- cgit v1.2.3