iPXE

An AES lookup table. More...
Data Fields  
union aes_table_entry  entry [256] 
Table entries, indexed by S(N) More...  
An AES lookup table.
This represents the products (in the Galois field GF(2^8)) of a constant eightbyte vector multiplier with all possible 256 scalar multiplicands.
The entries are indexed by the AES [Inv]SubBytes Sbox output values (denoted S(N)). This allows for the result of multiplying any single column of the [Inv]MixColumns matrix by S(N) to be obtained simply by extracting the relevant fourbyte subset from the Nth table entry. For example:
Input byte (N): 0x3a SubBytes output S(N): 0x80 MixColumns column[1]: { 3, 2, 1, 1 } Vector multiplier: { 1, 1, 1, 3, 2, 1, 1, 3 } Table entry[0x3a]: { 0x80, 0x80, 0x80, 0x9b, 0x1b, 0x80, 0x80, 0x9b } Product: { 0x9b, 0x1b, 0x80, 0x80 }
Since the first byte of the eightbyte vector multiplier is always chosen to be 1, the value of S(N) may be lookup up by extracting the first byte of the Nth table entry.
union aes_table_entry aes_table::entry[256] 
Table entries, indexed by S(N)
Definition at line 141 of file aes.c.
Referenced by aes_final(), aes_generate(), aes_key_sbox(), and aes_setkey().