4
创建带有subjectAltName的自签名证书,以修复Chrome 58+中的[missing_subjectAltName]
我正在尝试创建一个自签名证书,以localhost包含subjectAltName满足Chrome 58+的要求: createcertificate.sh: #!/usr/bin/env bash filename="$1server" openssl req -new -sha256 -nodes -out ./../nginx/ssl/${filename}.csr -newkey rsa:2048 -keyout ./../nginx/ssl/${filename}.key -config <( cat ${filename}_csr.txt ) openssl x509 -req -in ./../nginx/ssl/${filename}.csr -CA ~/ssl/rootCA.pem -CAkey ~/ssl/rootCA.key -CAcreateserial -out ./../nginx/ssl/${filename}.crt -days 500 -sha256 server_csr.txt: [req] default_bits = 2048 prompt = no default_md = sha256 req_extensions = …