PQLR
Postquantum Crypto Library by QAPP
hypericum.h File Reference
#include "params.h"
#include <pqlr/common/pqlr.h>
#include <pqlr/common/api.h>
#include <stdint.h>

Go to the source code of this file.

Typedefs

typedef struct hypericum_st * hypericum_t
 hypericum algorithm instance handle More...
 

Functions

PQLR_API hypericum_t hypericum_new (hypericum_parameterset_t parameterset)
 Creates new hypericum instance with selected parameter set. More...
 
PQLR_API void hypericum_free (hypericum_t hypericum)
 Frees hypericum instance and all corresponding resources. More...
 
PQLR_API hypericum_t hypericum_duplicate (const hypericum_t hypericum)
 Duplicates hypericum context. More...
 
PQLR_API pqlr_t hypericum_to_pqlr (hypericum_t hypericum)
 Casts hypericum instance to pqlr instance. More...
 
PQLR_API size_t hypericum_get_signature_bytes_len (hypericum_t hypericum)
 Obtains signature buffer length in bytes for current hypericum instance. More...
 
PQLR_API size_t hypericum_get_public_key_bytes_len (hypericum_t hypericum)
 Obtains public key buffer length in bytes for current hypericum instance. More...
 
PQLR_API size_t hypericum_get_secret_key_bytes_len (hypericum_t hypericum)
 Obtains secret key buffer length in bytes for current hypericum instance. More...
 
PQLR_API void hypericum_generate_keys (const hypericum_t hypericum, uint8_t *result_sk, uint8_t *result_pk)
 Generates random secret key and public key for given context. More...
 
PQLR_API void hypericum_sign (const hypericum_t hypericum, const uint8_t *sk, const uint8_t *msg, size_t msg_len, uint8_t *result_sig, size_t *result_sig_len)
 Generates signature for given message according to context and secret key. The signature is non-deterministic, i.e. there are different results for the same message. More...
 
PQLR_API int hypericum_verify (const hypericum_t hypericum, const uint8_t *pk, const uint8_t *sig, size_t sig_len, const uint8_t *msg, size_t msg_len)
 Verifies that given signature is the signature of given message. More...