summaryrefslogtreecommitdiff
path: root/lib/vtls/wolfssl.c
diff options
context:
space:
mode:
authorGergely Nagy <ngg@tresorit.com>2020-06-29 20:07:37 +0200
committerDaniel Stenberg <daniel@haxx.se>2020-09-14 12:56:47 +0200
commit182ff2d63c9a25c14ee1e7dc9e6d63e9079df677 (patch)
tree104daf62b1b7ca64beffcbbdbef127dbabed2063 /lib/vtls/wolfssl.c
parent7ea2e1d0c5a7fc7e2797a2d3c2a2429d6e09e581 (diff)
downloadcurl-182ff2d63c9a25c14ee1e7dc9e6d63e9079df677.tar.gz
vtls: deduplicate client certificates in ssl_config_data
Closes #5629
Diffstat (limited to 'lib/vtls/wolfssl.c')
-rw-r--r--lib/vtls/wolfssl.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/vtls/wolfssl.c b/lib/vtls/wolfssl.c
index 1428032b6..a299b99d1 100644
--- a/lib/vtls/wolfssl.c
+++ b/lib/vtls/wolfssl.c
@@ -379,11 +379,12 @@ wolfssl_connect_step1(struct connectdata *conn,
}
/* Load the client certificate, and private key */
- if(SSL_SET_OPTION(cert) && SSL_SET_OPTION(key)) {
+ if(SSL_SET_OPTION(primary.clientcert) && SSL_SET_OPTION(key)) {
int file_type = do_file_type(SSL_SET_OPTION(cert_type));
- if(SSL_CTX_use_certificate_file(backend->ctx, SSL_SET_OPTION(cert),
- file_type) != 1) {
+ if(SSL_CTX_use_certificate_file(backend->ctx,
+ SSL_SET_OPTION(primary.clientcert),
+ file_type) != 1) {
failf(data, "unable to use client certificate (no key or wrong pass"
" phrase?)");
return CURLE_SSL_CONNECT_ERROR;