Xamarin"可执行文件是使用无效的权利签署的"

eis*_*tee 6 iphone xamarin.ios entitlements ios provisioning-profile

我想在iPhone上测试我创建的iOS应用程序.构建成功但是当xamarin工作室尝试通过usb将文件传输到我的iPhone时,我收到以下错误:

VerifyingApplication: 70%
  PercentComplete: 40
  Status: VerifyingApplication
 ApplicationVerificationFailed: Failed to verify code signature of /private/var/installd/Library/Caches/com.apple.mobile.installd.staging/temp.yNZx88/extracted/<APPName>.app : 0xe8008016 (The executable was signed with invalid entitlements.)
error MT1006: Could not install the application '/Users/<NAME>/Projects/<APPName>/<APPName>/bin/iPhone/Debug/device-builds/iphone8.2-10.2.1/<APPNamr>.app' on the device '<DEVICEName>': Your code signing/provisioning profiles are not correctly configured. Probably you have an entitlement not supported by your current provisioning profile, or your device is not part of the current provisioning profile. Please check the iOS Device Log for details (error: 0xe8008016).
--- inner exception
Xamarin.Installation.FailedInstallException: Your code signing/provisioning profiles are not correctly configured. Probably you have an entitlement not supported by your current provisioning profile, or your device is not part of the current provisioning profile. Please check the iOS Device Log for details (error: 0xe8008016)

[...]

Application could not be uploaded to the device.
Run Code Online (Sandbox Code Playgroud)

我是xamarin的新手,不知道该怎么做.Apple开发人员帐户可用,并创建证书和配置文件.电话将添加到设备列表中,并创建标识符.

谁能帮我?

Too*_*eve 12

不是Xcode中的日志 - 那些是崩溃日志.这里需要的是Xamarin/View/Pad"设备日志".安装应用程序时,消息将滚动.

安装失败后,"全选/复制/粘贴"到文本编辑器中.搜索安装失败.在它应该是一些提供更多信息的线之前.具体来说,它将阐明这两种可能性中的哪一种是问题:1)权利或2)关于设备的东西.

我敢打赌它的权利.您需要隔离导致问题的权利.你在使用推送通知吗?iCloud?那些可能是罪魁祸首.或者可能是与隐私相关的权利之一 - 确保您遵循iOS 10的当前说明,该说明具有比早期iOS版本更严格的隐私设置.

看看源代码Entitlements.plist.保存一份远离项目的地方.从空白开始(空)Entitlements.plist.[如果您的项目文件夹中没有该文件,请添加带有该名称的空文本文件.]您是否可以部署到手机?

当然,您将无法使用所需的权利,虽然这是空白的,但您应该可以获得应用程序的第一个屏幕,或者至少有一些Apple对话框询问用户是否允许.你需要什么样的权利......

然后添加到Entitlements.plist您无法部署.谷歌针对那个具体问题 - 希望有一个解决方案.


另一种可能性是您的配置文件缺少您要求的权利.返回Apple开发人员网站,其中列出了您的证书和配置文件.选择提供者.您正在使用的个人资料 在"启用的服务"下,确保它列出您正在使用的服务.
(某些Apple功能不需要特定权利;如果有疑问,请创建新的配置文件,并仔细查看权利的所有选项,以及您正在使用的任何功能.)


小智 9

如果您的规定在您添加并设置"Entitlements.plist"(例如Icloud)之前有效,那么:

您需要从配置中删除"Entitlements.plist".

项目选项> IOS捆绑签名>自定义权利(保持空白).

  • 我浪费了几个小时试图弄清楚这有帮助。我想知道为什么当我显然从列表中选择它并且文件在那里时,Entitlements.plist 不能作为一个值工作,这表明它已经被使用了。 (2认同)