An error occurred while signing

David Shochet picture David Shochet · Dec 28, 2012 · Viewed 58.3k times · Source

I maintain a large WPF application which I inherited from another developer. I use ClickOnce to publish it. Suddenly, today I got an error message: Error 2 Cannot publish because a project failed to build. 1 1
Error 3 An error occurred while signing: Failed to sign bin\Debug\app.publish\setup.exe. SignTool Error: No certificates were found that met all the given criteria.

I do have a file called SomeName.snk, which is referred in project settings, Signing tab. I have no idea what happened today that caused the problem. I use VS 2012.

Answer

Antoine Meltzheim picture Antoine Meltzheim · Oct 21, 2013

Go to main project properties > Signing > If the expiration date is over > click on Create Test Certificate, password is not mandatory, and you're done.