openssl常见命令
查PEM格式证
openssl x509 -in ${NAME_FILE} -text -noout
查DER格式证书
openssl x509 -in ${NAME_FILE} -inform der -text -noout
DER格式转PEM
openssl x509 -inform DER -in ${NAME_CERT_DER} -out ${NAME_CERT_PEM}
证书和私钥转PKCS#12
openssl pkcs12 -export -out ${NAME_CERT_P12} -in ${NAME_CERT_PEM} -inkey ${NAME_PRIV_KEY} -passin pass:${PASSWD} -passout pass:${PASSWD}