配置完https后,服务起不来

来源:4-19 基于Nginx的HTTPS服务_证书签名生成和Nginx的HTTPS服务场景演示1

慕虎3033596

2017-12-18

http://img.mukewang.com/szimg/5a3784e100010d4a12790103.jpg

写回答

3回答

慕村1342571

2019-01-02

参考网上的方法,或者直接用老师后面的方法,就是不用输入密码那种,貌似是可以。

步骤1:openssl genrsa -des3 -out ca.key 2048

步骤2:openssl rsa -in ca.key -out ca.key

步骤3:openssl req -new -key zhaoy6.key -out ca.csr

步骤4:openssl x509 -req -days 3650 -in ca.csr -signkey ca.key -out ca.crt

步骤5:

nginx -tc /etc/nginx/nginx.conf

nginx: the configuration file /etc/nginx/nginx.conf syntax is ok

nginx: configuration file /etc/nginx/nginx.conf test is successful


1
3
慕村1342571
3、生成证书签名文件 openssl x509 -req -days 3650 -in ca.csr -signkey ca.key -out ca.crt Signature ok subject=/C=CN/ST=SiChuan/L=ChengDu/O=UNICOM/OU=INFO/CN=ca.com/emailAddress=ca@chinaunicom.cn Getting Private key Enter pass phrase for ca.key: 输入刚才的密码 4、验证 nginx -tc /etc/nginx/nginx.conf nginx: [emerg] SSL_CTX_use_PrivateKey_file("/etc/nginx/conf.d/ssl_key/ca.key") failed (SSL: error:0906B072:PEM routines:PEM_get_EVP_CIPHER_INFO:unsupported encryption error:140B0009:SSL routines:SSL_CTX_use_PrivateKey_file:PEM lib) nginx: configuration file /etc/nginx/nginx.conf test failed
2019-01-03
共3条回复

慕村1342571

2019-01-02

nginx -tc /etc/nginx/nginx.conf


nginx: [emerg] SSL_CTX_use_PrivateKey_file("/etc/nginx/conf.d/ssl_key/zhaoy6.key") failed (SSL: error:0906B072:PEM routines:PEM_get_EVP_CIPHER_INFO:unsupported encryption error:140B0009:SSL routines:SSL_CTX_use_PrivateKey_file:PEM lib)

nginx: configuration file /etc/nginx/nginx.conf test failed

按照操作,报SSL签名错误

0
0

Jeson

2017-12-18

可以截个清楚图给我吗?这个图它小了,看不清楚。

0
3
慕虎3033596
报这个错
2017-12-19
共3条回复

Nginx入门到实践-Nginx中间件应用+搭建Webserver架构

中间件、负载均衡、应用层安全防护、动静分离、Nginx+LUA开发等

4183 学习 · 908 问题

查看课程