23 #ifndef LW_INTERNAL_GRAIN128_H
24 #define LW_INTERNAL_GRAIN128_H
26 #include "internal-util.h"
84 const unsigned char *nonce);
uint64_t sr
Definition: internal-grain128.h:50
void grain128_compute_tag(grain128_state_t *state)
Computes the final authentiation tag.
Definition: internal-grain128.c:465
void grain128_decrypt(grain128_state_t *state, unsigned char *m, const unsigned char *c, size_t len)
Decrypts and authenticates data with Grain-128.
Definition: internal-grain128.c:420
uint32_t grain128_preoutput(const grain128_state_t *state)
Generates 32 bits of pre-output data.
Definition: internal-grain128.c:126
void grain128_encrypt(grain128_state_t *state, unsigned char *c, const unsigned char *m, size_t len)
Encrypts and authenticates data with Grain-128.
Definition: internal-grain128.c:377
unsigned posn
Definition: internal-grain128.h:52
Representation of the state of Grain-128.
Definition: internal-grain128.h:45
void grain128_setup(grain128_state_t *state, const unsigned char *key, const unsigned char *nonce)
Sets up the initial Grain-128 state with the key and nonce.
Definition: internal-grain128.c:207
void grain128_authenticate(grain128_state_t *state, const unsigned char *data, size_t len)
Authenticates data with Grain-128.
Definition: internal-grain128.c:336
uint64_t accum
Definition: internal-grain128.h:49
void grain128_core(grain128_state_t *state, uint32_t x, uint32_t x2)
Performs 32 rounds of Grain-128 in parallel.
Definition: internal-grain128.c:50