eHealth PKCS#12 into Windows X509 Store

This is, according to me, the prefered way of doing. It is easy, safe and provides the fullest flexibility with .Net.

Steps

  • Log in on the to the machine that will run you application
  • Open explorer and navigate to you eHealth PKCS#12 file
  • Double click the .p12 file
  • Follow the steps, don't forget to make the key as exportable

Result

Your certificates and there private keys are now available on your computer. To see them you can use internet explorer.
  • Open internet explorer
  • In the menu, click: Tools -> internet options
  • Pick the content-tap
  • Click the Certificates-button

You will now see your certificates in the list of the personal-tab. You will find the eHealth certificates in the tabs of the Certificate Authorities. Double click on a certificate for more information.

Usage

It is now possible to use a certificate from both code and configuration.

When using code, use the X509Store-class. See here for more information.

In the standard .Net configuration, there are many elements that reference a certificate. In general these elements have the same input as the X509Store has. See here for an example.

Last edited Jan 29, 2011 at 10:38 AM by egelke, version 1

Comments

No comments yet.