Go to the source code of this file.
|
#define | QUARTERROUND(a, b, c, d) |
|
#define | REPEAT10(a) do { {a}; {a}; {a}; {a}; {a}; {a}; {a}; {a}; {a}; {a}; } while(0) |
|
|
constexpr static uint32_t | rotl32 (uint32_t v, int c) |
|
|
static const unsigned char | sigma [] = "expand 32-byte k" |
|
static const unsigned char | tau [] = "expand 16-byte k" |
|
◆ QUARTERROUND
#define QUARTERROUND |
( |
|
a, |
|
|
|
b, |
|
|
|
c, |
|
|
|
d |
|
) |
| |
Value: a += b; d =
rotl32(d ^ a, 16); \
c += d; b =
rotl32(b ^ c, 12); \
a += b; d =
rotl32(d ^ a, 8); \
constexpr static uint32_t rotl32(uint32_t v, int c)
Definition at line 15 of file chacha20.cpp.
◆ REPEAT10
#define REPEAT10 |
( |
|
a | ) |
do { {a}; {a}; {a}; {a}; {a}; {a}; {a}; {a}; {a}; {a}; } while(0) |
◆ rotl32()
constexpr static uint32_t rotl32 |
( |
uint32_t |
v, |
|
|
int |
c |
|
) |
| |
|
inlinestaticconstexpr |
◆ sigma
const unsigned char sigma[] = "expand 32-byte k" |
|
static |
◆ tau
const unsigned char tau[] = "expand 16-byte k" |
|
static |