Experiencing [invalid package publisher name] error

Peachy Pixels 11 Reputation points
2021-05-17T19:05:31.553+00:00

Hello!

I am trying to submit a game (built in Unity) to the store (as a UWP app) but am experiencing issues with regards to the certificate and publisher name.

My test certificate (built in Unity) has a publisher name of "CN=<NAME>"

After building the UWP solution (in Unity) I then associate the app with the store (from within Visual Studio) and this changes the publisher name to "CN=<ID>"

When I then build the store package, I receive the following error...

warning : Publisher name (CN=<ID>) does not match signing certificate subject: CN=<NAME>. Updating Publisher name.

Upon submitting the package to the store, I then finally receive the following error...

Invalid package publisher name: CN=<NAME> (expected: CN=<ID>)

If (during the app association process) I select the certificate from the store, it sets the publisher name to "CN=<NAME>" and the error messages are then the reverse of the above.

Basically, I am unable to perform an error free build and submit the package to the store (although it was working until recently)

The app store id is 9NJ24KCM1NSS

After a little investigation, it seems there was a Visual Studio bug that could cause this. But it was fixed last year and I am using the latest at the time of writing (16.9.5)

So I would be very grateful if someone could look into this please and let me know if it's an issue on my end or with Visual Studio or the store.

Kind regards
David

Visual Studio
Visual Studio
A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.
5,103 questions
Microsoft Partner Center
Microsoft Partner Center
A Microsoft website for partners that provides access to product support, a partner community, and other partner services.
982 questions
{count} votes

3 answers

Sort by: Most helpful
  1. Connor Park 36 Reputation points
    2021-08-02T07:43:18.283+00:00

    Hi

    I am also having the same problem. It seems that the Publisher and Packag family name registered in the store are not used and the app is packaged using a local certificate.

    I've been testing all day today. In the past, when connecting to the store, the pfx file was added to the project and the build was carried out with the private key, but is that not the case now? How can I package without a pfx file for the store? It seems that this issue should be dealt with quickly.

    After searching several places, I found a solution. I started the app approval process with the second solution below.
    Many thanks to James.

    Hi @CP_98 Park,

    There are a couple ways we can try to fix this:

    Solution 1

    Upgrade to at least Visual Studio to 16.11 Preview 2 or wait until 16.11 is officially released soon.
    Add the property <GenerateTemporaryStoreCertificate>true</GenerateTemporaryStoreCertificate> to your project file.

    Solution 2

    Open the Manifest Designer using right click -> open on Package.appxmanifest.
    Navigate to the Packaging tab and click the ‘Choose Certificate…’ button.
    Click the ‘Create…’ button in the new dialog.
    In the ‘Publisher Common Name’ textbox, enter your store publisher name WITHOUT the “CN=” prefix. e.g. AF9XXXXX-XXXX-XXXX-XXXX-XXXXXXXXCCB8
    Click the ‘OK’ button.
    Click the ‘OK’ button.
    Save the file and solution.

    Let me know which solution you attempt to use and how it goes.

    Thank you,
    James

    3 people found this answer helpful.

  2. Ralf Armin Böttcher 1 Reputation point
    2021-05-27T12:52:13.823+00:00

    Hi,

    I have the same problem on Visual Studio 16.10

    Building the Unity3D project and running it in Visual Studio will show the self created certificate data under Packaging in the Package.appxmanifest.
    Using Publish - Associate App will show the correct Publisher (greyed out), Publisher display name and Package family name in the Packaging window (greyed out).

    However, if I create packages then the error message appears
    Warning Publisher name (CN=[ID from partner center]) does not match signing certificate subject: CN=RAB-Software. Updating Publisher name.

    double click on the message shows: [...]AppxPackage\Microsoft.AppXPackage.Targets 2698

    So it looks like that Visual Studio is still using the self created certificate and not the certificate from partner center. Is there a way of forcing VS to use the correct certificate?

    Another question would be if this is an Unity3D bug (building the VS project wrong) or a problem on the Microsoft side...

    Thank you and kind regards!

    0 comments No comments

  3. Jon Templin 161 Reputation points
    2021-08-14T16:23:58.857+00:00

    I also had this issue in 16.10.3. I used Solution 1 in the above post by @Connor Park to successfully build a store package that passed upload validation by the Partner Center.

    Sigh. It seems I have store packaging issues each time I use an upgraded Visual Studio. Publishing apps shouldn't be this difficult.

    Thanks to the other posters for their help. I would have been spinning my wheels all afternoon without your help.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.