Forum Cross Platform with Xamarin

VS 2019 What is the high voodoo to get a temporary key renewed?

So I have an update for a UWP app that I want to publish. The app has been converted from PCL to a .NET version, debugged and tested ready to go. When packaging the app under Publish->Create App Packages it rejected the temporary pfx cert saying it expired. This is funny because apparently when doing my builds up until then it didn't care that the temporary certificate had expired. Something new in VS 19 as compared to VS 17? So I went through the process of creating (renewing) the certificate. But it gives me the following error:
Cannot import the following key file: TemporaryKey.pfx. The key file may be password protected. To correct this, try to import the certificate again or manually install the certificate to the Strong Name CSP with the following key container name...

What is bad about this error message is it is way too terse. What is Strong Name CSP and what is the process to manually install? According to instructions from MS docs I tried that but the error persists. What gives? I've wasted too much time on this and no developer should either. The error message is WAY too cryptic. MS needs middle managers again.

Tagged:

Best Answer

  • BrianConradBrianConrad US ✭✭✭
    Accepted Answer

    Fixed but it's kind of a bug in VS 2019. I had selected the new cert in the App Manifest Designer but the build was finding the old cert and complaining about it. You'd think once selected the new cert would have ignored the old one. Excluding the old cert from the project fixed the problem and the app is ready to upload to the store. I think we waste a lot of productivity trying to track down things like these which could have been solved even by providing a better error message.

Answers

  • BrianConradBrianConrad USMember ✭✭✭
    Accepted Answer

    Fixed but it's kind of a bug in VS 2019. I had selected the new cert in the App Manifest Designer but the build was finding the old cert and complaining about it. You'd think once selected the new cert would have ignored the old one. Excluding the old cert from the project fixed the problem and the app is ready to upload to the store. I think we waste a lot of productivity trying to track down things like these which could have been solved even by providing a better error message.

Sign In or Register to comment.