Training

How do I convert a certificate from .pem format to .der or .cer format?

1 min read

The following openssl command can be used to convert a certificate in .pem format to .der format:

# openssl x509 -in MYCERT.pem -inform PEM -out MYCERT.der -outform DER

The following openssl command can be used to convert a certificate in .pem format to .cer format:

# openssl x509 -in MYCERT.pem -inform PEM -out MYCERT.cer -outform DER

For more information, please see the OpenSSL x509 documentation available here.

Get articles like this in your inbox: