PFXExportCertStoreEx to export private and public keys

137 views Asked by At

I have used PFXExportCertStoreEx API to successfully export public and private key of a RSA certificate from Windows key store. Can the same PFXExportCertStoreEx be used to export public and private keys of DSS and ECDSA certificates from the Windows key store? If not what other API needs to be used?

Thanks in advance.

1

There are 1 answers

0
Amal Jesudas On BEST ANSWER

After days of analysis and discussions, finally I was able to identify the root cause. It is related to privileges. If I run with Admin privilege, I can use PFXExportCertStoreEx to extract keys for ECDSA certificate as well from the Local Machine certificate store. If you do not intend to use Admin privilege, just take the certificate manager or mmc and select the certificate, take All tasks > Manage Private Keys give privileges as required.