Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 10:12:40

0001 
0002 #ifndef crypto_scalarmult_ristretto255_H
0003 #define crypto_scalarmult_ristretto255_H
0004 
0005 #include <stddef.h>
0006 
0007 #include "export.h"
0008 
0009 #ifdef __cplusplus
0010 extern "C" {
0011 #endif
0012 
0013 #define crypto_scalarmult_ristretto255_BYTES 32U
0014 SODIUM_EXPORT
0015 size_t crypto_scalarmult_ristretto255_bytes(void);
0016 
0017 #define crypto_scalarmult_ristretto255_SCALARBYTES 32U
0018 SODIUM_EXPORT
0019 size_t crypto_scalarmult_ristretto255_scalarbytes(void);
0020 
0021 /*
0022  * NOTE: Do not use the result of this function directly for key exchange.
0023  *
0024  * Hash the result with the public keys in order to compute a shared
0025  * secret key: H(q || client_pk || server_pk)
0026  *
0027  * Or unless this is not an option, use the crypto_kx() API instead.
0028  */
0029 SODIUM_EXPORT
0030 int crypto_scalarmult_ristretto255(unsigned char *q, const unsigned char *n,
0031                                    const unsigned char *p)
0032             __attribute__ ((warn_unused_result)) __attribute__ ((nonnull));
0033 
0034 SODIUM_EXPORT
0035 int crypto_scalarmult_ristretto255_base(unsigned char *q,
0036                                         const unsigned char *n)
0037             __attribute__ ((nonnull));
0038 
0039 #ifdef __cplusplus
0040 }
0041 #endif
0042 
0043 #endif