My Project
ed25519.h
Go to the documentation of this file.
1 
42 int wc_ed25519_make_public(ed25519_key* key, unsigned char* pubKey,
43  word32 pubKeySz);
44 
80 int wc_ed25519_make_key(WC_RNG* rng, int keysize, ed25519_key* key);
81 
128 int wc_ed25519_sign_msg(const byte* in, word32 inlen, byte* out,
129  word32 *outlen, ed25519_key* key);
130 
182 int wc_ed25519ctx_sign_msg(const byte* in, word32 inlen, byte* out,
183  word32 *outlen, ed25519_key* key,
184  const byte* context, byte contextLen);
185 
240 int wc_ed25519ph_sign_hash(const byte* hash, word32 hashLen, byte* out,
241  word32 *outLen, ed25519_key* key,
242  const byte* context, byte contextLen);
243 
296 int wc_ed25519ph_sign_msg(const byte* in, word32 inlen, byte* out,
297  word32 *outlen, ed25519_key* key,
298  const byte* context, byte contextLen);
299 
346 int wc_ed25519_verify_msg(const byte* sig, word32 siglen, const byte* msg,
347  word32 msgLen, int* ret, ed25519_key* key);
348 
400 int wc_ed25519ctx_verify_msg(const byte* sig, word32 siglen, const byte* msg,
401  word32 msgLen, int* ret, ed25519_key* key,
402  const byte* context, byte contextLen);
403 
459 int wc_ed25519ph_verify_hash(const byte* sig, word32 siglen, const byte* hash,
460  word32 hashLen, int* ret, ed25519_key* key,
461  const byte* context, byte contextLen);
462 
515 int wc_ed25519ph_verify_msg(const byte* sig, word32 siglen, const byte* msg,
516  word32 msgLen, int* ret, ed25519_key* key,
517  const byte* context, byte contextLen);
518 
540 int wc_ed25519_init(ed25519_key* key);
541 
560 void wc_ed25519_free(ed25519_key* key);
561 
595 int wc_ed25519_import_public(const byte* in, word32 inLen, ed25519_key* key);
596 
632 int wc_ed25519_import_private_only(const byte* priv, word32 privSz,
633  ed25519_key* key);
634 
674 int wc_ed25519_import_private_key(const byte* priv, word32 privSz,
675  const byte* pub, word32 pubSz, ed25519_key* key);
676 
716 int wc_ed25519_export_public(ed25519_key* key, byte* out, word32* outLen);
717 
755 int wc_ed25519_export_private_only(ed25519_key* key, byte* out, word32* outLen);
756 
798 int wc_ed25519_export_private(ed25519_key* key, byte* out, word32* outLen);
799 
845 int wc_ed25519_export_key(ed25519_key* key,
846  byte* priv, word32 *privSz,
847  byte* pub, word32 *pubSz);
848 
879 int wc_ed25519_check_key(ed25519_key* key);
880 
906 int wc_ed25519_size(ed25519_key* key);
907 
935 int wc_ed25519_priv_size(ed25519_key* key);
936 
963 int wc_ed25519_pub_size(ed25519_key* key);
964 
991 int wc_ed25519_sig_size(ed25519_key* key);
wc_ed25519ctx_sign_msg
int wc_ed25519ctx_sign_msg(const byte *in, word32 inlen, byte *out, word32 *outlen, ed25519_key *key, const byte *context, byte contextLen)
This function signs a message using an ed25519_key object to guarantee authenticity....
wc_ed25519_check_key
int wc_ed25519_check_key(ed25519_key *key)
This function checks the public key in ed25519_key structure matches the private key.
wc_ed25519_verify_msg
int wc_ed25519_verify_msg(const byte *sig, word32 siglen, const byte *msg, word32 msgLen, int *ret, ed25519_key *key)
This function verifies the Ed25519 signature of a message to ensure authenticity. It returns the answ...
wc_ed25519ph_sign_msg
int wc_ed25519ph_sign_msg(const byte *in, word32 inlen, byte *out, word32 *outlen, ed25519_key *key, const byte *context, byte contextLen)
This function signs a message using an ed25519_key object to guarantee authenticity....
wc_ed25519ctx_verify_msg
int wc_ed25519ctx_verify_msg(const byte *sig, word32 siglen, const byte *msg, word32 msgLen, int *ret, ed25519_key *key, const byte *context, byte contextLen)
This function verifies the Ed25519 signature of a message to ensure authenticity. The context is incl...
wc_ed25519_export_private
int wc_ed25519_export_private(ed25519_key *key, byte *out, word32 *outLen)
This function exports the key pair from an ed25519_key structure. It stores the key pair in the buffe...
wc_ed25519_make_key
int wc_ed25519_make_key(WC_RNG *rng, int keysize, ed25519_key *key)
This function generates a new Ed25519 key and stores it in key.
wc_ed25519_free
void wc_ed25519_free(ed25519_key *key)
This function frees an Ed25519 object after it has been used.
wc_ed25519_export_private_only
int wc_ed25519_export_private_only(ed25519_key *key, byte *out, word32 *outLen)
This function exports only the private key from an ed25519_key structure. It stores the private key i...
wc_ed25519_init
int wc_ed25519_init(ed25519_key *key)
This function initializes an ed25519_key object for future use with message verification.
wc_ed25519_priv_size
int wc_ed25519_priv_size(ed25519_key *key)
This function returns the private key size (secret + public) in bytes.
wc_ed25519_export_key
int wc_ed25519_export_key(ed25519_key *key, byte *priv, word32 *privSz, byte *pub, word32 *pubSz)
This function exports the private and public key separately from an ed25519_key structure....
wc_ed25519_import_public
int wc_ed25519_import_public(const byte *in, word32 inLen, ed25519_key *key)
This function imports a public ed25519_key pair from a buffer containing the public key....
wc_ed25519_import_private_key
int wc_ed25519_import_private_key(const byte *priv, word32 privSz, const byte *pub, word32 pubSz, ed25519_key *key)
This function imports a public/private Ed25519 key pair from a pair of buffers. This function will ha...
wc_ed25519_import_private_only
int wc_ed25519_import_private_only(const byte *priv, word32 privSz, ed25519_key *key)
This function imports an Ed25519 private key only from a buffer.
wc_ed25519_sign_msg
int wc_ed25519_sign_msg(const byte *in, word32 inlen, byte *out, word32 *outlen, ed25519_key *key)
This function signs a message using an ed25519_key object to guarantee authenticity.
wc_ed25519_size
int wc_ed25519_size(ed25519_key *key)
This function returns the size of an Ed25519 - 32 bytes.
wc_ed25519_export_public
int wc_ed25519_export_public(ed25519_key *key, byte *out, word32 *outLen)
This function exports the private key from an ed25519_key structure. It stores the public key in the ...
wc_ed25519_make_public
int wc_ed25519_make_public(ed25519_key *key, unsigned char *pubKey, word32 pubKeySz)
This function generates the Ed25519 public key from the private key. It stores the public key in the ...
wc_ed25519_sig_size
int wc_ed25519_sig_size(ed25519_key *key)
This function returns the size of an Ed25519 signature (64 in bytes).
wc_ed25519ph_sign_hash
int wc_ed25519ph_sign_hash(const byte *hash, word32 hashLen, byte *out, word32 *outLen, ed25519_key *key, const byte *context, byte contextLen)
This function signs a message digest using an ed25519_key object to guarantee authenticity....
wc_ed25519_pub_size
int wc_ed25519_pub_size(ed25519_key *key)
This function returns the compressed key size in bytes (public key).
wc_ed25519ph_verify_msg
int wc_ed25519ph_verify_msg(const byte *sig, word32 siglen, const byte *msg, word32 msgLen, int *ret, ed25519_key *key, const byte *context, byte contextLen)
This function verifies the Ed25519 signature of a message to ensure authenticity. The context is incl...
wc_ed25519ph_verify_hash
int wc_ed25519ph_verify_hash(const byte *sig, word32 siglen, const byte *hash, word32 hashLen, int *ret, ed25519_key *key, const byte *context, byte contextLen)
This function verifies the Ed25519 signature of the digest of a message to ensure authenticity....