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 ...
随机推荐
- PLSQL导出表结构
1:进行plsql后选怎Tools--------->Exports User Ojbects------------->选中需要导出的table,squence,view,type,fu ...
- 修改 Docker-MySQL 容器的 默认用户加密规则
背景介绍 今天开始做集成测试,需要把程序和环境重新部署在新的服务器上.项目的环境都是基于Docker来的,所以数据库也是选择从Docker官网上面拉官方的MySQL镜像.(Tag = 8.0.12) ...
- Maven web项目启动出错
问题描述: 在第一次建立maven项目后,启动测试,结果jsp页面报告404错误 问题解决: 在pom.xml中引入servlet-api 和 jsp-api,maven不会自动的添加,因此,要在首次 ...
- 代码生成器 CodeSmith 的使用(一)
由于在项目中经常要会用到数据库的 CRUD 操作(增.删.改.查),而且还使用的是orm 框架将数据库表名和表中的的字段映射成相应的类属性.如果把大量的时间用到手工输入数据库表中的字段,除了能练习打字 ...
- python urlretrieve 下载图片
python 3中urlretrieve方法直接将远程数据下载到本地.为什么不行? 55 import re import urllib.request def getHtml(url): page ...
- python气象分析
数据分析实例 -- 气象数据 一.实验介绍 本实验将对意大利北部沿海地区的气象数据进行分析与可视化.我们在实验过程中先会运用 Python 中matplotlib库的对数据进行图表化处理,然后调用 s ...
- HTML5 通过文件输入框读取文件为base64文件, 并借助canvas压缩 FileReader, files, drawImage
<!DOCTYPE html> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <m ...
- ajax 实现跨域
ajax本身是不可以跨域的,通过产生一个script标签来实现跨域.因为script标签的src属性是没有跨域的限制的. 其实设置了dataType: 'jsonp'后,$.ajax方法就和ajax ...
- Spring MVC 处理JSON 使用HttpMessageConveter
负责将请求信息转换为一个对象 请求报名,转为InputStream, 输出报名OutputStream
- Web Deploy
Web Deploy 服务器安装设置与使用 Win2008R2配置WebDeploy Visual Studio 使用Web Deploy发布项目