Apr 17, 2012 · Openssl.exe rsa -in priv.pem -out priv.pem Next step is extracting the public key certificate from the pfx file, there is a direct command in OPENSSL to extract the public key certificate from the pfx file but the generated file will contain public key certificate and some other information.