In this blog post, you will learn how to import PFX files to your own smart card. If you have couple of pfx files and you need to put them manually on a smart card, maybe for small smart card deployment or to protect your KRAs, then you can follow the below tip.

To import PFX files to your own smart card using the Microsoft Base Smart Card Crypto Service Provider, you need to perform the following steps:

Modify the registry keys below:

  • HKLM\SOFTWARE\Microsoft\Cryptography\Defaults\Provider\Microsoft Base Smart Card Crypto Provider\AllowPrivateExchangeKeyImport=DWORD:0x1
  • HKLM\SOFTWARE\Microsoft\Cryptography\Defaults\Provider\Microsoft Base Smart Card Crypto Provider\AllowPrivateSignatureKeyImport=DWORD:0x1

Then use the certutil.exe tool to import the key stored in a pfx file into the smart card: