Skip to content
Blog How to Convert a Apple Certificate .p12 file to a PEM File

How to Convert a Apple Certificate .p12 file to a PEM File

To convert PKCS#p12 file to a PEM file, use:

openssl pkcs12 -in cert.p12 -out cert.pem -nodes -clcerts

Now you will have both the certificate and key in the cert.pem file without a password.

If you need the certificate and key in separate files, use this:

openssl pkcs12 -in cert.p12 -out cert.pem -clcerts -nokeys
openssl pkcs12 -in cert.p12 -out key.pem -nocerts -nodes

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.