ed448.h
Go to the documentation of this file.
1 
42 int wc_ed448_make_public(ed448_key* key, unsigned char* pubKey,
43  word32 pubKeySz);
44 
80 int wc_ed448_make_key(WC_RNG* rng, int keysize, ed448_key* key);
81 
127 int wc_ed448_sign_msg(const byte* in, word32 inlen, byte* out,
128  word32 *outlen, ed448_key* key);
129 
183 int wc_ed448ph_sign_hash(const byte* hash, word32 hashLen, byte* out,
184  word32 *outLen, ed448_key* key,
185  const byte* context, byte contextLen);
186 
238 int wc_ed448ph_sign_msg(const byte* in, word32 inLen, byte* out,
239  word32 *outLen, ed448_key* key, const byte* context,
240  byte contextLen);
241 
290 int wc_ed448_verify_msg(const byte* sig, word32 siglen, const byte* msg,
291  word32 msgLen, int* res, ed448_key* key,
292  const byte* context, byte contextLen);
293 
345 int wc_ed448ph_verify_hash(const byte* sig, word32 siglen, const byte* hash,
346  word32 hashlen, int* res, ed448_key* key,
347  const byte* context, byte contextLen);
348 
398 int wc_ed448ph_verify_msg(const byte* sig, word32 siglen, const byte* msg,
399  word32 msgLen, int* res, ed448_key* key,
400  const byte* context, byte contextLen);
401 
423 int wc_ed448_init(ed448_key* key);
424 
443 void wc_ed448_free(ed448_key* key);
444 
481 int wc_ed448_import_public(const byte* in, word32 inLen, ed448_key* key);
482 
520 int wc_ed448_import_public_ex(const byte* in, word32 inLen, ed448_key* key,
521  int trusted);
522 
558 int wc_ed448_import_private_only(const byte* priv, word32 privSz,
559  ed448_key* key);
560 
602 int wc_ed448_import_private_key(const byte* priv, word32 privSz,
603  const byte* pub, word32 pubSz, ed448_key* key);
604 
647 int wc_ed448_import_private_key_ex(const byte* priv, word32 privSz,
648  const byte* pub, word32 pubSz, ed448_key* key, int trusted);
649 
690 int wc_ed448_export_public(ed448_key* key, byte* out, word32* outLen);
691 
730 int wc_ed448_export_private_only(ed448_key* key, byte* out, word32* outLen);
731 
773 int wc_ed448_export_private(ed448_key* key, byte* out, word32* outLen);
774 
820 int wc_ed448_export_key(ed448_key* key,
821  byte* priv, word32 *privSz,
822  byte* pub, word32 *pubSz);
823 
856 int wc_ed448_check_key(ed448_key* key);
857 
858 
884 int wc_ed448_size(ed448_key* key);
885 
913 int wc_ed448_priv_size(ed448_key* key);
914 
940 int wc_ed448_pub_size(ed448_key* key);
941 
968 int wc_ed448_sig_size(ed448_key* key);
int wc_ed448ph_sign_hash(const byte *hash, word32 hashLen, byte *out, word32 *outLen, ed448_key *key, const byte *context, byte contextLen)
This function signs a message digest using an ed448_key object to guarantee authenticity. The context is included as part of the data signed. The hash is the pre-hashed message before signature calculation. The hash algorithm used to create message digest must be SHAKE-256.
int wc_ed448_check_key(ed448_key *key)
This function checks the public key in ed448_key structure matches the private key.
int wc_ed448_export_private_only(ed448_key *key, byte *out, word32 *outLen)
This function exports only the private key from an ed448_key structure. It stores the private key in ...
int wc_ed448_import_public_ex(const byte *in, word32 inLen, ed448_key *key, int trusted)
This function imports a public ed448_key pair from a buffer containing the public key...
void wc_ed448_free(ed448_key *key)
This function frees an Ed448 object after it has been used.
int wc_ed448_export_private(ed448_key *key, byte *out, word32 *outLen)
This function exports the key pair from an ed448_key structure. It stores the key pair in the buffer ...
int wc_ed448_sig_size(ed448_key *key)
This function returns the size of an Ed448 signature (114 in bytes).
int wc_ed448_import_private_key(const byte *priv, word32 privSz, const byte *pub, word32 pubSz, ed448_key *key)
This function imports a public/private Ed448 key pair from a pair of buffers. This function will hand...
int wc_ed448_export_key(ed448_key *key, byte *priv, word32 *privSz, byte *pub, word32 *pubSz)
This function exports the private and public key separately from an ed448_key structure. It stores the private key in the buffer priv, and sets the bytes written to this buffer in privSz. It stores the public key in the buffer pub, and sets the bytes written to this buffer in pubSz.
int wc_ed448_import_private_key_ex(const byte *priv, word32 privSz, const byte *pub, word32 pubSz, ed448_key *key, int trusted)
This function imports a public/private Ed448 key pair from a pair of buffers. This function will hand...
int wc_ed448ph_sign_msg(const byte *in, word32 inLen, byte *out, word32 *outLen, ed448_key *key, const byte *context, byte contextLen)
This function signs a message using an ed448_key object to guarantee authenticity. The context is included as part of the data signed. The message is pre-hashed before signature calculation.
int wc_ed448_priv_size(ed448_key *key)
This function returns the private key size (secret + public) in bytes.
int wc_ed448_make_public(ed448_key *key, unsigned char *pubKey, word32 pubKeySz)
This function generates the Ed448 public key from the private key. It stores the public key in the bu...
int wc_ed448_size(ed448_key *key)
This function returns the size of an Ed448 private key - 57 bytes.
int wc_ed448_import_public(const byte *in, word32 inLen, ed448_key *key)
This function imports a public ed448_key pair from a buffer containing the public key...
int wc_ed448ph_verify_msg(const byte *sig, word32 siglen, const byte *msg, word32 msgLen, int *res, ed448_key *key, const byte *context, byte contextLen)
This function verifies the Ed448 signature of a message to ensure authenticity. The context is includ...
int wc_ed448_export_public(ed448_key *key, byte *out, word32 *outLen)
This function exports the private key from an ed448_key structure. It stores the public key in the bu...
int wc_ed448_import_private_only(const byte *priv, word32 privSz, ed448_key *key)
This function imports an Ed448 private key only from a buffer.
int wc_ed448_verify_msg(const byte *sig, word32 siglen, const byte *msg, word32 msgLen, int *res, ed448_key *key, const byte *context, byte contextLen)
This function verifies the Ed448 signature of a message to ensure authenticity. The context is includ...
int wc_ed448_make_key(WC_RNG *rng, int keysize, ed448_key *key)
This function generates a new Ed448 key and stores it in key.
int wc_ed448_sign_msg(const byte *in, word32 inlen, byte *out, word32 *outlen, ed448_key *key)
This function signs a message using an ed448_key object to guarantee authenticity.
int wc_ed448_init(ed448_key *key)
This function initializes an ed448_key object for future use with message verification.
int wc_ed448_pub_size(ed448_key *key)
This function returns the compressed key size in bytes (public key).
int wc_ed448ph_verify_hash(const byte *sig, word32 siglen, const byte *hash, word32 hashlen, int *res, ed448_key *key, const byte *context, byte contextLen)
This function verifies the Ed448 signature of the digest of a message to ensure authenticity. The context is included as part of the data verified. The hash is the pre-hashed message before signature calculation. The hash algorithm used to create message digest must be SHAKE-256. The answer is returned through res, with 1 corresponding to a valid signature, and 0 corresponding to an invalid signature.