55 #define ASCON128_KEY_SIZE 16
60 #define ASCON128_NONCE_SIZE 16
65 #define ASCON128_TAG_SIZE 16
70 #define ASCON80PQ_KEY_SIZE 20
75 #define ASCON80PQ_NONCE_SIZE 16
80 #define ASCON80PQ_TAG_SIZE 16
85 #define ASCON128_RATE 8
90 #define ASCON128A_RATE 16
95 #define ASCON80PQ_RATE 8
115 (
unsigned char *c,
size_t *clen,
116 const unsigned char *m,
size_t mlen,
117 const unsigned char *ad,
size_t adlen,
118 const unsigned char *npub,
119 const unsigned char *k);
143 (
unsigned char *m,
size_t *mlen,
144 const unsigned char *c,
size_t clen,
145 const unsigned char *ad,
size_t adlen,
146 const unsigned char *npub,
147 const unsigned char *k);
167 (
unsigned char *c,
size_t *clen,
168 const unsigned char *m,
size_t mlen,
169 const unsigned char *ad,
size_t adlen,
170 const unsigned char *npub,
171 const unsigned char *k);
195 (
unsigned char *m,
size_t *mlen,
196 const unsigned char *c,
size_t clen,
197 const unsigned char *ad,
size_t adlen,
198 const unsigned char *npub,
199 const unsigned char *k);
219 (
unsigned char *c,
size_t *clen,
220 const unsigned char *m,
size_t mlen,
221 const unsigned char *ad,
size_t adlen,
222 const unsigned char *npub,
223 const unsigned char *k);
247 (
unsigned char *m,
size_t *mlen,
248 const unsigned char *c,
size_t clen,
249 const unsigned char *ad,
size_t adlen,
250 const unsigned char *npub,
251 const unsigned char *k);
359 const unsigned char *npub,
const unsigned char *k);
386 unsigned char *out,
size_t len);
418 unsigned char *out,
size_t len);
487 const unsigned char *npub,
const unsigned char *k);
514 unsigned char *out,
size_t len);
546 unsigned char *out,
size_t len);
615 const unsigned char *npub,
const unsigned char *k);
642 unsigned char *out,
size_t len);
674 unsigned char *out,
size_t len);
int ascon128a_aead_decrypt_finalize(ascon128a_state_t *state, const unsigned char *tag)
Finalizes an incremental ASCON-128a decryption operation and checks the authentication tag.
void ascon80pq_aead_encrypt(unsigned char *c, size_t *clen, const unsigned char *m, size_t mlen, const unsigned char *ad, size_t adlen, const unsigned char *npub, const unsigned char *k)
Encrypts and authenticates a packet with ASCON-80pq.
void ascon128a_aead_encrypt_finalize(ascon128a_state_t *state, unsigned char *tag)
Finalizes an incremental ASCON-128a encryption operation and generates the authentication tag.
void ascon128_aead_abort(ascon128_state_t *state)
Aborts use of ASCON-128 in incremental mode.
void ascon80pq_aead_start(ascon80pq_state_t *state, const unsigned char *ad, size_t adlen, const unsigned char *npub, const unsigned char *k)
Starts encrypting or decrypting a packet with ASCON-80pq in incremental mode.
void ascon128a_aead_decrypt_block(ascon128a_state_t *state, const unsigned char *in, unsigned char *out, size_t len)
Decrypts a block of data with ASCON-128a in incremental mode.
int ascon80pq_aead_decrypt(unsigned char *m, size_t *mlen, const unsigned char *c, size_t clen, const unsigned char *ad, size_t adlen, const unsigned char *npub, const unsigned char *k)
Decrypts and authenticates a packet with ASCON-80pq.
void ascon80pq_aead_encrypt_block(ascon80pq_state_t *state, const unsigned char *in, unsigned char *out, size_t len)
Encrypts a block of data with ASCON-80pq in incremental mode.
#define ASCON128_KEY_SIZE
Size of the key for ASCON-128 and ASCON-128a.
void ascon128a_aead_encrypt(unsigned char *c, size_t *clen, const unsigned char *m, size_t mlen, const unsigned char *ad, size_t adlen, const unsigned char *npub, const unsigned char *k)
Encrypts and authenticates a packet with ASCON-128a.
int ascon128_aead_decrypt(unsigned char *m, size_t *mlen, const unsigned char *c, size_t clen, const unsigned char *ad, size_t adlen, const unsigned char *npub, const unsigned char *k)
Decrypts and authenticates a packet with ASCON-128.
#define ASCON80PQ_KEY_SIZE
Size of the key for ASCON-80pq.
void ascon128_aead_decrypt_block(ascon128_state_t *state, const unsigned char *in, unsigned char *out, size_t len)
Decrypts a block of data with ASCON-128 in incremental mode.
void ascon128_aead_encrypt_finalize(ascon128_state_t *state, unsigned char *tag)
Finalizes an incremental ASCON-128 encryption operation and generates the authentication tag.
void ascon80pq_aead_abort(ascon80pq_state_t *state)
Aborts use of ASCON-80pq in incremental mode.
void ascon80pq_aead_decrypt_block(ascon80pq_state_t *state, const unsigned char *in, unsigned char *out, size_t len)
Decrypts a block of data with ASCON-80pq in incremental mode.
void ascon128a_aead_start(ascon128a_state_t *state, const unsigned char *ad, size_t adlen, const unsigned char *npub, const unsigned char *k)
Starts encrypting or decrypting a packet with ASCON-128a in incremental mode.
void ascon128_aead_start(ascon128_state_t *state, const unsigned char *ad, size_t adlen, const unsigned char *npub, const unsigned char *k)
Starts encrypting or decrypting a packet with ASCON-128 in incremental mode.
void ascon80pq_aead_encrypt_finalize(ascon80pq_state_t *state, unsigned char *tag)
Finalizes an incremental ASCON-80pq encryption operation and generates the authentication tag.
int ascon128_aead_decrypt_finalize(ascon128_state_t *state, const unsigned char *tag)
Finalizes an incremental ASCON-128 decryption operation and checks the authentication tag.
void ascon128a_aead_encrypt_block(ascon128a_state_t *state, const unsigned char *in, unsigned char *out, size_t len)
Encrypts a block of data with ASCON-128a in incremental mode.
void ascon128_aead_encrypt(unsigned char *c, size_t *clen, const unsigned char *m, size_t mlen, const unsigned char *ad, size_t adlen, const unsigned char *npub, const unsigned char *k)
Encrypts and authenticates a packet with ASCON-128.
int ascon128a_aead_decrypt(unsigned char *m, size_t *mlen, const unsigned char *c, size_t clen, const unsigned char *ad, size_t adlen, const unsigned char *npub, const unsigned char *k)
Decrypts and authenticates a packet with ASCON-128a.
void ascon128_aead_encrypt_block(ascon128_state_t *state, const unsigned char *in, unsigned char *out, size_t len)
Encrypts a block of data with ASCON-128 in incremental mode.
int ascon80pq_aead_decrypt_finalize(ascon80pq_state_t *state, const unsigned char *tag)
Finalizes an incremental ASCON-80pq decryption operation and checks the authentication tag.
void ascon128a_aead_abort(ascon128a_state_t *state)
Aborts use of ASCON-128a in incremental mode.
Direct access to the ASCON permutation primitive.
ascon_state_t state
[snippet_key]
State information for the incremental version of ASCON-128.
State information for the incremental version of ASCON-128a.
State information for the incremental version of ASCON-80pq.
Structure of the internal state of the ASCON permutation.