From 4894464fddbcca4c48ea6073aed88f8302a4018a Mon Sep 17 00:00:00 2001 From: "iyuu.cn" <367013672@qq.com> Date: Fri, 3 Apr 2020 21:03:33 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E9=83=A8=E5=88=86php?= =?UTF-8?q?=E7=8E=AF=E5=A2=83CURLOPT=5FSSL=5FVERIFYHOST=E5=8F=82=E6=95=B0?= =?UTF-8?q?=E8=AE=BE=E7=BD=AE=E4=B8=BAfalse=E5=90=8E=EF=BC=8C=E5=8D=A1?= =?UTF-8?q?=E9=A1=BF=E9=97=AE=E9=A2=98=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/AutoReseed.php | 2 +- app/Client/qBittorrent/qBittorrent.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/AutoReseed.php b/app/AutoReseed.php index 7cd2705..7524ee0 100644 --- a/app/AutoReseed.php +++ b/app/AutoReseed.php @@ -73,7 +73,7 @@ class AutoReseed self::backup('config', $configALL); self::$curl = new Curl(); self::$curl->setOpt(CURLOPT_SSL_VERIFYPEER, false); - #self::$curl->setOpt(CURLOPT_SSL_VERIFYHOST, 2); + self::$curl->setOpt(CURLOPT_SSL_VERIFYHOST, 2); // 合作站点自动注册鉴权 $is_login = Oauth::login(self::$apiUrl . self::$endpoints['login']); diff --git a/app/Client/qBittorrent/qBittorrent.php b/app/Client/qBittorrent/qBittorrent.php index a16c347..b4ed89f 100644 --- a/app/Client/qBittorrent/qBittorrent.php +++ b/app/Client/qBittorrent/qBittorrent.php @@ -82,7 +82,7 @@ class qBittorrent extends AbstractClient $this->api_version = $api_version; $this->curl = new Curl(); $this->curl->setOpt(CURLOPT_SSL_VERIFYPEER, false); // 禁止验证证书 - $this->curl->setOpt(CURLOPT_SSL_VERIFYHOST, false); // 不检查证书 + $this->curl->setOpt(CURLOPT_SSL_VERIFYHOST, 2); // 不检查证书 $this->curl->setOpt(CURLOPT_CONNECTTIMEOUT, 60); // 超时 $this->curl->setOpt(CURLOPT_TIMEOUT, 600); // 超时 // Authenticate and get cookie, else throw exception