aboutsummaryrefslogtreecommitdiff
path: root/src/lib/crypt_ops/crypto_curve25519.h
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2018-07-03 11:09:54 -0400
committerNick Mathewson <nickm@torproject.org>2018-07-03 11:09:54 -0400
commit77e678c20daf8633ce1904dd1df28398d820f7c0 (patch)
tree411cb587ea7533b65edf60c8bc2221b072dda807 /src/lib/crypt_ops/crypto_curve25519.h
parenta01b4d7f87f2217f55f5c5113fe19a2d3081a44c (diff)
parent518ebe14dcc7568da353c4c517039d0c621deb28 (diff)
downloadtor-77e678c20daf8633ce1904dd1df28398d820f7c0.tar.gz
tor-77e678c20daf8633ce1904dd1df28398d820f7c0.zip
Merge remote-tracking branch 'github/shrink_or_h_more'
Diffstat (limited to 'src/lib/crypt_ops/crypto_curve25519.h')
-rw-r--r--src/lib/crypt_ops/crypto_curve25519.h11
1 files changed, 1 insertions, 10 deletions
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) */
-