SLAU723A October 2017 – October 2018 MSP432E401Y , MSP432E411Y
The AES algorithm generates block ciphers. The AES block size is 16 bytes. The AES key(s) can be coded on 128, 192, or 256 bits. Larger key sizes provide a higher level of security, but at the cost of a moderate decrease in throughput.
For the AES algorithm:
Table 9-1 lists the combinations of keys, blocks, and rounds.
Key | Key Length (Nk) | Block Size (Nb) | Number of Rounds (Nr) |
---|---|---|---|
128 bits | 4 | 4 | 10 |
192 bits | 6 | 4 | 12 |
256 bits | 8 | 4 | 14 |
The AES algorithm for cipher and inverse cipher uses a round function composed of four different byte-oriented transformations, as follows:
This transformation is a nonlinear byte substitution that operates independently on each byte of the state (the state is an intermediate processed block of 128 bits inside the AES, arranged as an array of [4 x Nk] bytes) using an S-Box. This S-Box transformation is reversible.
In this transformation, the bytes in the last three rows of the state are cyclically shifted over different numbers of bytes (offsets). The first row (r = 0) is not shifted.
This transformation operates on the state column-by-column, treating each column as a four-term polynomial. The columns are considered polynomials over GF(2 8) and multiplied modulo × 4+ 1 with a fixed polynomial a(x).
In this transformation, a round key is added to the state using a simple bitwise XOR operation. Each round key consists of Nb words from the key schedule.
The AES algorithm takes the cipher key (K) and performs a key expansion routine to generate a key schedule. The key expansion generates a total of Nb × (Nr + 1) words. The algorithm requires an initial set of Nb words, and each of the Nr rounds requires Nb words of key data. The resulting key schedule consists of a linear array of 4-byte words, denoted [w i], with i in the range 0 ≤ i < Nb × (Nr + 1).