gpt4 book ai didi

PHP 35 : error:14094410:SSL routines:SSL3_READ_BYTES:sslv3 alert handshake failure

转载 作者:可可西里 更新时间:2023-11-01 13:34:07 26 4
gpt4 key购买 nike

cURL 停止工作。我开始收到此错误(直到几个小时前它还可以正常工作)。

我正在为 PHP 使用 cURL 扩展。我找到了 curl 命令行的一些解决方案,但不幸的是我不理解它们:/而且我不知道如何将它们移动到 PHP cURl 标志。

cURL 配置:

$curl=curl_init();
curl_setopt($curl, CURLOPT_URL, "https://pln.bitcurex.com/data/ticker.json");
curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, FALSE);
curl_setopt($curl, CURLOPT_SSLVERSION, 3);
curl_setopt($curl, CURLOPT_TIMEOUT, 10);
curl_setopt($curl, CURLOPT_FOLLOWLOCATION, 1);
curl_setopt($curl, CURLOPT_USERAGENT, $this->useragent);
curl_setopt($curl, CURLOPT_VERBOSE, 0);
curl_setopt($curl, CURLOPT_HEADER, FALSE);
curl_setopt($curl, CURLOPT_HTTPHEADER, $this->headers);

if(substr($url, 0, 5)=='https') curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, 2);

if($this->ciastko)
{
curl_setopt($curl, CURLOPT_COOKIEJAR, $this->ciastko);
curl_setopt($curl, CURLOPT_COOKIEFILE, $this->ciastko);
}

if($this->post)
{
if( is_array($this->post) && count($this->post) > 0 )
{
$postdata = http_build_query($this->post,'','&');
}
elseif( is_string($this->post) )
{
$postdata = $this->post;
}
else $postdata = '';

curl_setopt($curl, CURLOPT_POST, 1);
curl_setopt($curl, CURLOPT_POSTFIELDS, $postdata);
}

$wynik=curl_exec($curl);

错误:

35:错误:14094410:SSL 例程:SSL3_READ_BYTES:sslv3 警报握手失败

有什么解决办法吗?

最佳答案

我只是从

curl_setopt($curl, CURLOPT_SSLVERSION, 3);

curl_setopt($curl, CURLOPT_SSLVERSION, 4);

关于PHP 35 : error:14094410:SSL routines:SSL3_READ_BYTES:sslv3 alert handshake failure,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/23568539/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com