« Back to Index

Convert a P12 into a PEM and vice versa

View original Gist on GitHub

convert-p12-pem-formats.bash

# Convert p12 to pem
openssl pkcs12 -in certificate.p12 -out certificate.pem -clcerts -nodes

# Convert pem to p12
openssl pkcs12 -export -in certificate.pem -out certificate.p12 -passout pass:password