Home | History | Annotate | Line # | Download | only in sodium
      1 #ifndef crypto_core_ed25519_H
      2 #define crypto_core_ed25519_H
      3 
      4 #include <stddef.h>
      5 #include "export.h"
      6 
      7 #ifdef __cplusplus
      8 extern "C" {
      9 #endif
     10 
     11 #define crypto_core_ed25519_BYTES 32
     12 SODIUM_EXPORT
     13 size_t crypto_core_ed25519_bytes(void);
     14 
     15 #define crypto_core_ed25519_UNIFORMBYTES 32
     16 SODIUM_EXPORT
     17 size_t crypto_core_ed25519_uniformbytes(void);
     18 
     19 SODIUM_EXPORT
     20 int crypto_core_ed25519_is_valid_point(const unsigned char *p);
     21 
     22 SODIUM_EXPORT
     23 int crypto_core_ed25519_add(unsigned char *r,
     24                             const unsigned char *p, const unsigned char *q);
     25 
     26 SODIUM_EXPORT
     27 int crypto_core_ed25519_sub(unsigned char *r,
     28                             const unsigned char *p, const unsigned char *q);
     29 
     30 SODIUM_EXPORT
     31 int crypto_core_ed25519_from_uniform(unsigned char *p, const unsigned char *r);
     32 
     33 #ifdef __cplusplus
     34 }
     35 #endif
     36 
     37 #endif
     38