Create pfx file from certificate and private key

Print Friendly

In order to create a pfx file we will need the certificate (crt file) and the private key file.
We need to download and install OpenSSL for windows https://slproweb.com/products/Win32OpenSSL.html.

The first step is to give the same filename to both files (crt and private key) and give the extension .key to the private key file.
So assuming we have the 2 files certificate.crt and certificate.key we have to open OpenSSL and execute the following command:

openssl pkcs12 -export -out newcertificate.pfx -inkey certificate.key -in certificate.crt

We will be asked for a password for the pfx file and we are done.

This entry was posted in Windows. Bookmark the permalink.

Leave a Reply

Your email address will not be published.