blob: 3ceeadd4af904e6ffdf6caff7cd8e4fbfa6c7a96 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
|
From: Patrick McDermott <patrick.mcdermott@libiquity.com>
Subject: Fix undefined references with NO_OLD_TLS and NO_SESSION_CACHE
diff -Naur src.orig/lib/vtls/wolfssl.c src/lib/vtls/wolfssl.c
--- src.orig/lib/vtls/wolfssl.c 2021-01-03 03:05:41.990032879 -0500
+++ src/lib/vtls/wolfssl.c 2021-01-03 03:19:00.108983191 -0500
@@ -265,8 +265,12 @@
#endif
break;
case CURL_SSLVERSION_TLSv1_1:
+#ifndef NO_OLD_TLS
req_method = wolfTLSv1_1_client_method();
use_sni(TRUE);
+#else
+ failf(data, "wolfSSL does not support TLS 1.1");
+#endif
break;
case CURL_SSLVERSION_TLSv1_2:
req_method = wolfTLSv1_2_client_method();
@@ -500,6 +504,7 @@
}
#endif /* OPENSSL_EXTRA */
+#ifndef NO_SESSION_CACHE
/* Check if there's a cached ID we can/should use here! */
if(SSL_SET_OPTION(primary.sessionid)) {
void *ssl_sessionid = NULL;
@@ -520,6 +525,7 @@
}
Curl_ssl_sessionid_unlock(conn);
}
+#endif
/* pass the raw socket into the SSL layer */
if(!wolfSSL_set_fd(backend->handle, (int)sockfd)) {
@@ -759,6 +765,7 @@
DEBUGASSERT(ssl_connect_3 == connssl->connecting_state);
+#ifndef NO_SESSION_CACHE
if(SSL_SET_OPTION(primary.sessionid)) {
bool incache;
WOLFSSL_SESSION *our_ssl_sessionid;
@@ -788,6 +795,7 @@
}
Curl_ssl_sessionid_unlock(conn);
}
+#endif
connssl->connecting_state = ssl_connect_done;
|