Go to the source code of this file.
◆ ascon_sbox
#define ascon_sbox |
( |
|
x0, |
|
|
|
x1, |
|
|
|
x2, |
|
|
|
x3, |
|
|
|
x4 |
|
) |
| |
Value: do { \
x0 ^= x4; x4 ^= x3; x2 ^= x1; \
t0 = ~x0; t1 = ~x1; t2 = ~x2; t3 = ~x3; t4 = ~x4; \
t0 &= x1; t1 &= x2; t2 &= x3; t3 &= x4; t4 &= x0; \
x0 ^= t1; x1 ^= t2; x2 ^= t3; x3 ^= t4; x4 ^= t0; \
x1 ^= x0; x0 ^= x4; x3 ^= x2; \
} while (0)
◆ ROUND_CONSTANT_PAIR
#define ROUND_CONSTANT_PAIR |
( |
|
rc1, |
|
|
|
rc2 |
|
) |
| (~((uint32_t)(rc1))), (~((uint32_t)(rc2))) |
◆ ascon_permute()
void ascon_permute |
( |
ascon_state_t * |
state, |
|
|
uint8_t |
first_round |
|
) |
| |
Permutes the ASCON state with a specified number of rounds.
- Parameters
-
state | The ASCON state in "operational" form. |
first_round | The first round to execute, between 0 and 11. The number of rounds will be 12 - first_round. |
Definition at line 36 of file ascon-c32.c.