24#ifndef PROTOCORE_CHACHAPOLY_H
25#define PROTOCORE_CHACHAPOLY_H
29#if PROTOCORE_ENABLE_CHACHAPOLY
33#define PROTOCORE_CHACHAPOLY_KEY_LEN 64
34#define PROTOCORE_CHACHAPOLY_TAG_LEN 16
35#define PROTOCORE_CHACHAPOLY_AAD_LEN 4
45 const uint8_t *enc_len;
47} ChachaPolyLengthArgs;
57} ChachaPolyEncryptArgs;
67} ChachaPolyDecryptArgs;
101 ChachaPolyLengthArgs length_args;
102 ChachaPolyEncryptArgs encrypt_args;
103 ChachaPolyDecryptArgs decrypt_args;
109extern ChachaPolyVars ChachaPolyV;
114 void (*
const get_length)(uint8_t *work);
115 void (*
const encrypt)(uint8_t *work);
116 void (*
const decrypt)(uint8_t *work);
121void protocore_chacha_poly_get_length(uint8_t *work);
122void protocore_chacha_poly_encrypt(uint8_t *work);
123void protocore_chacha_poly_decrypt(uint8_t *work);
129static const ChachaPolyNs ChachaPoly __attribute__((unused)) = {
130 .get_length = protocore_chacha_poly_get_length,
131 .encrypt = protocore_chacha_poly_encrypt,
132 .decrypt = protocore_chacha_poly_decrypt,
#define PROTOCORE_BEGIN_DECLS
Give a header's declarations C linkage, so their symbol names carry no parameter types.
_Bool proto_bool
The truth value.
#define PROTOCORE_END_DECLS