首页 文章

Laravel - GuzzleHttp客户端抛出cURL错误35:连接中出现未知的SSL协议错误

提问于
浏览
2
use GuzzleHttp\Client;

try {    
    $this->client = new Client(['base_uri'=>'']);  
    $responseData = $this->client->request('URL',[
        'verify'  => false,
        'headers' => [
            'Accept'       => 'application/json',
            'Content-Type' => 'application/json',
            ],  
    ]);
} catch (\Exception $ex) {
    echo $ex->getMessage()." ".$ex->getLine()." ".$ex->getFile();
}

cURL错误35:连接中未知的SSL协议错误(请参阅http://curl.haxx.se/libcurl/c/libcurl-errors.html)186 /var/www/api/vendor/guzzlehttp/guzzle/src/Handler/CurlFactory.php

1 回答

  • 2

    已经有很多类似的问题 . 尝试使用 curl console命令和this article调试它,因为没有一个错误原因(错误是一般的) .

相关问题