bug-wget
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug-wget] OpenSSL 1.1.0


From: Tim Rühsen
Subject: [Bug-wget] OpenSSL 1.1.0
Date: Tue, 28 Jun 2016 22:16:03 +0200
User-agent: KMail/4.14.10 (Linux/4.6.0-1-amd64; KDE/4.14.21; x86_64; ; )

Patching src/openssl.c for 1.1.0 (see below) let it compile.
But the HTTPS tests fail due to

ERROR: cannot verify localhost's certificate, issued by 'O=GNU,OU=Wget,CN=GNU 
Wget':
  unsupported certificate purpose

Any idea ?

Regards, Tim


The (quick&dirty) patch to compile would be

diff --git a/src/openssl.c b/src/openssl.c
index c6549ea..389f3ba 100644
--- a/src/openssl.c
+++ b/src/openssl.c
@@ -204,18 +204,20 @@ ssl_init (void)
 #endif
   SSL_library_init ();
   SSL_load_error_strings ();
+#if OPENSSL_VERSION_NUMBER < 0x10100000L
   SSLeay_add_all_algorithms ();
   SSLeay_add_ssl_algorithms ();
+#endif
 
   switch (opt.secure_protocol)
     {
-#ifndef OPENSSL_NO_SSL2
+#if !defined OPENSSL_NO_SSL2 && OPENSSL_VERSION_NUMBER < 0x10100000L
     case secure_protocol_sslv2:
       meth = SSLv2_client_method ();
       break;
 #endif
 
-#ifndef OPENSSL_NO_SSL3
+#ifndef OPENSSL_NO_SSL3_METHOD
     case secure_protocol_sslv3:
       meth = SSLv3_client_method ();
       break;
@@ -583,7 +585,7 @@ ssl_connect_wget (int fd, const char *hostname, int 
*continue_session)
     DEBUGP (("SSL handshake timed out.\n"));
     goto timeout;
   }
-  if (scwt_ctx.result <= 0 || SSL_state(conn) != SSL_ST_OK)
+  if (scwt_ctx.result <= 0 || SSL_get_state(conn) != TLS_ST_OK)
     goto error;
 
   ctx = xnew0 (struct openssl_transport_context);

Attachment: signature.asc
Description: This is a digitally signed message part.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]