How do I get the .pfx file?

China☆狼群 提交于 2020-01-24 01:49:29

问题


I am working on a UWP app. I store the source code in Azure DevOps Services. I can debug it fine on my desktop PC. However, I cannot on my laptop. The issue is that I don't have the .pfx file necessary for debugging, on my laptop. I returned from the Microsoft Ignite conference, where I learned that I should copy the .pfx from off of my desktop onto my laptop. So I tried to find it (it's named Blank_TemporaryKey.pfx), but it isn't in the directory. Looking at Visual Studio I see that it has a yellow triangle next to the file in the Solution Explorer. My guess is that somehow it was deleted, but what VS 2019 needs for me to debug it on the desktop is already in place.

What I'd like to know now is if it is possible to extract what is needed for a .pfx file, from what's on my desktop, so I can use it on my laptop for this project?

Here's a screen shot of what I'm seeing in Solution Explorer on my desktop:


回答1:


You can manually generate a new test certificate in Package.appxmanifest.

If you use a .gitignore file that is automatically generated by Visual Studio, the .pfx certificate file is in its ignore list and will not be uploaded to the codebase. However, this certificate file is recorded in the file list of the solution, so there will be a prompt to find the file after the initial synchronization.

The reason for this design is that the test certificate is generated based on your device and current account. When you replace another device for development, the fingerprint of the original test certificate cannot match, you need to generate a new certificate.

Best regards.



来源:https://stackoverflow.com/questions/58793944/how-do-i-get-the-pfx-file

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!