Cannot import the following key file error when importing pfx

后端 未结 8 1768
名媛妹妹
名媛妹妹 2021-02-01 17:03

I researched this question thoroughly on stackoverflow and I have seen numerous answers but none of them have worked for us yet. We recently bought a code signing certificate fr

8条回答
  •  忘了有多久
    2021-02-01 17:37

    I had the same issue. I am building the application from a thumb drive on numerous computers and believe this is the cause.

    I found success with the "sn -i [comodo].pfx VS_KEY_xxxxxxxxxxxxx" method. I did the following steps:

    1. Run "Developer Command Prompt" as administrator (found in Start->All Programs->Visual Studio->Tools)
    2. Navigate to your key directory (for me this was the root of my project directory, not the solution directory)
    3. Execute "sn -i mykey.pfx VS_KEY_xxxxxxxxxxxxx" (mykey.pfx and VS_KEY_xxxxxxxxxxxxx are both found in the build error message)
    4. Enter the password if required

    When I tried this without running "Developer Command Prompt" as an administrator, I get the help display text when running "sn -i mykey.pfx VS_KEY_xxxxxxxxxxxxx" and it does not work. The trick was to make sure I ran the develop prompt as an administrator.

    For context, I am using VS Community 2013.5, Window 7 x64 Professional, and NET Framework 4.7

提交回复
热议问题