How to create a UWP app with a certificate that can be loaded

I am trying to create a UWP app that can be loaded onto other PCs. My main question is, do I need a certificate from a trusted source to sign my application?

After much chatting, I found out that you can download / install UWP apps via the App Installer from the Windows Store. After installing the App Installer, you can install UWP apps by double-clicking the file .appxbundle

. (Not using a file .ps1

as mentioned here )

Before doing this, I will need to trust the certificate. I created this certificate through Visual Studio. It was created by double clicking .appxmanifest

on Packaging

, selecting Choose Certificate

Configure Cerfiticate

and then Create test certificate

.

I tried to install my application on two different Windows 10 machines. On one machine, the application will fail saying that the package may conflict with another package or depends on what is not installed (something is wrong), but on the other computer it will to the certificate error (although I am trusted and added the certificate to my trusted certificates).

Do I need a certificate issued by a trusted authority to make it work? I was under the impression that my certificate should work if the user trusts it, but the app doesn't seem to install.

Also, if I need a trusted certificate, how do I create this file pfx

? And where do I get it from? Microsoft documentation doesn't seem to mention anything.

+3


source to share


2 answers


It turns out I had no dependencies installed. I added a certificate to Local Computer

(not the current user) in Trusted Root Authorities Section

. After that, I was still getting the error that the package depends on something that was not installed. It turned out to be true! According to the app installer page

The app installer does not automatically install framework dependencies. In most cases, your device already has dependencies, but there are some developer or enterprise scenarios where you need additional infrastructure. In this case, just go to the dependencies folder with your application and install the dependency infrastructure like any application using the Installer app!



The dependencies were in the Dependencies folder that was created by Visual Studio. After installing them, the application has been successfully installed!

+2


source


Make sure the certificate is added to the store Trusted People

(it's not a typo - it's People ). Another error can be caused if you don't have the correct Framework packages installed or if you've previously installed the app and haven't changed the version number in the manifest.



+1


source







All Articles