diff options
author | daurnimator <quae@daurnimator.com> | 2017-08-30 22:46:59 +1000 |
---|---|---|
committer | daurnimator <quae@daurnimator.com> | 2017-08-31 01:09:46 +1000 |
commit | 52b637bb43c7fbe5ae0d67f939acdaed5e7426f0 (patch) | |
tree | 8989aa6be8bd94c4a28d2e1bba7f7c810760f5bc /src | |
parent | 24c947d934703c5b59edfe8229f9fa5202ffc86d (diff) | |
download | luaossl-52b637bb43c7fbe5ae0d67f939acdaed5e7426f0.tar.gz luaossl-52b637bb43c7fbe5ae0d67f939acdaed5e7426f0.tar.bz2 luaossl-52b637bb43c7fbe5ae0d67f939acdaed5e7426f0.zip |
Fix openssl 0.9.8 compat (missing sk_OPENSSL_STRING_* functions)
Diffstat (limited to 'src')
-rw-r--r-- | src/openssl.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/openssl.c b/src/openssl.c index a3e5637..2cfad4a 100644 --- a/src/openssl.c +++ b/src/openssl.c | |||
@@ -333,6 +333,10 @@ | |||
333 | #define HAVE_SSLV2_SERVER_METHOD (!OPENSSL_PREREQ(1,1,0) && !defined OPENSSL_NO_SSL2) | 333 | #define HAVE_SSLV2_SERVER_METHOD (!OPENSSL_PREREQ(1,1,0) && !defined OPENSSL_NO_SSL2) |
334 | #endif | 334 | #endif |
335 | 335 | ||
336 | #ifndef HAVE_STACK_OPENSSL_STRING_FUNCS | ||
337 | #define HAVE_STACK_OPENSSL_STRING_FUNCS (OPENSSL_PREREQ(1,0,0) || LIBRESSL_PREREQ(2,0,0)) | ||
338 | #endif | ||
339 | |||
336 | #ifndef HAVE_X509_GET_SIGNATURE_NID | 340 | #ifndef HAVE_X509_GET_SIGNATURE_NID |
337 | #define HAVE_X509_GET_SIGNATURE_NID OPENSSL_PREREQ(1,0,2) | 341 | #define HAVE_X509_GET_SIGNATURE_NID OPENSSL_PREREQ(1,0,2) |
338 | #endif | 342 | #endif |
@@ -1698,6 +1702,12 @@ static int compat_SSL_CTX_set1_param(SSL_CTX *ctx, X509_VERIFY_PARAM *vpm) { | |||
1698 | } /* compat_SSL_CTX_set1_param() */ | 1702 | } /* compat_SSL_CTX_set1_param() */ |
1699 | #endif | 1703 | #endif |
1700 | 1704 | ||
1705 | #if !HAVE_STACK_OPENSSL_STRING_FUNCS | ||
1706 | #define sk_OPENSSL_STRING_num(s) sk_num(s) | ||
1707 | #define sk_OPENSSL_STRING_value(s, i) sk_value((s), (i)) | ||
1708 | #define sk_OPENSSL_STRING_free(s) X509_email_free(s) | ||
1709 | #endif | ||
1710 | |||
1701 | #if !HAVE_X509_GET0_EXT | 1711 | #if !HAVE_X509_GET0_EXT |
1702 | #define X509_get0_ext(crt, i) X509_get_ext((crt), (i)) | 1712 | #define X509_get0_ext(crt, i) X509_get_ext((crt), (i)) |
1703 | #endif | 1713 | #endif |