Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

OSX 10.10 import .pfx without a password?

I am attempting to import a .pfx certificate on a MacBookPro with 10.10. As I import the cert I am prompted to enter a password for the cert. I created the cert and I know there is no password. I cannot leave the password field blank as it results in an "Sorry, you entered an invalid password." error. Is there a way to import a .pfx certificate that is not encypted with a password?

like image 600
Nate Hancock Avatar asked Feb 26 '15 22:02

Nate Hancock


People also ask

Does a PFX file require a password?

pfx file does not require a password.

How do I open a PFX file on Mac?

Importing from a .p12 or .pfx FileNavigate to File > Import Items. Browse to the . p12 or . pfx file that you want to import and open it.

How do I import a PFX to a certificate store?

Start Windows Explorer and select and hold (or right-click) the . pfx file, then select Open to open the Certificate Import Wizard. Follow the procedure in the Certificate Import Wizard to import the code-signing certificate into the Personal certificate store.


1 Answers

Assuming you don't need to import the private key, you can extract the certificate from the pfx file on a machine with openssl installed using the command below.

openssl pkcs12 -in [inputFile.pfx] -nokeys -out [outputFile.cer]

If you need to import the private key to OSX, or don't have a machine with openssl, you could try importing the pfx in Windows & exporting either just the cert to a cer file or the cert & key to a new pfx with a password.

I'm not sure how you wound up with a pfx that has no password in the first place, because they contain the associated private key a password is typically required.

like image 102
Steve Avatar answered Sep 29 '22 04:09

Steve