diff --git a/src/API/ServerAPI.php b/src/API/ServerAPI.php index e8b9ca67..3e9c03e8 100644 --- a/src/API/ServerAPI.php +++ b/src/API/ServerAPI.php @@ -285,6 +285,7 @@ class ServerAPI{ if($this->getProperty("enable-rcon") === true){ $this->rcon = new RCON($this->getProperty("rcon.password", ""), $this->getProperty("rcon.port", $this->getProperty("server-port")), $this->getProperty("server-ip", "0.0.0.0"), $this->getProperty("rcon.threads", 1), $this->getProperty("rcon.clients-per-thread", 50)); } + if($this->getProperty("enable-query") === true){ $this->query = new Query(); } diff --git a/src/utils/Utils.php b/src/utils/Utils.php index 47235bff..19f0c666 100644 --- a/src/utils/Utils.php +++ b/src/utils/Utils.php @@ -351,6 +351,8 @@ class Utils{ curl_setopt($ch, CURLOPT_AUTOREFERER, true); curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false); curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 2); + curl_setopt($ch, CURLOPT_FORBID_REUSE, 1); + curl_setopt($ch, CURLOPT_FRESH_CONNECT, 1); curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, (int) $timeout); @@ -366,6 +368,10 @@ class Utils{ $ch = curl_init($page); curl_setopt($ch, CURLOPT_POST, 1); + curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false); + curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 2); + curl_setopt($ch, CURLOPT_FORBID_REUSE, 1); + curl_setopt($ch, CURLOPT_FRESH_CONNECT, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, $args); curl_setopt($ch, CURLOPT_AUTOREFERER, true); curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);