Inno Setup - 签名失败,显示“签名工具退出代码为0x1”

3
我有一个Inno Setup脚本,需要使用SignTool=signtool,这个已经配置好并且过去也能正常工作。
但是当我尝试编译时,出现以下错误:

签名工具退出代码0x1。

请参考以下图片: 图片描述 图片描述

4
你是否尝试直接通过命令行运行Sign命令来查看是否也失败了?这样你就可以看到适当的错误消息。你能否在不进行签名的情况下编译安装程序?我曾经遇到过类似的问题,因为Windows将Compil32.exe视为不受信任的进程而阻止访问安装程序的临时文件。 - undefined
2个回答

8

您没有提供任何可用于调试问题的信息。

因此,我将发布通用指令来调试“签名工具”问题。

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

    enter image description here

  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
    

    enter image description here

    Note that if you use a path to signtool.exe with spaces, due to the way cmd works, you have to wrap not only the path itself to double quotes, but also the whole command:

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

另请参阅使用exit code 0x1与Inno Setup运行signtool失败


0

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接