I have a .cer certificate, .key file and I would like to convert it to the .pem format.
How do I convert them to .pem?
I have a .cer certificate, .key file and I would like to convert it to the .pem format.
How do I convert them to .pem?
Assuming you have the .key PK,
and .cer/.crt/.cert file in the correct format
(i think common-name is mandatory)
// in Linux
cat x.key x.cert > x.pem
// in Windows
copy /b x.key+x.cert x.pem
I used openssl to do the conversion and it works.
Convert 'certificate.cer' to 'certificate.pem'
openssl x509 -inform DER -in certificate.cer -out certificate.pem
Convert 'yourkeyfile.key' to 'yourkey.pem'
openssl rsa -in yourkeyfile.key -out yourkeyfile.pem
Bundle both certificate.pem and yourkey.pem as a single cert+key.pem
cat certificate.pem yourkey.pem > cert+key.pem