Inno Setup - Signing fails with “Sign Tool failed with exit code 0x1”

风格不统一 提交于 2019-11-26 12:32:02

问题


I have Inno Setup script, where I need to use the SignTool=signtool, which is configured properly and worked in past.

But it\'s failing when I try to compile with the following error:

Sign Tool failed with exit code 0x1.


回答1:


You didn't provide us any information that we can use to debug your problem.

So I'm posting generic instructions to debug issues with a "sign tool".

  1. Try command-line compiler (ISCC.exe). It will preserve a full signtool.exe error message in the output:

  2. Or temporarily prefix the sign tool command with cmd.exe /k to preserve its output even when compiling in Inno Setup GUI Compiler. E.g.:

    cmd.exe /k C:\path\to\signtool.exe sign /f C:\mykey.pfx $f
    


See also signtool fail with Inno Setup with exit code 0x1.




回答2:


When using an EV with a token, you can assign the fingerprint using /a /sha1 [Hash].

like so:

signtool sign /tr http://timestamp.digicert.com /td sha256 /fd sha256 /sha1 certfingerprint $f

This will make signtool to choose the cert from token.

More info: https://docs.microsoft.com/en-us/dotnet/framework/tools/signtool-exe



来源:https://stackoverflow.com/questions/39685417/inno-setup-signing-fails-with-sign-tool-failed-with-exit-code-0x1

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