summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorMatt Caswell <matt@openssl.org>2020-09-02 16:15:06 +0100
committerMatt Caswell <matt@openssl.org>2020-09-13 11:09:45 +0100
commit6ac1cd10ba8a1d92d3858e53a7aea2cf444adf26 (patch)
tree9b2ccdb7ea5335deb20cfb4d98ee23b8ae10e299 /test
parent08073700cc50bcd0df5c0ee68c100e300a320d03 (diff)
Fix safestack issues in ssl.h
We fix 3 problems with safestack: - Including an openssl header file without linking against libcrypto can cause compilation failures (even if the app does not otherwise need to link against libcrypto). See issue #8102 - Recent changes means that applications in no-deprecated builds will need to include additional macro calls in the source code for all stacks that they need to use - which is an API break. This changes avoids that necessity. - It is not possible to write code using stacks that works in both a no-deprecated and a normal build of OpenSSL. See issue #12707. Fixes #12707 Contains a partial fix for #8102. A similar PR will be needed for hash to fully fix. Reviewed-by: Richard Levitte <levitte@openssl.org> Reviewed-by: Paul Dale <paul.dale@oracle.com> (Merged from https://github.com/openssl/openssl/pull/12781)
Diffstat (limited to 'test')
-rw-r--r--test/cipherbytes_test.c2
-rw-r--r--test/cipherlist_test.c2
-rw-r--r--test/ciphername_test.c2
-rw-r--r--test/dtls_mtu_test.c2
-rw-r--r--test/sslcorrupttest.c2
-rw-r--r--test/ssltest_old.c1
6 files changed, 0 insertions, 11 deletions
diff --git a/test/cipherbytes_test.c b/test/cipherbytes_test.c
index cbbfff2a41..ed4eacbdf3 100644
--- a/test/cipherbytes_test.c
+++ b/test/cipherbytes_test.c
@@ -21,8 +21,6 @@
#include "internal/nelem.h"
#include "testutil.h"
-DEFINE_STACK_OF(SSL_CIPHER)
-
static SSL_CTX *ctx;
static SSL *s;
diff --git a/test/cipherlist_test.c b/test/cipherlist_test.c
index 0f337b4054..380f0727fc 100644
--- a/test/cipherlist_test.c
+++ b/test/cipherlist_test.c
@@ -21,8 +21,6 @@
#include "internal/nelem.h"
#include "testutil.h"
-DEFINE_STACK_OF_CONST(SSL_CIPHER)
-
typedef struct cipherlist_test_fixture {
const char *test_case_name;
SSL_CTX *server;
diff --git a/test/ciphername_test.c b/test/ciphername_test.c
index c82a164827..c4ec6cadd7 100644
--- a/test/ciphername_test.c
+++ b/test/ciphername_test.c
@@ -22,8 +22,6 @@
#include "internal/nelem.h"
#include "testutil.h"
-DEFINE_STACK_OF(SSL_CIPHER)
-
typedef struct cipher_id_name {
int id;
const char *name;
diff --git a/test/dtls_mtu_test.c b/test/dtls_mtu_test.c
index b0730077b7..588ca32c79 100644
--- a/test/dtls_mtu_test.c
+++ b/test/dtls_mtu_test.c
@@ -20,8 +20,6 @@
/* for SSL_READ_ETM() */
#include "../ssl/ssl_local.h"
-DEFINE_STACK_OF(SSL_CIPHER)
-
static int debug = 0;
static unsigned int clnt_psk_callback(SSL *ssl, const char *hint,
diff --git a/test/sslcorrupttest.c b/test/sslcorrupttest.c
index 641ecf331d..ca9e8bfd73 100644
--- a/test/sslcorrupttest.c
+++ b/test/sslcorrupttest.c
@@ -11,8 +11,6 @@
#include "ssltestlib.h"
#include "testutil.h"
-DEFINE_STACK_OF(SSL_CIPHER)
-
static int docorrupt = 0;
static void copy_flags(BIO *bio)
diff --git a/test/ssltest_old.c b/test/ssltest_old.c
index 4f340fc2e0..88aef5e896 100644
--- a/test/ssltest_old.c
+++ b/test/ssltest_old.c
@@ -81,7 +81,6 @@
# include <unistd.h>
#endif
-DEFINE_STACK_OF(SSL_COMP)
DEFINE_STACK_OF_STRING()
static SSL_CTX *s_ctx = NULL;