From 1743dac078f2e060f3f6c7194deae90a2175fe92 Mon Sep 17 00:00:00 2001 From: Nick Mathewson Date: Sun, 1 Jul 2018 13:04:21 -0400 Subject: Minimize headers that include crypto_formats and x25519 stuff --- src/lib/crypt_ops/crypto_curve25519.h | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) (limited to 'src/lib/crypt_ops/crypto_curve25519.h') diff --git a/src/lib/crypt_ops/crypto_curve25519.h b/src/lib/crypt_ops/crypto_curve25519.h index 2e614848e4..acb36fde3b 100644 --- a/src/lib/crypt_ops/crypto_curve25519.h +++ b/src/lib/crypt_ops/crypto_curve25519.h @@ -8,13 +8,7 @@ #include "lib/cc/torint.h" #include "lib/crypt_ops/crypto_digest.h" #include "lib/crypt_ops/crypto_openssl_mgt.h" - -/** Length of a curve25519 public key when encoded. */ -#define CURVE25519_PUBKEY_LEN 32 -/** Length of a curve25519 secret key when encoded. */ -#define CURVE25519_SECKEY_LEN 32 -/** Length of the result of a curve25519 handshake. */ -#define CURVE25519_OUTPUT_LEN 32 +#include "lib/defs/x25519_sizes.h" /** Wrapper type for a curve25519 public key. * @@ -75,8 +69,6 @@ STATIC int curve25519_impl(uint8_t *output, const uint8_t *secret, STATIC int curve25519_basepoint_impl(uint8_t *output, const uint8_t *secret); #endif /* defined(CRYPTO_CURVE25519_PRIVATE) */ -#define CURVE25519_BASE64_PADDED_LEN 44 - int curve25519_public_from_base64(curve25519_public_key_t *pkey, const char *input); int curve25519_public_to_base64(char *output, @@ -86,4 +78,3 @@ void curve25519_set_impl_params(int use_ed); void curve25519_init(void); #endif /* !defined(TOR_CRYPTO_CURVE25519_H) */ - -- cgit v1.2.3-54-g00ecf