diff options
author | David Benjamin <davidben@chromium.org> | 2014-08-27 22:35:09 +0400 |
---|---|---|
committer | Adam Langley <agl@google.com> | 2014-08-28 04:41:34 +0400 |
commit | 457112e1973251a721ae419128d7108844d3c1a3 (patch) | |
tree | ccd7d5d5d2bd10345a78f7a789a674388ac96a97 /ssl/ssl_cert.c | |
parent | 1f3591d4c75fc4039dbd120ff1c459b311e976e2 (diff) |
unifdef a bunch of OPENSSL_NO_* ifdefs.
Get all this stuff out of the way.
- OPENSSL_NO_MD5
- OPENSSL_NO_SHA
- OPENSSL_NO_EC
- OPENSSL_NO_ECDSA
- OPENSSL_NO_ECDH
- OPENSSL_NO_NEXTPROTONEG
- OPENSSL_NO_DH
- OPENSSL_NO_SSL3
- OPENSSL_NO_RC4
- OPENSSL_NO_RSA
Also manually removed a couple instances of OPENSSL_NO_DSA that seemed to be
confused anyway. Did some minor manual cleanup. (Removed a few now-pointless
'if (0)'s.)
Change-Id: Id540ba97ee22ff2309ab20ceb24c7eabe766d4c4
Reviewed-on: https://boringssl-review.googlesource.com/1662
Reviewed-by: Adam Langley <agl@google.com>
Diffstat (limited to 'ssl/ssl_cert.c')
-rw-r--r-- | ssl/ssl_cert.c | 20 |
1 files changed, 0 insertions, 20 deletions
diff --git a/ssl/ssl_cert.c b/ssl/ssl_cert.c index bab0effc..5e9d41d7 100644 --- a/ssl/ssl_cert.c +++ b/ssl/ssl_cert.c @@ -161,9 +161,7 @@ void ssl_cert_set_default_md(CERT *cert) /* Set digest values to defaults */ cert->pkeys[SSL_PKEY_RSA_SIGN].digest = EVP_sha1(); cert->pkeys[SSL_PKEY_RSA_ENC].digest = EVP_sha1(); -#ifndef OPENSSL_NO_ECDSA cert->pkeys[SSL_PKEY_ECC].digest = EVP_sha1(); -#endif } CERT *ssl_cert_new(void) @@ -205,7 +203,6 @@ CERT *ssl_cert_dup(CERT *cert) ret->mask_k = cert->mask_k; ret->mask_a = cert->mask_a; -#ifndef OPENSSL_NO_DH if (cert->dh_tmp != NULL) { ret->dh_tmp = DHparams_dup(cert->dh_tmp); @@ -236,9 +233,7 @@ CERT *ssl_cert_dup(CERT *cert) } } ret->dh_tmp_cb = cert->dh_tmp_cb; -#endif -#ifndef OPENSSL_NO_ECDH if (cert->ecdh_tmp) { ret->ecdh_tmp = EC_KEY_dup(cert->ecdh_tmp); @@ -250,7 +245,6 @@ CERT *ssl_cert_dup(CERT *cert) } ret->ecdh_tmp_cb = cert->ecdh_tmp_cb; ret->ecdh_tmp_auto = cert->ecdh_tmp_auto; -#endif for (i = 0; i < SSL_PKEY_NUM; i++) { @@ -366,17 +360,11 @@ CERT *ssl_cert_dup(CERT *cert) return(ret); -#if !defined(OPENSSL_NO_DH) || !defined(OPENSSL_NO_ECDH) err: -#endif -#ifndef OPENSSL_NO_DH if (ret->dh_tmp != NULL) DH_free(ret->dh_tmp); -#endif -#ifndef OPENSSL_NO_ECDH if (ret->ecdh_tmp != NULL) EC_KEY_free(ret->ecdh_tmp); -#endif ssl_cert_clear_certs(ret); @@ -418,12 +406,8 @@ void ssl_cert_free(CERT *c) if(c == NULL) return; -#ifndef OPENSSL_NO_DH if (c->dh_tmp) DH_free(c->dh_tmp); -#endif -#ifndef OPENSSL_NO_ECDH if (c->ecdh_tmp) EC_KEY_free(c->ecdh_tmp); -#endif ssl_cert_clear_certs(c); if (c->peer_sigalgs) @@ -591,14 +575,10 @@ void ssl_sess_cert_free(SESS_CERT *sc) if (sc->peer_rsa_tmp != NULL) RSA_free(sc->peer_rsa_tmp); -#ifndef OPENSSL_NO_DH if (sc->peer_dh_tmp != NULL) DH_free(sc->peer_dh_tmp); -#endif -#ifndef OPENSSL_NO_ECDH if (sc->peer_ecdh_tmp != NULL) EC_KEY_free(sc->peer_ecdh_tmp); -#endif OPENSSL_free(sc); } |