发新帖

[其他] 解决Win7下运行php Composer出现SSL报错的问题

零下一度 2020-8-31 1067
D:\wamp\bin\php\php7.1.33>php -r "copy('https://getcomposer.org/installer', 'com
poser-setup.php');"
Warning: copy(): SSL operation failed with code 1. OpenSSL Error messages:
error:14090086:SSL routines:ssl3_get_server_certificate:certificate verify faile
d in Command line code on line 1
Warning: copy(): Failed to enable crypto in Command line code on line 1
Warning: copy(https://getcomposer.org/installer): failed to open stream: operati
on failed in Command line code on line 1


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

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

然后修改php.ini文件

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


最新回复 (0)
返回
零下一度
主题数
931
帖子数
0
注册排名
1