Skip to main content

encrypt_block

Function encrypt_block 

Source
pub fn encrypt_block<const N: usize>(
    round_keys: &[[u8; 16]; N],
    block: &[u8; 16],
) -> [u8; 16]
Expand description

Encrypt one 16-byte block using T-table accelerated routine.

Combines SubBytes, ShiftRows, and MixColumns into four 32-bit table lookups per column, matching the approach used by Go and OpenSSL for software AES.

N = 11 for AES-128 (10 rounds), N = 15 for AES-256 (14 rounds).