From 23d47adaf4b9044df13b3ff180f23f3ed942c18f Mon Sep 17 00:00:00 2001 From: leonid-ed Date: Thu, 26 May 2016 15:22:17 +0300 Subject: [PATCH] [core] Fixed passing of the private key file path to OpenSSL; --- lib/hub.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/hub.c b/lib/hub.c index da92491..944173d 100644 --- a/lib/hub.c +++ b/lib/hub.c @@ -830,7 +830,7 @@ int _sxhub_settls_ctx_s(sxhub_t *hub) /* set the local certificate from CertFile */ if(SSL_CTX_use_certificate_file(hub->ctx, hub->certpem, SSL_FILETYPE_PEM) <= 0) return SXE_ESSL; /* set the private key from KeyFile (may be the same as CertFile) */ - if(SSL_CTX_use_PrivateKey_file(hub->ctx, hub->certpem, SSL_FILETYPE_PEM) <= 0) return SXE_ESSL; + if(SSL_CTX_use_PrivateKey_file(hub->ctx, hub->certkey, SSL_FILETYPE_PEM) <= 0) return SXE_ESSL; /* verify private key */ if (!SSL_CTX_check_private_key(hub->ctx)) return SXE_ESSL;