diff options
Diffstat (limited to 'includes/HttpFunctions.php')
-rw-r--r-- | includes/HttpFunctions.php | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/includes/HttpFunctions.php b/includes/HttpFunctions.php index 8453e62c..8e48da46 100644 --- a/includes/HttpFunctions.php +++ b/includes/HttpFunctions.php @@ -716,13 +716,8 @@ class CurlHttpRequest extends MWHttpRequest { } $this->curlOptions[CURLOPT_USERAGENT] = $this->reqHeaders['User-Agent']; - if ( isset( $this->sslVerifyHost ) ) { - $this->curlOptions[CURLOPT_SSL_VERIFYHOST] = $this->sslVerifyHost; - } - - if ( isset( $this->sslVerifyCert ) ) { - $this->curlOptions[CURLOPT_SSL_VERIFYPEER] = $this->sslVerifyCert; - } + $this->curlOptions[CURLOPT_SSL_VERIFYHOST] = $this->sslVerifyHost ? 2 : 0; + $this->curlOptions[CURLOPT_SSL_VERIFYPEER] = $this->sslVerifyCert; if ( $this->caInfo ) { $this->curlOptions[CURLOPT_CAINFO] = $this->caInfo; |