沃梦达 / 编程问答 / php问题 / 正文

在windows上安装php composer时出错

Errors in installing php composer on windows(在windows上安装php composer时出错)

本文介绍了在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.

这篇关于在windows上安装php composer时出错的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!

本文标题为:在windows上安装php composer时出错

基础教程推荐