xref: /freebsd/sys/contrib/libsodium/src/libsodium/crypto_scalarmult/crypto_scalarmult.c (revision 3611ec604864a7d4dcc9a3ea898c80eb35eef8a0)
1 
2 #include "crypto_scalarmult.h"
3 
4 const char *
crypto_scalarmult_primitive(void)5 crypto_scalarmult_primitive(void)
6 {
7     return crypto_scalarmult_PRIMITIVE;
8 }
9 
10 int
crypto_scalarmult_base(unsigned char * q,const unsigned char * n)11 crypto_scalarmult_base(unsigned char *q, const unsigned char *n)
12 {
13     return crypto_scalarmult_curve25519_base(q, n);
14 }
15 
16 int
crypto_scalarmult(unsigned char * q,const unsigned char * n,const unsigned char * p)17 crypto_scalarmult(unsigned char *q, const unsigned char *n,
18                   const unsigned char *p)
19 {
20     return crypto_scalarmult_curve25519(q, n, p);
21 }
22 
23 size_t
crypto_scalarmult_bytes(void)24 crypto_scalarmult_bytes(void)
25 {
26     return crypto_scalarmult_BYTES;
27 }
28 
29 size_t
crypto_scalarmult_scalarbytes(void)30 crypto_scalarmult_scalarbytes(void)
31 {
32     return crypto_scalarmult_SCALARBYTES;
33 }
34