Domanda

Possible Duplicate:
Outputed py2exe exe won't run only when signed: ImportError

I am making a program using Python 3.2. I use cxfreeze to turn the scripts into an executable. The frozen executable runs fine when run without changes. When I tried to sign the executable using signtool.exe, the exe raises ImportError. Is there a way to digitally sign a frozen python3 executable?

Thanks!.

È stato utile?

Soluzione

From here:

There are three different options for producing executables as well. The first option is the only one that was available in earlier versions of cx_Freeze, that is appending the zip file to the executable itself. The second option is creating a private zip file with the same name as the executable but with the extension .zip. The final option is the default which is to create a zip file called library.zip and place all modules in this zip file.

It is evident why this would fail, when reading the (in my opinion duplicate) topic here. Different version of the language, yes. Different tool, yes. Different approach, no! It is evident from the error you get that you are using that first option and signtool will interfere with the payload.

Altri suggerimenti

As far as I understand, signtool.exe is only there to sign .NET based app. Since your app is not .NET based, this failure (exception) takes place.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top