Bitcoin ABC  0.29.2
P2P Digital Currency
Macros | Functions | Variables
chacha20.cpp File Reference
#include <crypto/chacha20.h>
#include <crypto/common.h>
#include <cstring>
Include dependency graph for chacha20.cpp:

Go to the source code of this file.

Macros

#define QUARTERROUND(a, b, c, d)
 

Functions

constexpr static uint32_t rotl32 (uint32_t v, int c)
 

Variables

static const uint8_t sigma [] = "expand 32-byte k"
 
static const uint8_t tau [] = "expand 16-byte k"
 

Macro Definition Documentation

◆ QUARTERROUND

#define QUARTERROUND (   a,
  b,
  c,
 
)
Value:
do { \
a += b; \
d = rotl32(d ^ a, 16); \
c += d; \
b = rotl32(b ^ c, 12); \
a += b; \
d = rotl32(d ^ a, 8); \
c += d; \
b = rotl32(b ^ c, 7); \
} while (0)
constexpr static uint32_t rotl32(uint32_t v, int c)
Definition: chacha20.cpp:13

Definition at line 17 of file chacha20.cpp.

Function Documentation

◆ rotl32()

constexpr static uint32_t rotl32 ( uint32_t  v,
int  c 
)
inlinestaticconstexpr

Definition at line 13 of file chacha20.cpp.

Variable Documentation

◆ sigma

const uint8_t sigma[] = "expand 32-byte k"
static

Definition at line 29 of file chacha20.cpp.

◆ tau

const uint8_t tau[] = "expand 16-byte k"
static

Definition at line 30 of file chacha20.cpp.