iPXE
Data Fields
des_round_key Union Reference

A DES round key. More...

#include <des.h>

Data Fields

uint8_t byte [8]
 Raw bytes. More...
 
uint32_t dword [2]
 32-bit big-endian dwords More...
 
int8_t step [8]
 6-bit step key byte More...
 

Detailed Description

A DES round key.

A DES round key is a 48-bit value, consumed as 8 groups of 6 bits. We store these as 8 separate bytes, for simplicity of consumption.

Definition at line 56 of file des.h.

Field Documentation

◆ byte

uint8_t des_round_key::byte[8]

Raw bytes.

Definition at line 58 of file des.h.

Referenced by des_setkey().

◆ dword

uint32_t des_round_key::dword[2]

32-bit big-endian dwords

Definition at line 60 of file des.h.

Referenced by des_round(), and des_setkey().

◆ step

int8_t des_round_key::step[8]

6-bit step key byte

There are 8 steps within a DES round (one step per S-box). Each step requires six bits of the round key.

As an optimisation, we store the least significant of the 6 bits in the sign bit of a signed 8-bit value, and the remaining 5 bits in the least significant 5 bits of the 8-bit value. See the comments in des_sbox() for further details.

Definition at line 72 of file des.h.

Referenced by des_sbox().


The documentation for this union was generated from the following file: