1 #ifndef PQCLEAN_SPHINCSSHA256192FSIMPLE_AVX2_WOTS_H
2 #define PQCLEAN_SPHINCSSHA256192FSIMPLE_AVX2_WOTS_H
3 
4 #include "hash_state.h"
5 #include "params.h"
6 #include <stdint.h>
7 
8 /**
9  * WOTS key generation. Takes a 32 byte seed for the private key, expands it to
10  * a full WOTS private key and computes the corresponding public key.
11  * It requires the seed pub_seed (used to generate bitmasks and hash keys)
12  * and the address of this WOTS key pair.
13  *
14  * Writes the computed public key to 'pk'.
15  */
16 void PQCLEAN_SPHINCSSHA256192FSIMPLE_AVX2_wots_gen_pk(
17     unsigned char *pk, const unsigned char *sk_seed,
18     const unsigned char *pub_seed, uint32_t addr[8],
19     const hash_state *hash_state_seeded);
20 
21 /**
22  * Takes a n-byte message and the 32-byte seed for the private key to compute a
23  * signature that is placed at 'sig'.
24  */
25 void PQCLEAN_SPHINCSSHA256192FSIMPLE_AVX2_wots_sign(
26     unsigned char *sig, const unsigned char *msg,
27     const unsigned char *sk_seed, const unsigned char *pub_seed,
28     uint32_t addr[8], const hash_state *hash_state_seeded);
29 
30 /**
31  * Takes a WOTS signature and an n-byte message, computes a WOTS public key.
32  *
33  * Writes the computed public key to 'pk'.
34  */
35 void PQCLEAN_SPHINCSSHA256192FSIMPLE_AVX2_wots_pk_from_sig(
36     unsigned char *pk,
37     const unsigned char *sig, const unsigned char *msg,
38     const unsigned char *pub_seed, uint32_t addr[8],
39     const hash_state *hash_state_seeded);
40 
41 #endif
42