简体   繁体   English

代码签名错误

[英]Code Signing Error

The company I am working for has a base app that they reskin and sell to different businesses. 我正在工作的公司有一个基础应用程序,可以重新设计并出售给不同的企业。 I have redesigned the app and am trying to upload it to their account but am getting: 我已经重新设计了该应用程序,并试图将其上传到他们的帐户,但得到:

[BEROR]Code Sign error: The identity 'iPhone Distribution' doesn't match any
valid certificate/private key pair in the default keychain

How do I add their developer account into my Xcode and acquire a certificate for distribution? 如何将他们的开发者帐户添加到我的Xcode中并获取分发证书?

Thank you 谢谢

Basically, you need to have maximum privileges in the Provisioning Portal to do the following, so if you don't, get it, and then do this: 基本上,您需要在Provisioning Portal中拥有最大权限才能执行以下操作,因此如果不这样做,请获取它,然后执行以下操作:

  1. Login and download a developer certificate . 登录并下载开发人员证书 If you need to create one, select How To from the menu in the Provisioning Portal under certificates. 如果你需要创建一个,选择如何从Provisioning户菜单下的证书。
  2. Download a distribution certificate . 下载发行证书 Again, if you need one, select How To . 同样,如果您需要,请选择“ 如何”
  3. Open both certificates and make sure they open in your Keychain Access 打开两个证书并确保它们在您的Keychain Access中打开
  4. Select provisioning and download both a developer and distribution .mobileprovision provisioning profile. 选择配置并下载开发人员和分发.mobileprovision配置文件。 Create one if necessary using How To 如有必要,使用“ 如何”创建一个
  5. Make sure you have XCode open and open both .mobileprovisioning profiles. 确保已打开XCode并打开两个.mobileprovisioning配置文件。 Make sure that they open in the Organizer and show in the status that they are properly linked with a certificate that is valid in the Keychain Access . 确保它们在管理器中打开,并显示它们与Keychain Access中有效的证书正确链接的状态。 If they aren't, a flag will pop up, saying something like "There is no valid certificate associated with this profile" in bright red. 如果不是,则会弹出一个标志,并以红色显示类似“没有与此配置文件关联的有效证书”的信息。
  6. Check your code signing in both the Target and Project areas of your build. 检查构建的目标项目区域中的代码签名。 Make absolutely sure that both are trying to sign using your distribution profile . 确保两者都尝试使用您的分发配置文件进行签名。
  7. Make sure that you are building the distribution scheme of your app (You may have to create this). 确保您正在构建应用程序的分发方案 (您可能必须创建一个)。
  8. Finally set the build device to iOS Device, set the scheme to Distribution, and select Archive. 最后,将构建设备设置为iOS Device,将方案设置为Distribution,然后选择Archive。 It is imperative that when the program asks you to allow the code signing to use your private key, that you select "Allow" and not "Always Allow," as this is very buggy and often results in code signing errors. 当程序要求您允许代码签名使用私钥时,必须选择“允许”而不是“始终允许”,因为这非常容易出错,并且经常会导致代码签名错误。

If you need any more help, comment. 如果您需要更多帮助,请发表评论。

Hope this helps! 希望这可以帮助!

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM