windows 安装composer 报SSL错误的解决方式

http://curl.haxx.se/docs/caextract.html     下载证书  即可   然后在php.ini  改一下配置  

windows8下运行php Composer出现ssl报错的问题:
[Composer\Downloader\TransportException]
The "https://packagist.org/packages.json" file could not be downloaded: SSL
operation failed with code 1. OpenSSL Error messages:
error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify
failed
Failed to enable crypto
failed to open stream: operation failed
----类似以上错误

这是没有安装CA证书导致的!!!

CA证书下载地址:http://curl.haxx.se/docs/caextract.html

然后修改php.ini文件

openssl.cafile= D:/wamp/php/verify/cacert.pem

posted @ 2016-11-19 08:44  lovely_1014  阅读(5799)  评论(0编辑  收藏  举报