php本地curl访问https的时候SSL certificate: unable to get local issuer certificate

在项目中需要使用oauth2协议请求github进行第三方登录,出现报错:SSL certificate: unable to get local issuer certificate

已解决:

下载http://curl.haxx.se/ca/cacert.pem文件,放到本地某一目录之下,并在php.ini文件中添加一行配置

curl.cainfo = "D:\myinstall\wamp\cacert.pem"

重启wamp即可

猜你喜欢

转载自blog.csdn.net/oschina_41731918/article/details/86645980