Expand description
Serpent and Tnepres single-block encryption.
Constant time with respect to key and block contents: both engines use bitsliced S-boxes and fixed rotations. Tnepres uses a different byte representation, not an alias for Serpent. Key lengths are public. Stored schedules are wiped on drop, but caller buffers and every register or stack copy are not. No mode, padding or authentication is provided.
Structs§
- Serpent
Engine - Serpent with a 4- to 32-byte key in four-byte steps and a 16-byte block. Uses the conventional little-endian representation.
- Tnepres
Engine - Tnepres with a 4- to 32-byte key in four-byte steps and a 16-byte block. Uses the byte- and word-reversed AES-submission representation, not a Serpent alias.
Constants§
- BLOCK_
BYTES - Block length in bytes.
- KEY_
STEP_ BYTES - Accepted key lengths advance by this many bytes.
- MAX_
KEY_ BYTES - Maximum key length in bytes.
- MIN_
KEY_ BYTES - Minimum key length in bytes.
- SERPENT_
ALGO_ NAME - Algorithm name of the conventional representation.
- TNEPRES_
ALGO_ NAME - Algorithm name of the reversed representation.