Code Signing

Add-in Express™ Support Service
That's what is more important than anything else

Code Signing
Code signing error 
Michael Kaden




Posts: 251
Joined: 2017-11-15
Dear Andrei,

I renewed my code signing certificate. Now I get the following error.


Errorpage

I can still publish to the web, but when I install, I get all the warnings as if the code is not signed.

can you help?

Thank you & regards

Michael
Posted 09 Sep, 2019 09:05:58 Top
Andrei Smolin


Add-in Express team


Posts: 17184
Joined: 2006-05-11
Hello Michael,

Does this occur on your development machine? We suppose that the new certificate isn't installed to the root folder of the Certificate Store on your machine. Start Micirosft Managment console (mmc), choose File | Add/Remove snap-in to see certificates: your new certificate should be listed under Personal. Also, there is the node 'Trusted Root Certification Authorities'; I assume the certificate authority that you bought your certificate from is listed there.

Please note that this is far from add-ins; I may be a wrong source of info. Please use any search engine to verify whatever I say here.

Regards from Belarus (GMT+3),

Andrei Smolin
Add-in Express Team Leader
Posted 09 Sep, 2019 10:02:35 Top
Michael Kaden




Posts: 251
Joined: 2017-11-15
Thank you Andrei for your prompt answer.

The installation from the internet now works without problems. I had a smartscreen warning message but this has gone away after I have done the installation about 20 times with the new certificate in place.

Thank you for your comment, I have done all this. The certificate is listed under Personal but in the user certificates not local machine certificates. The import does not give me a choice. Strangely enough my expired certificate is listed in the local machine AND user certificates/Personal. Any advise how I get the new certificate into the local Machine Certificate Personal folder?

Please note that the warning only comes up when I build/rebuild the solution. When I publish the solution no warning comes up and everything works as intended.

thanks again & kind regards

Michael
Posted 10 Sep, 2019 01:19:39 Top
Michael Kaden




Posts: 251
Joined: 2017-11-15
Dear Andrei

Update

I now put the certificates also in the LocalMachine/Certifocates/Personal store but the issue is the same.

Publish and internet installation works perfect
Rebuild all will bring up this warning.

If I understand the exception correctly it is generated by AddInExpress.Wizard.dll?

Any help is greatly appreciated

kind regards

Michael
Posted 10 Sep, 2019 01:49:23 Top
Andrei Smolin


Add-in Express team


Posts: 17184
Joined: 2006-05-11
Hello Michael,

The AdddinExpress.Wizard.dll tries to sign your assembly and fails with the exception pointing to your certificate.

Please check pages returned by this Google search: https://www.google.com/search?client=firefox-b-d&q=how+to+install+certificate+on+windows. You may need to add to the search terms the name of the company which provides the certificate.

Regards from Belarus (GMT+3),

Andrei Smolin
Add-in Express Team Leader
Posted 10 Sep, 2019 02:02:23 Top
Michael Kaden




Posts: 251
Joined: 2017-11-15
Dear Andrei,

where is AdddinExpress.Wizard.dll looking for the certificate?

Local Machine or User account?

In which directory - Personal/ trusted Root Certification Authorities / or any other folder?

how does AdddinExpress.Wizard.dll know which certificate to look for, is it the one I enter into the publishing template?

On solution/properties, Sign the assembly is ticked and I make a new strong name key file (in this case "19alera.snk") is this correct?

Thanks & regards

Michael
Posted 10 Sep, 2019 02:35:20 Top
Andrei Smolin


Add-in Express team


Posts: 17184
Joined: 2006-05-11
Michael Kaden writes:
how does AdddinExpress.Wizard.dll know which certificate to look for, is it the one I enter into the publishing template?


Exactly. You specify a certificate, the wizard retrieves it and tries to apply. I don't know the details you're asking for. I suggest that you check the certificate vendor: it might provide an instruction for you. Is the certificate a code-signing certificate?

Michael Kaden writes:
On solution/properties, Sign the assembly is ticked and I make a new strong name key file (in this case "19alera.snk") is this correct?


Looks correct. Though this doesn't relate to using the certificate.

Regards from Belarus (GMT+3),

Andrei Smolin
Add-in Express Team Leader
Posted 10 Sep, 2019 02:41:54 Top
Michael Kaden




Posts: 251
Joined: 2017-11-15
Dear Andrei,

thank you for the prompt reply

Yes, it is a Thawte code signing certificate

In the publishing template I use "select from file" C:\aleraSoft\Code Signing\Alera19.pfx.p12 and put the password in. When I publish the solution the correct certificate is used and it works.

So, I assume that the AdddinExpress.Wizard.dll finds something wrong with this certificate when building the assembly but not when publishing?

Sorry to be missing something there.

Regards

Michael
Posted 10 Sep, 2019 03:00:36 Top
Andrei Smolin


Add-in Express team


Posts: 17184
Joined: 2006-05-11
Michael Kaden writes:
So, I assume that the AdddinExpress.Wizard.dll finds something wrong with this certificate when building the assembly but not when publishing?


I don't understand this question. Are you saying that publishing works with that certificate and building the add-in project don't?

Regards from Belarus (GMT+3),

Andrei Smolin
Add-in Express Team Leader
Posted 10 Sep, 2019 04:22:26 Top
Michael Kaden




Posts: 251
Joined: 2017-11-15
Dear Andrei,

Both work, publishing and building the project.

But with building the project I get the warning message.

Click please - This is the warning I get when building the project

When I publish the project I do not get the warning.

regards

Michael
Posted 10 Sep, 2019 07:21:19 Top