(trunk, daemon) #5562: 'Discrepancy in curl SSL setup between tr-daemon and tr-remote' -- fix by mike.dld

This commit is contained in:
Jordan Lee 2014-01-19 01:53:07 +00:00
parent 15d11de5f4
commit 621b27fe4d
1 changed files with 3 additions and 0 deletions

View File

@ -1769,7 +1769,10 @@ tr_curl_easy_init (struct evbuffer * writebuf)
if (auth)
curl_easy_setopt (curl, CURLOPT_USERPWD, auth);
if (UseSSL)
{
curl_easy_setopt (curl, CURLOPT_SSL_VERIFYHOST, 0); /* do not verify subject/hostname */
curl_easy_setopt (curl, CURLOPT_SSL_VERIFYPEER, 0); /* since most certs will be self-signed, do not verify against CA */
}
if (sessionId) {
char * h = tr_strdup_printf ("%s: %s", TR_RPC_SESSION_ID_HEADER, sessionId);
struct curl_slist * custom_headers = curl_slist_append (NULL, h);