How can I solve error “There was an error one importing private key and signed certificate. Error message: org.bouncycastle.asn1.pkcs.PrivateKeyInfo cannot be cast to org.bouncycastle.openssl.PEMKeyPair” ? I have a .pem file with me that I converted from .pfx file exported from IIS webserver. Does the scenario explained by me in SU blog security - Enable secure port 9091 of Openfire server - Super User work?. How can I import private key and certificate from .pem file through the import-certificate.jsp console of Openfire server?