changeset 1397:d3d2aabe16dd

Tests: LibreSSL client detection in multiple certificate tests. SSL_CTRL_SET_SIGALGS_LIST and TLSv1.3 support are missing from LibreSSL despite high OPENSSL_VERSION_NUMBER. Treat it as pre-1.0.2 OpenSSL client.
author Sergey Kandaurov <pluknet@nginx.com>
date Tue, 13 Nov 2018 18:29:16 +0300
parents 28ddfda3ca2a
children 9242811bf22b
files ssl_certificates.t ssl_stapling.t
diffstat 2 files changed, 4 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/ssl_certificates.t
+++ b/ssl_certificates.t
@@ -133,7 +133,8 @@ sub get_ssl_socket {
 	my $ctx = Net::SSLeay::CTX_new() or die("Failed to create SSL_CTX $!");
 
 	if (defined $type) {
-		if (Net::SSLeay::SSLeay() < 0x1000200f) {
+		my $ssleay = Net::SSLeay::SSLeay();
+		if ($ssleay < 0x1000200f || $ssleay == 0x20000000) {
 			Net::SSLeay::CTX_set_cipher_list($ctx, $type)
 				or die("Failed to set cipher list");
 		} else {
--- a/ssl_stapling.t
+++ b/ssl_stapling.t
@@ -304,7 +304,8 @@ sub staple {
 
 	my $ctx = Net::SSLeay::CTX_new() or die("Failed to create SSL_CTX $!");
 
-	if (Net::SSLeay::SSLeay() < 0x1000200f) {
+	my $ssleay = Net::SSLeay::SSLeay();
+	if ($ssleay < 0x1000200f || $ssleay == 0x20000000) {
 		Net::SSLeay::CTX_set_cipher_list($ctx, $ciphers)
 			or die("Failed to set cipher list");
 	} else {