CentOS7.6上,以root用户操作
cd /etc/pki/CA/
执行如下,注意有左右英文下的括号:
(umask 077; openssl genrsa -out private/cakey.pem 1024)
openssl req -new -x509 -key private/cakey.pem -out cacert.pem -days 365
touch index.txt serial
echo "1001" > serial
mkdir csr
--------------------------------------------------------------------------------------
组织机构申请证书步骤:
在某台自己的电脑上,系统是centOS7.6
mkdir /usr/local/nginx/https -pv
cd /usr/local/nginx/https
(umask 077; openssl genrsa -out evergreen.org.key 1024)
openssl req -new -key evergreen.org.key -out evergreen.org.csr
scp evergreen.org.csr root@192.168.1.200:/etc/pki/CA/csr
CA签署组织机构发过来的证书:
cd /etc/pki/CA/
openssl ca -in csr/evergreen.org.csr -out evergreen.org.crt -days 365
生成crt文件后,拷贝回申请证书的服务器上:
scp evergreen.org.crt root@192.168.1.202:/usr/local/nginx/https/