From fc6e5a737220624ee0134ef0b41bd63226db68d7 Mon Sep 17 00:00:00 2001 From: David Benjamin Date: Tue, 19 Jan 2016 15:36:43 -0500 Subject: [PATCH] Drop the silly 'ECDH_' prefix on X25519. I got that from the TLS 1.3 draft, but it's kind of silly-looking. X25519 already refers to a Diffie-Hellman primitive. Also hopefully the WG will split NamedGroups and SignatureAlgorithms per the recent proposal, so it won't be needed anyway. (Most chatter is about what hashes should be allowed with what NIST curves, so it seems like people like the split itself? We'll see.) Change-Id: I7bb713190001199a3ebd30b67df2c00d29132431 Reviewed-on: https://boringssl-review.googlesource.com/6912 Reviewed-by: Adam Langley --- ssl/internal.h | 2 +- ssl/ssl_ecdh.c | 2 +- ssl/t1_lib.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ssl/internal.h b/ssl/internal.h index ad76b8c0..c3982d0b 100644 --- a/ssl/internal.h +++ b/ssl/internal.h @@ -531,7 +531,7 @@ int ssl3_update_handshake_hash(SSL *ssl, const uint8_t *in, size_t in_len); #define SSL_CURVE_SECP256R1 23 #define SSL_CURVE_SECP384R1 24 #define SSL_CURVE_SECP521R1 25 -#define SSL_CURVE_ECDH_X25519 29 +#define SSL_CURVE_X25519 29 /* An SSL_ECDH_METHOD is an implementation of ECDH-like key exchanges for * TLS. */ diff --git a/ssl/ssl_ecdh.c b/ssl/ssl_ecdh.c index 45c5b26b..cad8ebc0 100644 --- a/ssl/ssl_ecdh.c +++ b/ssl/ssl_ecdh.c @@ -298,7 +298,7 @@ static const SSL_ECDH_METHOD kMethods[] = { }, { NID_x25519, - SSL_CURVE_ECDH_X25519, + SSL_CURVE_X25519, "X25519", ssl_x25519_cleanup, ssl_x25519_generate_keypair, diff --git a/ssl/t1_lib.c b/ssl/t1_lib.c index 8cad57a8..68c380a9 100644 --- a/ssl/t1_lib.c +++ b/ssl/t1_lib.c @@ -294,7 +294,7 @@ int SSL_early_callback_ctx_extension_get( } static const uint16_t eccurves_default[] = { - SSL_CURVE_ECDH_X25519, + SSL_CURVE_X25519, SSL_CURVE_SECP256R1, SSL_CURVE_SECP384R1, #if defined(BORINGSSL_ANDROID_SYSTEM)