Unable to upload healthvault certificate to windows azure

112 Views Asked by At

I am going crazy on the following problem: I am developing a webapplication (asp.net) for the Microsoft HealthVault. During development everything works fine.

However, I need to publish the development version (PPE) to Azure. Downloaded the publish file and 30 seconds later, my project was published on Azure. So far so good. However, a certificate must be uploaded (a .pfx) file. Although I do have the certificate as a .pfx file, I cannot upload it, because Azure requires a password in the certificate. But this certificate is auto created by the Health Vault Application Manager, and does NOT have a password.

How can I fit the certificate with a password? How am a supposed to proceed? Any thoughts, I am kind of stuck right now. As far as I can see, Microsoft itself hasn't foreseen this situation.

1

There are 1 best solutions below

1
Remus Rusanu On

Sounds like all you have to do is add a password to your pfx file. You can use certutil or openssl. I don't think either allows you to do this step directly, but both allow you to import/export the cert and private key and add a password in the process. For example Howto: Change password on pfx certificate using openssl (first Google hit):

Export you current certificate to a passwordless pem type:

[user@hostname]>openssl pkcs12 -in mycert.pfx -out tmpmycert.pem -nodes
Enter Import Password:
MAC verified OK

Convert the passwordless pem to a new pfx file with password:

[user@hostname]openssl pkcs12 -export -out mycert2.pfx -in tmpmycert.pem
Enter Export Password:
Verifying - Enter Export Password:

Remove the temporary file:

[user@hostname]rm tmpmycert.pem

(The example uses Linux openssl, but you can use the Windows version too, same syntax).