在windows上安装php composer时出错
在安装 composer 以使用 laravel 框架时,我遇到了一些错误:
While installing the composer to user the laravel framework, I got some errors :
Download failed: file_get_contents(): SSL operation failed with code 1. OpenSSL Error messages:
error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed
file_get_contents(): Failed to enable crypto
file_get_contents(https://getcomposer.org/composer.phar): failed to open stream: operation failed
Download failed: file_get_contents(): SSL operation failed with code 1. OpenSSL Error messages:
error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed
file_get_contents(): Failed to enable crypto
file_get_contents(https://getcomposer.org/composer.phar): failed to open stream: operation failed
Download failed: file_get_contents(): SSL operation failed with code 1. OpenSSL Error messages:
error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed
file_get_contents(): Failed to enable crypto
file_get_contents(https://getcomposer.org/composer.phar): failed to open stream: operation failed
The download failed repeatedly, aborting.
我确定 php.ini
中的 Openssl
已启用.
I'm sure that the Openssl
in php.ini
is enable.
推荐答案
启用 OpenSSL 扩展并不意味着它配置正确.
Having the OpenSSL extension enabled does not mean it is configured correctly.
无法验证 getcomposer.org
的证书.这意味着要么一些中间人服务器混淆了您的请求,要么您以某种方式没有配置默认 CA 授权集.您的服务器运营商可以告诉您更多信息.
It fails to validate the certificate for getcomposer.org
. That means either some man-in-the-middle server messes with your request or you somehow did not configure the set of default CA Authorities. Your server operator can tell you more.
相关文章