码迷,mamicode.com
首页 > Windows程序 > 详细

解决Win8下安装yii2时,运行php Composer出现SSL报错的问题

时间:2015-08-02 21:48:45      阅读:397      评论:0      收藏:0      [点我收藏+]

标签:

今天尝试在win8下运行composer却出现SSL报错:

D:\data\www\mmoyu\symapp>php -f %phprc%\composer install

Loading composer repositories with package information

 

  [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

 

install [--prefer-source] [--prefer-dist] [--dry-run] [--dev] [--no-dev] [--no-p

lugins] [--no-custom-installers] [--no-scripts] [--no-progress] [-v|vv|vvv|--ver

bose] [-o|--optimize-autoloader]



技术分享

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


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


然后修改php.ini文件


技术分享

openssl.cafile=C:/lamp/php56/verify/cacert.pem

重启apache



解决Win8下安装yii2时,运行php Composer出现SSL报错的问题

标签:

原文地址:http://my.oschina.net/yonghan/blog/486711

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!