Converting Certificates to PFX Format

<< Click to Display Table of Contents >>

Navigation:  SSL Certificates >

Converting Certificates to PFX Format

The system only supports files in PEM format. If you have your certificate or private key in another format, you must first convert the file to PEM format.

 

The PFX file is a package that contains the private key and the certificate, encrypted within the same file. To extract the private key and certificate, follow these steps:

 

1.Extract the private key

 

The first step is to extract the private key from the certificate file:

 

openssl pkcs12 -in certificate.pfx -nocerts -out PrivateKey.pem

 

When you press Enter, provide the export password for the pfx file and also provide a new password for the private key file.

 

Now we'll generate the SSLKey file (assuming the key is RSA), using the following command:

 

openssl rsa-in PrivateKey.pem -out SSLKey

 

Press Enter to supply the password for the private key file created in the previous step.

 

2.Extract the certificate

 

The second step is to extract the certificate from the file:

 

openssl pkcs12 -in certificate.pfx -clcerts -nokeys -out SSLCert

 

3.Root certificate

 

The generated certificate will also be used as the root certificate, so copy the SSLCert file to SSLRootCert

 

copy SSLCert SSLRootCert

 

Now you have the SSLCert, SSLRootCert and SSLKey files, copy these files and replace them in the system installation folder to load the certificates and restart the services.