91void sha3_224(
const uint8_t *src,
size_t len, uint8_t dst[
static 28]);
154void sha3_256(
const uint8_t *src,
size_t len, uint8_t dst[
static 32]);
217void sha3_384(
const uint8_t *src,
size_t len, uint8_t dst[
static 48]);
280void sha3_512(
const uint8_t *src,
size_t len, uint8_t dst[
static 64]);
427void shake128(
const uint8_t *src,
const size_t src_len, uint8_t *dst,
const size_t dst_len);
505void shake256(
const uint8_t *src,
const size_t src_len, uint8_t *dst,
const size_t dst_len);
549void hmac_sha3_224(
const uint8_t *key,
const size_t key_len,
const uint8_t *msg,
const size_t msg_len, uint8_t mac[28]);
574void hmac_sha3_256(
const uint8_t *key,
const size_t key_len,
const uint8_t *msg,
const size_t msg_len, uint8_t mac[32]);
599void hmac_sha3_384(
const uint8_t *key,
const size_t key_len,
const uint8_t *msg,
const size_t msg_len, uint8_t mac[48]);
624void hmac_sha3_512(
const uint8_t *key,
const size_t key_len,
const uint8_t *msg,
const size_t msg_len, uint8_t mac[64]);
1136void kmac128(
const kmac_params_t params,
const uint8_t *src,
const size_t src_len, uint8_t *dst,
const size_t dst_len);
1164void kmac256(
const kmac_params_t params,
const uint8_t *src,
const size_t src_len, uint8_t *dst,
const size_t dst_len);
2025void turboshake128(
const uint8_t *src,
const size_t src_len, uint8_t *dst,
const size_t dst_len);
2053void turboshake128_custom(
const uint8_t pad,
const uint8_t *src,
const size_t src_len, uint8_t *dst,
const size_t dst_len);
2074void turboshake256(
const uint8_t *src,
const size_t src_len, uint8_t *dst,
const size_t dst_len);
2100void turboshake256_custom(
const uint8_t pad,
const uint8_t *src,
const size_t src_len, uint8_t *dst,
const size_t dst_len);
2307void k12_once(
const uint8_t *src,
const size_t src_len, uint8_t *dst,
const size_t dst_len);
2328void k12_custom_once(
const uint8_t *src,
const size_t src_len,
const uint8_t *custom,
const size_t custom_len, uint8_t *dst,
const size_t dst_len);
2349void k12_init(
k12_t *k12,
const uint8_t *src,
const size_t src_len,
const uint8_t *custom,
const size_t custom_len);
void cshake128_xof_init(sha3_xof_t *xof, const cshake_params_t params)
Initialize cSHAKE128 XOF context.
void cshake256(const cshake_params_t params, const uint8_t *src, const size_t src_len, uint8_t *dst, const size_t dst_len)
Initialize cSHAKE256, absorb data, then squeeze bytes out.
void cshake256_xof_squeeze(sha3_xof_t *xof, uint8_t *dst, const size_t len)
Squeeze bytes from cSHAKE256 XOF context.
_Bool cshake256_xof_absorb(sha3_xof_t *xof, const uint8_t *src, const size_t len)
Absorb data into cSHAKE256 XOF context.
void cshake128(const cshake_params_t params, const uint8_t *src, const size_t src_len, uint8_t *dst, const size_t dst_len)
Initialize cSHAKE128, absorb data, then squeeze bytes out.
void cshake128_xof_squeeze(sha3_xof_t *xof, uint8_t *dst, const size_t len)
Squeeze bytes from cSHAKE128 XOF context.
void cshake256_xof_init(sha3_xof_t *xof, const cshake_params_t params)
Initialize cSHAKE256 XOF context.
_Bool cshake128_xof_absorb(sha3_xof_t *xof, const uint8_t *src, const size_t len)
Absorb data into cSHAKE128 XOF context.
void hmac_sha3_512_init(hmac_sha3_t *ctx, const uint8_t *key, const size_t key_len)
Initialize HMAC-SHA3-512 (FIPS 202, Section 7) context.
_Bool hmac_sha3_512_absorb(hmac_sha3_t *ctx, const uint8_t *src, const size_t len)
Absorb data into HMAC-SHA3-512 context.
void hmac_sha3_512(const uint8_t *key, const size_t key_len, const uint8_t *msg, const size_t msg_len, uint8_t mac[64])
Calculate HMAC-SHA3-512 of given key and data.
void hmac_sha3_224(const uint8_t *key, const size_t key_len, const uint8_t *msg, const size_t msg_len, uint8_t mac[28])
Calculate HMAC-SHA3-224 of given key and data.
_Bool hmac_sha3_224_absorb(hmac_sha3_t *ctx, const uint8_t *src, const size_t len)
Absorb data into HMAC-SHA3-224 context.
_Bool hmac_sha3_256_absorb(hmac_sha3_t *ctx, const uint8_t *src, const size_t len)
Absorb data into HMAC-SHA3-256 context.
void hmac_sha3_512_final(hmac_sha3_t *ctx, uint8_t mac[64])
Finalize HMAC-SHA3-512 context and write 64 byte MAC to destination buffer.
void hmac_sha3_224_final(hmac_sha3_t *ctx, uint8_t mac[28])
Finalize HMAC-SHA3-224 context and write 28 byte MAC to destination buffer.
void hmac_sha3_256_final(hmac_sha3_t *ctx, uint8_t mac[32])
Finalize HMAC-SHA3-256 context and write 32 byte MAC to destination buffer.
void hmac_sha3_256(const uint8_t *key, const size_t key_len, const uint8_t *msg, const size_t msg_len, uint8_t mac[32])
Calculate HMAC-SHA3-256 given key and data.
void hmac_sha3_384_final(hmac_sha3_t *ctx, uint8_t mac[48])
Finalize HMAC-SHA3-384 context and write 48 byte MAC to destination buffer.
void hmac_sha3_224_init(hmac_sha3_t *ctx, const uint8_t *key, const size_t key_len)
Initialize HMAC-SHA3-224 (FIPS 202, Section 7) context.
_Bool hmac_sha3_384_absorb(hmac_sha3_t *ctx, const uint8_t *src, const size_t len)
Absorb data into HMAC-SHA3-384 context.
void hmac_sha3_384(const uint8_t *key, const size_t key_len, const uint8_t *msg, const size_t msg_len, uint8_t mac[48])
Calculate HMAC-SHA3-384 of given key and data.
void hmac_sha3_256_init(hmac_sha3_t *ctx, const uint8_t *key, const size_t key_len)
Initialize HMAC-SHA3-256 (FIPS 202, Section 7) context.
void hmac_sha3_384_init(hmac_sha3_t *ctx, const uint8_t *key, const size_t key_len)
Initialize HMAC-SHA3-384 (FIPS 202, Section 7) context.
void k12_once(const uint8_t *src, const size_t src_len, uint8_t *dst, const size_t dst_len)
Absorb data into KangarooTwelve, then squeeze bytes out.
void k12_custom_once(const uint8_t *src, const size_t src_len, const uint8_t *custom, const size_t custom_len, uint8_t *dst, const size_t dst_len)
Absorb data into KangarooTwelve with customization string, then squeeze bytes out.
void k12_squeeze(k12_t *k12, uint8_t *dst, const size_t len)
Squeeze bytes from KangarooTwelve context.
void k12_init(k12_t *k12, const uint8_t *src, const size_t src_len, const uint8_t *custom, const size_t custom_len)
Initialize KangarooTwelve context.
void kmac128_xof_squeeze(sha3_xof_t *xof, uint8_t *dst, const size_t len)
Squeeze data from KMAC128 XOF context.
void kmac256(const kmac_params_t params, const uint8_t *src, const size_t src_len, uint8_t *dst, const size_t dst_len)
Absorb data into KMAC256, then squeeze bytes out.
void kmac256_xof_squeeze(sha3_xof_t *xof, uint8_t *dst, const size_t len)
Squeeze data from KMAC256 XOF context.
void kmac256_xof_init(sha3_xof_t *xof, const kmac_params_t params)
Initialize KMAC256 XOF context.
_Bool kmac256_xof_absorb(sha3_xof_t *xof, const uint8_t *src, const size_t len)
Absorb data into KMAC256 XOF context.
_Bool kmac128_xof_absorb(sha3_xof_t *xof, const uint8_t *src, const size_t len)
Absorb data into KMAC128 XOF context.
void kmac256_xof_once(const kmac_params_t params, const uint8_t *src, const size_t src_len, uint8_t *dst, const size_t dst_len)
Absorb data into KMAC256 XOF context, then squeeze bytes out.
void kmac128(const kmac_params_t params, const uint8_t *src, const size_t src_len, uint8_t *dst, const size_t dst_len)
Absorb data into KMAC128, then squeeze bytes out.
void kmac128_xof_init(sha3_xof_t *xof, const kmac_params_t params)
Initialize KMAC128 XOF context.
void kmac128_xof_once(const kmac_params_t params, const uint8_t *src, const size_t src_len, uint8_t *dst, const size_t dst_len)
Absorb data into KMAC128 XOF context, then squeeze bytes out.
const char * sha3_backend(void)
Get name of backend.
void parallelhash256_xof_absorb(parallelhash_t *xof, const uint8_t *src, const size_t len)
Absorb data into a ParallelHash256 XOF context.
void parallelhash256_xof_once(const parallelhash_params_t params, const uint8_t *src, const size_t src_len, uint8_t *dst, const size_t dst_len)
Absorb bytes into ParallelHash256 XOF, then squeeze bytes out.
void parallelhash128_xof_squeeze(parallelhash_t *xof, uint8_t *dst, const size_t len)
Squeeze bytes from a ParallelHash128 XOF context.
void parallelhash256_xof_init(parallelhash_t *xof, const parallelhash_params_t params)
Initialize a ParallelHash256 XOF context.
void parallelhash128(const parallelhash_params_t params, const uint8_t *src, const size_t src_len, uint8_t *dst, const size_t dst_len)
Absorb data into ParallelHash128, then squeeze bytes out.
void parallelhash128_xof_once(const parallelhash_params_t params, const uint8_t *src, const size_t src_len, uint8_t *dst, const size_t dst_len)
Absorb bytes into ParallelHash128 XOF, then squeeze bytes out.
void parallelhash128_xof_absorb(parallelhash_t *hash, const uint8_t *src, const size_t len)
Absorb data into a ParallelHash128 XOF context.
void parallelhash256_xof_squeeze(parallelhash_t *xof, uint8_t *dst, const size_t len)
Squeeze bytes from a ParallelHash256 XOF context.
void parallelhash128_xof_init(parallelhash_t *xof, const parallelhash_params_t params)
Initialize a ParallelHash128 XOF context.
void parallelhash256(const parallelhash_params_t params, const uint8_t *src, const size_t src_len, uint8_t *dst, const size_t dst_len)
Absorb data into ParallelHash256, then squeeze bytes out.
void sha3_256_final(sha3_t *hash, uint8_t dst[32])
Finalize SHA3-256 hash context and write 32 bytes of output to destination buffer dst.
void sha3_384(const uint8_t *src, size_t len, uint8_t dst[static 48])
Calculate SHA3-384 hash of input data.
_Bool sha3_512_absorb(sha3_t *hash, const uint8_t *src, const size_t len)
Absorb input data into SHA3-512 hash context.
void sha3_224_final(sha3_t *hash, uint8_t dst[28])
Finalize SHA3-224 hash context and write 28 bytes of output to destination buffer dst.
void sha3_384_final(sha3_t *hash, uint8_t dst[48])
Finalize SHA3-384 hash context and write 48 bytes of output to destination buffer dst.
void sha3_256(const uint8_t *src, size_t len, uint8_t dst[static 32])
Calculate SHA3-256 hash of input data.
void sha3_224_init(sha3_t *hash)
Initialize SHA3-224 hash context.
void sha3_256_init(sha3_t *hash)
Initialize SHA3-256 hash context.
void sha3_224(const uint8_t *src, size_t len, uint8_t dst[static 28])
Calculate SHA3-224 hash of input data.
void sha3_512(const uint8_t *src, size_t len, uint8_t dst[static 64])
Calculate SHA3-512 hash of input data.
void sha3_512_final(sha3_t *hash, uint8_t dst[64])
Finalize SHA3-512 hash context and write 64 bytes of output to destination buffer dst.
void sha3_512_init(sha3_t *hash)
Initialize SHA3-512 hash context.
_Bool sha3_224_absorb(sha3_t *hash, const uint8_t *src, const size_t len)
Initialize SHA3-224 hash context.
_Bool sha3_384_absorb(sha3_t *hash, const uint8_t *src, const size_t len)
Absorb input data into SHA3-384 hash context.
_Bool sha3_256_absorb(sha3_t *hash, const uint8_t *src, const size_t len)
Absorb input data into SHA3-256 hash context.
void sha3_384_init(sha3_t *hash)
Initialize SHA3-384 hash context.
void shake128_init(sha3_xof_t *const xof)
Initialize SHAKE128 extendable-output function (XOF) context.
_Bool shake256_absorb(sha3_xof_t *xof, const uint8_t *msg, const size_t len)
Absorb data into SHAKE256 XOF context.
_Bool shake128_absorb(sha3_xof_t *xof, const uint8_t *msg, const size_t len)
Absorb data into SHAKE128 XOF context.
void shake256(const uint8_t *src, const size_t src_len, uint8_t *dst, const size_t dst_len)
Absorb data into SHAKE256 XOF, then squeeze bytes out.
void shake256_squeeze(sha3_xof_t *xof, uint8_t *dst, const size_t len)
Squeeze bytes from SHAKE256 XOF context.
void shake128_squeeze(sha3_xof_t *xof, uint8_t *dst, const size_t len)
Squeeze bytes from SHAKE128 XOF context.
void shake256_init(sha3_xof_t *xof)
Initialize SHAKE256 extendable-output function (XOF) context.
void shake128(const uint8_t *src, const size_t src_len, uint8_t *dst, const size_t dst_len)
Absorb data into SHAKE128 XOF, then squeeze bytes out.
void tuplehash256_xof_squeeze(sha3_xof_t *xof, uint8_t *dst, const size_t len)
Squeeze bytes from a TupleHash256 XOF context.
void tuplehash256_xof_once(const tuplehash_params_t params, uint8_t *dst, const size_t len)
Absorb data into TupleHash256 XOF, then squeeze bytes out.
void tuplehash128_xof_squeeze(sha3_xof_t *xof, uint8_t *dst, const size_t len)
Squeeze data from TupleHash128 XOF context.
void tuplehash128(const tuplehash_params_t params, uint8_t *dst, const size_t len)
Absorb tuple and customization string into TupleHash128, then squeeze bytes out.
void tuplehash256_xof_init(sha3_xof_t *xof, const tuplehash_params_t params)
Initialize a TupleHash256 XOF context.
void tuplehash128_xof_init(sha3_xof_t *xof, const tuplehash_params_t params)
Initialize a TupleHash128 XOF context.
void tuplehash128_xof_once(const tuplehash_params_t params, uint8_t *dst, const size_t len)
Absorb data into TupleHash128 XOF, then squeeze bytes out.
void tuplehash256(const tuplehash_params_t params, uint8_t *dst, const size_t len)
Absorb tuple and customization string into TupleHash256, then squeeze bytes out.
void turboshake256_custom(const uint8_t pad, const uint8_t *src, const size_t src_len, uint8_t *dst, const size_t dst_len)
Absorb bytes into TurboSHAKE256 XOF with custom padding byte, then squeeze bytes out.
_Bool turboshake256_absorb(turboshake_t *ts, const uint8_t *src, const size_t len)
Absorb data into TurboSHAKE256 XOF context.
void turboshake128_init(turboshake_t *ts)
Initialize TurboSHAKE128 XOF context.
void turboshake256_init(turboshake_t *ts)
Initialize TurboSHAKE256 XOF context.
_Bool turboshake256_init_custom(turboshake_t *ts, const uint8_t pad)
Initialize TurboSHAKE256 XOF context with custom padding byte.
_Bool turboshake128_absorb(turboshake_t *ts, const uint8_t *src, const size_t len)
Absorb data into TurboSHAKE128 XOF context.
void turboshake128_custom(const uint8_t pad, const uint8_t *src, const size_t src_len, uint8_t *dst, const size_t dst_len)
Absorb bytes into TurboSHAKE128 XOF with custom padding byte, then squeeze bytes out.
void turboshake128_squeeze(turboshake_t *ts, uint8_t *dst, const size_t len)
Squeeze bytes from TurboSHAKE128 XOF context.
void turboshake128(const uint8_t *src, const size_t src_len, uint8_t *dst, const size_t dst_len)
Absorb bytes into TurboSHAKE128 XOF, then squeeze bytes out.
_Bool turboshake128_init_custom(turboshake_t *ts, const uint8_t pad)
Initialize TurboSHAKE128 XOF context with custom padding byte.
void turboshake256(const uint8_t *src, const size_t src_len, uint8_t *dst, const size_t dst_len)
Absorb bytes into TurboSHAKE256 XOF, then squeeze bytes out.
void turboshake256_squeeze(turboshake_t *ts, uint8_t *dst, const size_t len)
Squeeze bytes from TurboSHAKE256 XOF context.
cSHAKE parameters.
Definition: sha3.h:860
const size_t custom_len
Definition: sha3.h:864
const uint8_t * custom
Definition: sha3.h:863
const size_t name_len
Definition: sha3.h:862
const uint8_t * name
Definition: sha3.h:861
HMAC-SHA3 (Hash-based Message Authentication Code) context (all members are private).
Definition: sha3.h:634
sha3_t outer
Definition: sha3.h:636
sha3_t inner
Definition: sha3.h:635
_Bool finalized
Definition: sha3.h:637
KangarooTwelve XOF context (all members are private).
Definition: sha3.h:2287
turboshake_t ts
Definition: sha3.h:2288
KMAC configuration parameters (key and customization string).
Definition: sha3.h:1103
const size_t key_len
Definition: sha3.h:1105
const size_t custom_len
Definition: sha3.h:1107
const uint8_t * key
Definition: sha3.h:1104
const uint8_t * custom
Definition: sha3.h:1106
ParallelHash configuration parameters.
Definition: sha3.h:1676
const size_t custom_len
Definition: sha3.h:1679
const uint8_t * custom
Definition: sha3.h:1678
const size_t block_len
Definition: sha3.h:1677
ParallelHash context (all members are private).
Definition: sha3.h:1686
sha3_xof_t curr_xof
Definition: sha3.h:1688
size_t num_blocks
Definition: sha3.h:1691
size_t block_len
Definition: sha3.h:1690
_Bool squeezing
Definition: sha3.h:1692
size_t ofs
Definition: sha3.h:1689
sha3_xof_t root_xof
Definition: sha3.h:1687
Iterative SHA-3 context (all members are private).
Definition: sha3.h:67
_Bool finalized
Definition: sha3.h:70
size_t num_bytes
Definition: sha3.h:68
sha3_state_t a
Definition: sha3.h:69
Iterative XOF context (all members are private) for XOFs with 12 round permutations.
Definition: sha3.h:2000
_Bool squeezing
Definition: sha3.h:2003
sha3_state_t a
Definition: sha3.h:2002
size_t num_bytes
Definition: sha3.h:2001
Iterative XOF context (all members are private).
Definition: sha3.h:346
sha3_state_t a
Definition: sha3.h:348
_Bool squeezing
Definition: sha3.h:349
size_t num_bytes
Definition: sha3.h:347
TupleHash configuration parameters.
Definition: sha3.h:1432
const tuplehash_str_t * strs
Definition: sha3.h:1433
const size_t num_strs
Definition: sha3.h:1434
const size_t custom_len
Definition: sha3.h:1436
const uint8_t * custom
Definition: sha3.h:1435
Individual element of TupleHash tuple.
Definition: sha3.h:1423
size_t len
Definition: sha3.h:1425
const uint8_t * ptr
Definition: sha3.h:1424
TurboShake XOF context (all members are private).
Definition: sha3.h:2109
sha3_xof12_t xof
Definition: sha3.h:2110
uint8_t pad
Definition: sha3.h:2111
Internal SHA-3 state (all members are private).
Definition: sha3.h:55