summaryrefslogtreecommitdiffstats
path: root/ssl
diff options
context:
space:
mode:
authorNils Larsch <nils@openssl.org>2005-07-16 11:13:10 +0000
committerNils Larsch <nils@openssl.org>2005-07-16 11:13:10 +0000
commit4913b88f704bd6cf2d6b5afa202ea4f9317422eb (patch)
treedc890bac74d3ac8c0044cd33a430d5a02f5c11a0 /ssl
parent273157153c867940891a028b8b96f562cb65701c (diff)
make
./configure no-deprecated [no-dsa] [no-dh] [no-ec] [no-rsa] make all test work again (+ make update) PR: 1159
Diffstat (limited to 'ssl')
-rw-r--r--ssl/Makefile72
-rw-r--r--ssl/d1_clnt.c3
-rw-r--r--ssl/d1_srvr.c3
-rw-r--r--ssl/s3_clnt.c8
-rw-r--r--ssl/s3_lib.c2
-rw-r--r--ssl/s3_srvr.c6
-rw-r--r--ssl/ssl_cert.c2
-rw-r--r--ssl/ssl_lib.c7
-rw-r--r--ssl/ssl_locl.h4
-rw-r--r--ssl/ssltest.c8
10 files changed, 75 insertions, 40 deletions
diff --git a/ssl/Makefile b/ssl/Makefile
index 90e2ff0430..357f3e074e 100644
--- a/ssl/Makefile
+++ b/ssl/Makefile
@@ -146,24 +146,24 @@ d1_both.o: ../include/openssl/x509_vfy.h d1_both.c ssl_locl.h
d1_clnt.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
d1_clnt.o: ../include/openssl/bn.h ../include/openssl/buffer.h
d1_clnt.o: ../include/openssl/comp.h ../include/openssl/crypto.h
-d1_clnt.o: ../include/openssl/dsa.h ../include/openssl/dtls1.h
-d1_clnt.o: ../include/openssl/e_os2.h ../include/openssl/ec.h
-d1_clnt.o: ../include/openssl/ecdh.h ../include/openssl/ecdsa.h
-d1_clnt.o: ../include/openssl/err.h ../include/openssl/evp.h
-d1_clnt.o: ../include/openssl/kssl.h ../include/openssl/lhash.h
-d1_clnt.o: ../include/openssl/md5.h ../include/openssl/obj_mac.h
-d1_clnt.o: ../include/openssl/objects.h ../include/openssl/opensslconf.h
-d1_clnt.o: ../include/openssl/opensslv.h ../include/openssl/ossl_typ.h
-d1_clnt.o: ../include/openssl/pem.h ../include/openssl/pem2.h
-d1_clnt.o: ../include/openssl/pkcs7.h ../include/openssl/pq_compat.h
-d1_clnt.o: ../include/openssl/pqueue.h ../include/openssl/rand.h
-d1_clnt.o: ../include/openssl/rsa.h ../include/openssl/safestack.h
-d1_clnt.o: ../include/openssl/sha.h ../include/openssl/ssl.h
-d1_clnt.o: ../include/openssl/ssl2.h ../include/openssl/ssl23.h
-d1_clnt.o: ../include/openssl/ssl3.h ../include/openssl/stack.h
-d1_clnt.o: ../include/openssl/symhacks.h ../include/openssl/tls1.h
-d1_clnt.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h d1_clnt.c
-d1_clnt.o: kssl_lcl.h ssl_locl.h
+d1_clnt.o: ../include/openssl/dh.h ../include/openssl/dsa.h
+d1_clnt.o: ../include/openssl/dtls1.h ../include/openssl/e_os2.h
+d1_clnt.o: ../include/openssl/ec.h ../include/openssl/ecdh.h
+d1_clnt.o: ../include/openssl/ecdsa.h ../include/openssl/err.h
+d1_clnt.o: ../include/openssl/evp.h ../include/openssl/kssl.h
+d1_clnt.o: ../include/openssl/lhash.h ../include/openssl/md5.h
+d1_clnt.o: ../include/openssl/obj_mac.h ../include/openssl/objects.h
+d1_clnt.o: ../include/openssl/opensslconf.h ../include/openssl/opensslv.h
+d1_clnt.o: ../include/openssl/ossl_typ.h ../include/openssl/pem.h
+d1_clnt.o: ../include/openssl/pem2.h ../include/openssl/pkcs7.h
+d1_clnt.o: ../include/openssl/pq_compat.h ../include/openssl/pqueue.h
+d1_clnt.o: ../include/openssl/rand.h ../include/openssl/rsa.h
+d1_clnt.o: ../include/openssl/safestack.h ../include/openssl/sha.h
+d1_clnt.o: ../include/openssl/ssl.h ../include/openssl/ssl2.h
+d1_clnt.o: ../include/openssl/ssl23.h ../include/openssl/ssl3.h
+d1_clnt.o: ../include/openssl/stack.h ../include/openssl/symhacks.h
+d1_clnt.o: ../include/openssl/tls1.h ../include/openssl/x509.h
+d1_clnt.o: ../include/openssl/x509_vfy.h d1_clnt.c kssl_lcl.h ssl_locl.h
d1_enc.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
d1_enc.o: ../include/openssl/bn.h ../include/openssl/buffer.h
d1_enc.o: ../include/openssl/comp.h ../include/openssl/crypto.h
@@ -248,24 +248,24 @@ d1_pkt.o: ssl_locl.h
d1_srvr.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
d1_srvr.o: ../include/openssl/bn.h ../include/openssl/buffer.h
d1_srvr.o: ../include/openssl/comp.h ../include/openssl/crypto.h
-d1_srvr.o: ../include/openssl/dsa.h ../include/openssl/dtls1.h
-d1_srvr.o: ../include/openssl/e_os2.h ../include/openssl/ec.h
-d1_srvr.o: ../include/openssl/ecdh.h ../include/openssl/ecdsa.h
-d1_srvr.o: ../include/openssl/err.h ../include/openssl/evp.h
-d1_srvr.o: ../include/openssl/kssl.h ../include/openssl/lhash.h
-d1_srvr.o: ../include/openssl/md5.h ../include/openssl/obj_mac.h
-d1_srvr.o: ../include/openssl/objects.h ../include/openssl/opensslconf.h
-d1_srvr.o: ../include/openssl/opensslv.h ../include/openssl/ossl_typ.h
-d1_srvr.o: ../include/openssl/pem.h ../include/openssl/pem2.h
-d1_srvr.o: ../include/openssl/pkcs7.h ../include/openssl/pq_compat.h
-d1_srvr.o: ../include/openssl/pqueue.h ../include/openssl/rand.h
-d1_srvr.o: ../include/openssl/rsa.h ../include/openssl/safestack.h
-d1_srvr.o: ../include/openssl/sha.h ../include/openssl/ssl.h
-d1_srvr.o: ../include/openssl/ssl2.h ../include/openssl/ssl23.h
-d1_srvr.o: ../include/openssl/ssl3.h ../include/openssl/stack.h
-d1_srvr.o: ../include/openssl/symhacks.h ../include/openssl/tls1.h
-d1_srvr.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h d1_srvr.c
-d1_srvr.o: ssl_locl.h
+d1_srvr.o: ../include/openssl/dh.h ../include/openssl/dsa.h
+d1_srvr.o: ../include/openssl/dtls1.h ../include/openssl/e_os2.h
+d1_srvr.o: ../include/openssl/ec.h ../include/openssl/ecdh.h
+d1_srvr.o: ../include/openssl/ecdsa.h ../include/openssl/err.h
+d1_srvr.o: ../include/openssl/evp.h ../include/openssl/kssl.h
+d1_srvr.o: ../include/openssl/lhash.h ../include/openssl/md5.h
+d1_srvr.o: ../include/openssl/obj_mac.h ../include/openssl/objects.h
+d1_srvr.o: ../include/openssl/opensslconf.h ../include/openssl/opensslv.h
+d1_srvr.o: ../include/openssl/ossl_typ.h ../include/openssl/pem.h
+d1_srvr.o: ../include/openssl/pem2.h ../include/openssl/pkcs7.h
+d1_srvr.o: ../include/openssl/pq_compat.h ../include/openssl/pqueue.h
+d1_srvr.o: ../include/openssl/rand.h ../include/openssl/rsa.h
+d1_srvr.o: ../include/openssl/safestack.h ../include/openssl/sha.h
+d1_srvr.o: ../include/openssl/ssl.h ../include/openssl/ssl2.h
+d1_srvr.o: ../include/openssl/ssl23.h ../include/openssl/ssl3.h
+d1_srvr.o: ../include/openssl/stack.h ../include/openssl/symhacks.h
+d1_srvr.o: ../include/openssl/tls1.h ../include/openssl/x509.h
+d1_srvr.o: ../include/openssl/x509_vfy.h d1_srvr.c ssl_locl.h
kssl.o: ../include/openssl/asn1.h ../include/openssl/bio.h
kssl.o: ../include/openssl/bn.h ../include/openssl/buffer.h
kssl.o: ../include/openssl/comp.h ../include/openssl/crypto.h
diff --git a/ssl/d1_clnt.c b/ssl/d1_clnt.c
index 0f840f439d..e426dcf03f 100644
--- a/ssl/d1_clnt.c
+++ b/ssl/d1_clnt.c
@@ -121,6 +121,9 @@
#include <openssl/objects.h>
#include <openssl/evp.h>
#include <openssl/md5.h>
+#ifndef OPENSSL_NO_DH
+#include <openssl/dh.h>
+#endif
static SSL_METHOD *dtls1_get_client_method(int ver);
static int dtls1_get_hello_verify(SSL *s);
diff --git a/ssl/d1_srvr.c b/ssl/d1_srvr.c
index 6d07dd4792..99f154ba65 100644
--- a/ssl/d1_srvr.c
+++ b/ssl/d1_srvr.c
@@ -121,6 +121,9 @@
#include <openssl/evp.h>
#include <openssl/x509.h>
#include <openssl/md5.h>
+#ifndef OPENSSL_NO_DH
+#include <openssl/dh.h>
+#endif
static SSL_METHOD *dtls1_get_server_method(int ver);
static int dtls1_send_hello_verify_request(SSL *s);
diff --git a/ssl/s3_clnt.c b/ssl/s3_clnt.c
index d4f7cec712..4f67cda042 100644
--- a/ssl/s3_clnt.c
+++ b/ssl/s3_clnt.c
@@ -130,7 +130,9 @@
#include <openssl/objects.h>
#include <openssl/evp.h>
#include <openssl/md5.h>
+#ifndef OPENSSL_NO_DH
#include <openssl/dh.h>
+#endif
#include <openssl/bn.h>
static SSL_METHOD *ssl3_get_client_method(int ver);
@@ -1608,6 +1610,7 @@ int ssl3_get_server_done(SSL *s)
}
+#ifndef OPENSSL_NO_ECDH
static const int KDF1_SHA1_len = 20;
static void *KDF1_SHA1(const void *in, size_t inlen, void *out, size_t *outlen)
{
@@ -1619,8 +1622,9 @@ static void *KDF1_SHA1(const void *in, size_t inlen, void *out, size_t *outlen)
return SHA1(in, inlen, out);
#else
return NULL;
-#endif
+#endif /* OPENSSL_NO_SHA */
}
+#endif /* OPENSSL_NO_ECDH */
int ssl3_send_client_key_exchange(SSL *s)
{
@@ -2132,7 +2136,7 @@ int ssl3_send_client_verify(SSL *s)
unsigned u=0;
#endif
unsigned long n;
-#ifndef OPENSSL_NO_DSA
+#if !defined(OPENSSL_NO_DSA) || !defined(OPENSSL_NO_ECDSA)
int j;
#endif
diff --git a/ssl/s3_lib.c b/ssl/s3_lib.c
index 4585ac3014..1d146d2f44 100644
--- a/ssl/s3_lib.c
+++ b/ssl/s3_lib.c
@@ -127,7 +127,9 @@
#include "ssl_locl.h"
#include "kssl_lcl.h"
#include <openssl/md5.h>
+#ifndef OPENSSL_NO_DH
#include <openssl/dh.h>
+#endif
#include <openssl/pq_compat.h>
const char *ssl3_version_str="SSLv3" OPENSSL_VERSION_PTEXT;
diff --git a/ssl/s3_srvr.c b/ssl/s3_srvr.c
index 29cb2170e6..351bb7a24e 100644
--- a/ssl/s3_srvr.c
+++ b/ssl/s3_srvr.c
@@ -133,7 +133,9 @@
#include <openssl/objects.h>
#include <openssl/evp.h>
#include <openssl/x509.h>
+#ifndef OPENSSL_NO_DH
#include <openssl/dh.h>
+#endif
#include <openssl/bn.h>
#ifndef OPENSSL_NO_KRB5
#include <openssl/krb5_asn.h>
@@ -1642,6 +1644,7 @@ err:
}
+#ifndef OPENSSL_NO_ECDH
static const int KDF1_SHA1_len = 20;
static void *KDF1_SHA1(const void *in, size_t inlen, void *out, size_t *outlen)
{
@@ -1653,8 +1656,9 @@ static void *KDF1_SHA1(const void *in, size_t inlen, void *out, size_t *outlen)
return SHA1(in, inlen, out);
#else
return NULL;
-#endif
+#endif /* OPENSSL_NO_SHA */
}
+#endif /* OPENSSL_NO_ECDH */
int ssl3_get_client_key_exchange(SSL *s)
{
diff --git a/ssl/ssl_cert.c b/ssl/ssl_cert.c
index 0c9bd07378..997528e97d 100644
--- a/ssl/ssl_cert.c
+++ b/ssl/ssl_cert.c
@@ -121,7 +121,9 @@
#include <openssl/bio.h>
#include <openssl/pem.h>
#include <openssl/x509v3.h>
+#ifndef OPENSSL_NO_DH
#include <openssl/dh.h>
+#endif
#include <openssl/bn.h>
#include "ssl_locl.h"
diff --git a/ssl/ssl_lib.c b/ssl/ssl_lib.c
index 383ba33298..f8c8e1d8ac 100644
--- a/ssl/ssl_lib.c
+++ b/ssl/ssl_lib.c
@@ -125,7 +125,9 @@
#include <openssl/objects.h>
#include <openssl/lhash.h>
#include <openssl/x509v3.h>
+#ifndef OPENSSL_NO_DH
#include <openssl/dh.h>
+#endif
const char *SSL_version_str=OPENSSL_VERSION_TEXT;
@@ -1551,7 +1553,10 @@ void ssl_set_cert_masks(CERT *c, SSL_CIPHER *cipher)
int rsa_enc_export,dh_rsa_export,dh_dsa_export;
int rsa_tmp_export,dh_tmp_export,kl;
unsigned long mask,emask;
- int have_ecc_cert, have_ecdh_tmp, ecdh_ok, ecdsa_ok, ecc_pkey_size;
+ int have_ecc_cert, ecdh_ok, ecdsa_ok, ecc_pkey_size;
+#ifndef OPENSSL_NO_ECDH
+ int have_ecdh_tmp;
+#endif
X509 *x = NULL;
EVP_PKEY *ecc_pkey = NULL;
int signature_nid = 0;
diff --git a/ssl/ssl_locl.h b/ssl/ssl_locl.h
index 8cbe26c01e..f61b1cd7e5 100644
--- a/ssl/ssl_locl.h
+++ b/ssl/ssl_locl.h
@@ -127,8 +127,12 @@
#include <openssl/comp.h>
#include <openssl/bio.h>
#include <openssl/stack.h>
+#ifndef OPENSSL_NO_RSA
#include <openssl/rsa.h>
+#endif
+#ifndef OPENSSL_NO_DSA
#include <openssl/dsa.h>
+#endif
#include <openssl/err.h>
#include <openssl/ssl.h>
#include <openssl/symhacks.h>
diff --git a/ssl/ssltest.c b/ssl/ssltest.c
index ef09a699b7..6949f9696b 100644
--- a/ssl/ssltest.c
+++ b/ssl/ssltest.c
@@ -143,9 +143,15 @@
#endif
#include <openssl/err.h>
#include <openssl/rand.h>
+#ifndef OPENSSL_NO_RSA
#include <openssl/rsa.h>
+#endif
+#ifndef OPENSSL_NO_DSA
#include <openssl/dsa.h>
+#endif
+#ifndef OPENSSL_NO_DH
#include <openssl/dh.h>
+#endif
#include <openssl/bn.h>
#define _XOPEN_SOURCE_EXTENDED 1 /* Or gethostname won't be declared properly
@@ -390,7 +396,9 @@ int main(int argc, char *argv[])
char *server_key=NULL;
char *client_cert=TEST_CLIENT_CERT;
char *client_key=NULL;
+#ifndef OPENSSL_NO_ECDH
char *named_curve = NULL;
+#endif
SSL_CTX *s_ctx=NULL;
SSL_CTX *c_ctx=NULL;
SSL_METHOD *meth=NULL;