curl: (60) SSL certificate problem: unable to get local issuer certificate 错误
今天同事做微信管理的项目,请求接口返回如下错误SSL certificate problem: unable to get local issuer certificate。
此问题的出现是由于没有配置信任的服务器HTTPS验证。默认,cURL被设为不信任任何CAs,就是说,它不信任任何服务器验证。因此,这就是浏览器无法通过HTTPs访问你服务器的原因。
解决此报错有2种处理方法
1.如果你的内容不敏感,一个快捷的方法是使用curl_exec()之前跳过ssl检查项。
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
2.下载一个ca-bundle.crt ,放到对应的目录,在php.ini文件中配置下路径
https://github.com/bagder/ca-bundle/blob/e9175fec5d0c4d42de24ed6d84a06d504d5e5a09/ca-bundle.crt
在php.ini加入 ,重启web服务器
curl.cainfo="真实路径/ca-bundle.crt"
curl: (60) SSL certificate problem: unable to get local issuer certificate 错误的更多相关文章
- curl: (60) SSL certificate problem: unable to get local issuer certificate
国内私募机构九鼎控股打造APP,来就送 20元现金领取地址:http://jdb.jiudingcapital.com/phone.html 内部邀请码:C8E245J (不写邀请码,没有现金送) 国 ...
- ...cURL error 60: SSL certificate problem: unable to get local issuer certificate...
问题描述: 在做PHP爬虫的时候, 安装了 guzzle 和 dom-crawler 之后, 调用的时候出现问题, 如下 报错内容: Fatal error: Uncaught GuzzleHttp ...
- cURL error 60: SSL certificate problem: unable to get local issuer certificate 解决方法
微信开发的时,请求接口报错如下: cURL error 60: SSL certificate problem: unable to get local issuer certificate (see ...
- SSL certificate problem unable to get local issuer certificate解决办法
SSL certificate problem unable to get local issuer certificate 解决办法: 下载:ca-bundle.crt 将它放在自己的wamp或者x ...
- SSL certificate problem: unable to get local issuer certificate 的解决方法
今天在进行微信开发获取微信Access_Token时,使用到了php的curl库, 在敲完代码后获取token失败,经过各种排查错误,到了下面这一步 SSL certificate problem: ...
- HTTP 599: SSL certificate problem: unable to get local issuer certificate错误
自己在用 PySpider 框架爬虫运行代码后时出现 HTTP 599: SSL certificate problem: unable to get local issuer certificate ...
- 【error】git clone: SSL certificate problem: unable to get local issuer certificate
报错: $ git clone https://github.XXX.git Cloning into 'XXX'... fatal: unable to access 'https://github ...
- git中的SSL certificate problem: unable to get local issuer certificate错误的解决办法
我们在使用git初始化一个项目时,尤其是通过git submodule update --init --remote初始化子模块时,可能会遇到下面这个错误: fatal: unable to acce ...
- Git错误:unable to access 'https://git.voicegu.com/qa/qa.git/': SSL certificate problem: unable to get local issuer certificate
fatal: unable to access 'https://git.voicegu.com/qa/qa.git/': SSL certificate problem: unable to get ...
随机推荐
- Quectel module USB driver for linux
The environment settings are as follows: 1. ubuntu 14.04 , linux kernel: linux-lts-xenial-4.4.0 2. m ...
- 布尔值运算&集合
示例:返回booleanli = [] li = {} li = () if not li: print(1) radiansdict.has_key(key) #如果键在字典dict里返回true, ...
- Phoenix 安装完的几个简单使用
Phoenix 安装完之后的一些简单使用: 本屌丝的运行环境是3节点集群,先启动hadoop,每个节点分别启动zookeeper,启动hbase(具体怎么启动这里就不多说了) 进入 phoenix的b ...
- final修饰的类有什么特点
变量定义为final,一旦被初始化便不可改变,这里不可改变的意思对基本类型来说是其值不可变,而对于对象变量来说其引用不可再变. 方法定义为final,是为了防止任何继承类改变它. 类定义为final, ...
- 在 Linux 下使用mdadm创建 RAID 5
在 RAID 5 中,数据条带化后存储在分布式奇偶校验的多个磁盘上.分布式奇偶校验的条带化意味着它将奇偶校验信息和条带化数据分布在多个磁盘上,这样会有很好的数据冗余. 在 Linux 中配置 RAID ...
- jmeter建立JDBC连接池时遇到“A Test is currently running,stop or shutdown test to execute this command”
1.显示如下图,打开日志可以看到:Variable Name must not be empty for element:JDBC Connection Configuration,即JDBC Con ...
- string hashcode 解读
偶尔看到string hashcode方法如下 public int hashCode() { int h = hash; if (h == 0 && value.length > ...
- hive 上篇
hive 是以hadoop为基础的数据仓库,使用HQL查询存放在HDFS上面的数据,HSQL是一种类SQL的语句,最终会被编译成map/reduce,HSQL可以查询HDFS上面的数据:不支持记录级别 ...
- Redis hash数据结构
1, 新增一个 hash 或者 新增数据 => hset key field value 2, 获取某个字段值 => hset key field 3, 获取所有字段值 => hge ...
- redis该怎么用
最近一些人在介绍方案时,经常会出现redis这个词,于是很多小伙伴百度完redis也就觉得它是一个缓存,然后项目里面把数据丢进去完事,甚至有例如将实体属性拆分塞进redis hash里面的奇怪用法等等 ...