在MacOS X上对PyInstaller生成的可执行文件进行代码签名不予尊重

时间:2016-05-27 10:46:33

标签: python macos sandbox pyinstaller

在os x的沙箱中,我的应用程序将调用包含由Pyinstaller生成的一个可执行文件的XPC服务。但我被告知我需要代码签名我的" Python"文件。我可以指定一个签名的#34; Python文件"当我生成单个可执行文件?以下是错误:

kernel[0]: CODE SIGNING: process 32173 [obfsproxy-xpc-se]: rejecting invalid page at address 0x107be7000 from offset 0x1000 in file "/private/var/folders/nt/j_7h77js7bsfvhw4s44k7cf40000gn/T/com.houlin.obfsproxy-xpc- server/_MEINzOiO6/Python" (cs_mtime:1464339917.0 == mtime:1464339917.0) (signed:1 validated:1 tainted:1 wpmapped:0 slid:0)

现在我使用以下代码对文件进行了代码签名:

codesign -f -s "3rd Party Mac Developer Application: lin hou (KF34Q87E4G)" --entitlements /Users/houlin/workspace1/vpn_master/obfsproxy-xpc-service/obfsproxy-xpc-service.entitlements //Python*

但是,我仍然会收到以下错误:

16/5/28 下午6:47:42.000 kernel[0]: CODE SIGNING: process 29381[obfsproxy-xpc-se]: rejecting invalid page at address 0x108249000 from offset 0x1000 in file"/private/var/folders/nt/j_7h77js7bsfvhw4s44k7cf40000gn/T/com.houlin.obfsproxy-xpc-server/_MEI4o6uYx/Python" (cs_mtime:1464432462.0 == mtime:1464432462.0) (signed:1 validated:1 tainted:1 wpmapped:0 slid:0) 16/5/28 下午9:26:45.060 com.apple.xpc.launchd[1]: (com.houlin.obfsproxy-xpc-server[29702]) Binary is improperly signed.

我对此处生成的捆绑文件进行了代码签名。

enter image description here

以下是info.plist:

enter image description here enter image description here

1 个答案:

答案 0 :(得分:0)

试试这个食谱。 code signing in pyinstaller