get rid of EVP_PKEY_ECDSA (now we have EVP_PKEY_EC instead)
Submitted by: Nils Larsch
diff --git a/ssl/s3_both.c b/ssl/s3_both.c
index a558836..2e03a70 100644
--- a/ssl/s3_both.c
+++ b/ssl/s3_both.c
@@ -526,10 +526,7 @@
}
}
#ifndef OPENSSL_NO_EC
- /* XXX: Structurally, there is no distinction between
- * ECDSA and ECDH public keys (both are ECPoints).
- * So EVP_PKEY_ECDSA should really be renamed EVP_PKEY_ECC
- * (or similar). As for ECC certificates, additional
+ /* As for ECC certificates, additional
* information (e.g. in the optional key usage X509v3
* extension) could be used when available to distinguish
* between ECDH and ECDSA certificates. For now, we do not
@@ -537,7 +534,7 @@
* of checking for appropriate key usage to the SSL code
* responsible for sending/processing ECC certificates.
*/
- else if (i == EVP_PKEY_ECDSA)
+ else if (i == EVP_PKEY_EC)
{
ret = SSL_PKEY_ECC;
}
diff --git a/ssl/s3_clnt.c b/ssl/s3_clnt.c
index 74e1e52..cb93c5a 100644
--- a/ssl/s3_clnt.c
+++ b/ssl/s3_clnt.c
@@ -1349,7 +1349,7 @@
else
#endif
#ifndef OPENSSL_NO_ECDSA
- if (pkey->type == EVP_PKEY_ECDSA)
+ if (pkey->type == EVP_PKEY_EC)
{
/* let's do ECDSA */
EVP_VerifyInit_ex(&md_ctx,EVP_ecdsa(), NULL);
@@ -1907,7 +1907,7 @@
srvr_pub_pkey = X509_get_pubkey(s->session-> \
sess_cert->peer_pkeys[SSL_PKEY_ECC].x509);
if ((srvr_pub_pkey == NULL) ||
- (srvr_pub_pkey->type != EVP_PKEY_ECDSA) ||
+ (srvr_pub_pkey->type != EVP_PKEY_EC) ||
(srvr_pub_pkey->pkey.eckey == NULL))
{
SSLerr(SSL_F_SSL3_SEND_CLIENT_KEY_EXCHANGE,
@@ -2118,7 +2118,7 @@
else
#endif
#ifndef OPENSSL_NO_ECDSA
- if (pkey->type == EVP_PKEY_ECDSA)
+ if (pkey->type == EVP_PKEY_EC)
{
if (!ECDSA_sign(pkey->save_type,
&(data[MD5_DIGEST_LENGTH]),
diff --git a/ssl/s3_srvr.c b/ssl/s3_srvr.c
index d26790a..4b374a9 100644
--- a/ssl/s3_srvr.c
+++ b/ssl/s3_srvr.c
@@ -1446,7 +1446,7 @@
else
#endif
#if !defined(OPENSSL_NO_ECDSA)
- if (pkey->type == EVP_PKEY_ECDSA)
+ if (pkey->type == EVP_PKEY_EC)
{
/* let's do ECDSA */
EVP_SignInit_ex(&md_ctx,EVP_ecdsa(), NULL);
@@ -2001,7 +2001,7 @@
}
if (((clnt_pub_pkey=X509_get_pubkey(s->session->peer))
== NULL) ||
- (clnt_pub_pkey->type != EVP_PKEY_ECDSA))
+ (clnt_pub_pkey->type != EVP_PKEY_EC))
{
/* XXX: For now, we do not support client
* authentication using ECDH certificates
@@ -2228,7 +2228,7 @@
else
#endif
#ifndef OPENSSL_NO_ECDSA
- if (pkey->type == EVP_PKEY_ECDSA)
+ if (pkey->type == EVP_PKEY_EC)
{
j=ECDSA_verify(pkey->save_type,
&(s->s3->tmp.cert_verify_md[MD5_DIGEST_LENGTH]),