summaryrefslogtreecommitdiff
path: root/indra/llcorehttp
diff options
context:
space:
mode:
authorAndrey Lihatskiy <alihatskiy@productengine.com>2020-09-28 22:24:12 +0300
committerAndrey Lihatskiy <alihatskiy@productengine.com>2020-09-28 22:24:12 +0300
commit32cb17e3bb86e1d3e7b945f49aa39df7868059ce (patch)
tree04c2823be5069e50ccb3363a28c4df2e48ec8cea /indra/llcorehttp
parent7f2388194136fc45d204f09fe63a6bd32d7e99ff (diff)
parentbac6652cdcd2d8333df04c3ebd3a6a7b752328b3 (diff)
Merge branch 'master' into DRTVWR-513-maint
# Conflicts: # indra/newview/llgroupmgr.cpp
Diffstat (limited to 'indra/llcorehttp')
-rw-r--r--indra/llcorehttp/_httpoprequest.cpp19
1 files changed, 14 insertions, 5 deletions
diff --git a/indra/llcorehttp/_httpoprequest.cpp b/indra/llcorehttp/_httpoprequest.cpp
index 6909a650da..04617792a2 100644
--- a/indra/llcorehttp/_httpoprequest.cpp
+++ b/indra/llcorehttp/_httpoprequest.cpp
@@ -1001,11 +1001,20 @@ CURLcode HttpOpRequest::curlSslCtxCallback(CURL *curl, void *sslctx, void *userd
{
HttpOpRequest::ptr_t op(HttpOpRequest::fromHandle<HttpOpRequest>(userdata));
- if (op->mCallbackSSLVerify)
- {
- SSL_CTX * ctx = (SSL_CTX *)sslctx;
- // disable any default verification for server certs
- SSL_CTX_set_verify(ctx, SSL_VERIFY_NONE, NULL);
+ if (op->mCallbackSSLVerify)
+ {
+ SSL_CTX * ctx = (SSL_CTX *)sslctx;
+ if (op->mReqOptions && op->mReqOptions->getSSLVerifyPeer())
+ {
+ // verification for ssl certs
+ SSL_CTX_set_verify(ctx, SSL_VERIFY_PEER, NULL);
+ }
+ else
+ {
+ // disable any default verification for server certs
+ // Ex: setting urls (assume non-SL) for parcel media in LLFloaterURLEntry
+ SSL_CTX_set_verify(ctx, SSL_VERIFY_NONE, NULL);
+ }
// set the verification callback.
SSL_CTX_set_cert_verify_callback(ctx, sslCertVerifyCallback, userdata);
// the calls are void