2015-08-11 11:23:30 +01:00
|
|
|
/*
|
2016-09-22 15:31:41 +01:00
|
|
|
xmss_commons.h 20160722
|
2015-08-11 11:23:30 +01:00
|
|
|
Andreas Hülsing
|
2016-02-16 15:31:18 +00:00
|
|
|
Joost Rijneveld
|
2015-08-11 11:23:30 +01:00
|
|
|
Public domain.
|
|
|
|
*/
|
2015-08-11 11:08:27 +01:00
|
|
|
#ifndef XMSS_COMMONS_H
|
|
|
|
#define XMSS_COMMONS_H
|
|
|
|
|
|
|
|
#include <stdlib.h>
|
2016-07-11 10:15:16 +01:00
|
|
|
#include <stdint.h>
|
2015-08-11 11:08:27 +01:00
|
|
|
|
2016-07-11 10:15:16 +01:00
|
|
|
void to_byte(unsigned char *output, unsigned long long in, uint32_t bytes);
|
2017-08-03 16:38:34 +01:00
|
|
|
|
2015-08-11 11:08:27 +01:00
|
|
|
void hexdump(const unsigned char *a, size_t len);
|
2017-08-03 16:38:34 +01:00
|
|
|
|
|
|
|
void gen_leaf_wots(unsigned char *leaf,
|
|
|
|
const unsigned char *sk_seed, const unsigned char *pub_seed,
|
|
|
|
uint32_t ltree_addr[8], uint32_t ots_addr[8]);
|
|
|
|
|
|
|
|
void get_seed(unsigned char *seed,
|
|
|
|
const unsigned char *sk_seed, uint32_t addr[8]);
|
|
|
|
|
|
|
|
void l_tree(unsigned char *leaf, unsigned char *wots_pk,
|
|
|
|
const unsigned char *pub_seed, uint32_t addr[8]);
|
|
|
|
|
|
|
|
int xmss_core_sign_open(unsigned char *m, unsigned long long *mlen,
|
|
|
|
const unsigned char *sm, unsigned long long smlen,
|
|
|
|
const unsigned char *pk);
|
|
|
|
|
|
|
|
int xmssmt_core_sign_open(unsigned char *m, unsigned long long *mlen,
|
|
|
|
const unsigned char *sm, unsigned long long smlen,
|
|
|
|
const unsigned char *pk);
|
2017-06-02 13:45:16 +01:00
|
|
|
#endif
|