diff --git a/aes-set-decrypt-key.c b/aes-set-decrypt-key.c index e0b75ea1705594e1f9b66d6e060c38c96f5373c2..b8d01da4c0e10de74639c8f9171fe8fd67aa689b 100644 --- a/aes-set-decrypt-key.c +++ b/aes-set-decrypt-key.c @@ -32,7 +32,7 @@ #include "aes-internal.h" /* Tables for computations in the AES GF2 field. */ -static const uint8_t log[0x100] = +static const uint8_t gf2_log[0x100] = { 0x00,0x00,0x19,0x01,0x32,0x02,0x1a,0xc6, 0x4b,0xc7,0x1b,0x68,0x33,0xee,0xdf,0x03, @@ -68,7 +68,7 @@ static const uint8_t log[0x100] = 0x0d,0x63,0x8c,0x80,0xc0,0xf7,0x70,0x07, }; -static const uint8_t ilog[0x100] = +static const uint8_t gf2_exp[0x100] = { 0x01,0x03,0x05,0x0f,0x11,0x33,0x55,0xff, 0x1a,0x2e,0x72,0x96,0xa1,0xf8,0x13,0x35, @@ -107,7 +107,7 @@ static const uint8_t ilog[0x100] = static unsigned mult(unsigned a, unsigned b) { - return (a && b) ? ilog[ (log[a] + log[b]) % 255] : 0; + return (a && b) ? gf2_exp[ (gf2_log[a] + gf2_log[b]) % 255] : 0; } static void