ios 代码签名错误:未找到包含任何钥匙串签名证书的未过期配置文件

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/9982788/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-30 17:40:51  来源:igfitidea点击:

Code Sign error: No unexpired provisioning profiles found that contain any of the keychain's signing certificates

ioscode-signingios-provisioning

提问by Matt Miller

I think I've reached the nadir of iOSprovisioning hell. After migrating to a new mac and doing an archive for distribution, I received the error:

我想我已经达到了iOS供应地狱的最低点。迁移到新 mac 并进行分发存档后,我收到错误消息:

Code Sign error: No unexpired provisioning profiles found that contain any of the keychain's signing certificates

代码签名错误:未找到包含任何钥匙串签名证书的未过期配置文件

I then erased all certs and keys and provision profiles and did a "hard reset" (deleting all keys, certs, and profiles), following Apple's instructions by hand, with the same error. Then I did another hard reset and then had Xcode handle the whole thing via the Organizer, did another archive - only to see the same error.

然后,我按照 Apple 的手动指示删除了所有证书和密钥以及配置文件,并进行了“硬重置”(删除所有密钥、证书和配置文件),但出现了相同的错误。然后我又做了一次硬重置,然后让 Xcode 通过 Organizer 处理整个事情,做了另一个存档 - 只是看到了同样的错误。

I have all certs (WDRCA, Developer ID Cert Authority, iPhone Dev, iPhone Distribution) showing in Keychain Access, Xcodeshows that it sees the dev and distribution certs, as well as the provisioning profiles, all marked with a green checkmark and "valid" status.

我在 Keychain Access 中显示了所有证书 ( WDRCA, Developer ID Cert Authority, iPhone Dev, iPhone Distribution),Xcode表明它可以看到开发和分发证书以及配置文件,所有这些都标有绿色复选标记和“有效”状态。

Code signing within the app show the correct dev and distribution is selected.

应用程序中的代码签名显示选择了正确的开发和分发。

What's really troubling is that a Google search on the error shows one tech notefrom Apple that isn't very helpful, 2 tweets, and 3 results in Japanese - and nothing else. I contacted one of the tweeps and he said he fixed it with a hard result, which I have done twice.

真正令人不安的是,谷歌对该错误的搜索显示了一份来自 Apple 的技术说明,但不是很有帮助,2 条推文和 3 条日文结果——除此之外别无他物。我联系了tweeps之一,他说,他用硬结果,我已经做了两次固定它。

Any ideas on where to go or what to do next?

关于去哪里或下一步做什么的任何想法?

采纳答案by Matt Miller

After nine hours of hair pulling, cursing and burying my head in my hands... All I had to do was create a new project, transfer the files over by hand, and the error went away. Argh.

经过九个小时的头发拉扯,诅咒和将头埋在我的手中......我所要做的就是创建一个新项目,手动传输文件,错误消失了。啊。

Update: My marking my own answer as correct does not mean these other answers were wrong - I didn't get a chance to try any of them.

更新:我将自己的答案标记为正确并不意味着这些其他答案是错误的 - 我没有机会尝试其中任何一个。

回答by Uladzimir

Fixed it by Organizer -> Teams (select Your Team) -> Refresh (low right corner).

通过组织者 -> 团队(选择你的团队)-> 刷新(右下角)修复它。

回答by Marc

After removing all devices/profiles/certificatesand adding/creatingit did still not work here too....also removing the Xcode prefs did not help.

删除所有内容后devices/profiles/certificatesadding/creating它仍然无法在这里工作......也删除 Xcode 首选项也没有帮助。

but it seems to in the project settings, check in the build settings under CODE_SIGN_IDENTITIY, in my project the first line was set to a old profile but not visible in the list, only if you open the pulldown, after removing that it worked.

但它似乎在项目设置中,检查下的构建设置CODE_SIGN_IDENTITIY,在我的项目中,第一行设置为旧配置文件,但在列表中不可见,只有当您打开下拉菜单后,它才能工作。

回答by Chad Meyer

I just had this problem as well. I finally realized that the identifier is case sensitive. For example if your product name is "StackOverflow" it automatically tags the identifier with com.yourcompanyname.StackOverflow. (this of course can be changed by going to the summary of the target). The problem lies in what the app id is in the developer portal. Make sure that the identifier in the portal matches what's in Xcode.

我也刚遇到这个问题。我终于意识到标识符区分大小写。例如,如果您的产品名称是“StackOverflow”,它会自动使用 com.yourcompanyname.StackOverflow 标记标识符。(这当然可以通过转到目标摘要来更改)。问题在于开发者门户中的应用程序 ID 是什么。确保门户中的标识符与 Xcode 中的标识符相匹配。

回答by Marc

I have the same issue here since Xcode 4.3 install (moving from /Developer to /Applications). I found this postfor changing the Xcode dir

自 Xcode 4.3 安装(从 /Developer 移动到 /Applications)以来,我在这里遇到了同样的问题。我发现这篇文章用于更改 Xcode 目录

in the terminal check what path it is set to with:

在终端中检查它设置的路径:

/usr/bin/xcode-select -print-path

/usr/bin/xcode-select -print-path

and then if it is still set to /Developerset it to /Applications:

然后如果它仍然设置/Developer/Applications

sudo /usr/bin/xcode-select -switch /Applications

sudo /usr/bin/xcode-select -switch /Applications

which worked for me to be able to do the update to 4.3.2 but this did not resolve the issue mentioned....so maybe it helps you.

这对我有用,能够更新到 4.3.2 但这并没有解决提到的问题......所以也许它对你有帮助。

回答by andrew chu

i 've met the same problem.

我遇到了同样的问题。

the answer of the problem is simple.

问题的答案很简单。

you need to login your apple develpoer web site to apply and download a profile for your app .

您需要登录您的 Apple develpoer 网站才能为您的应用程序申请和下载配置文件。

after double-click the download file , you can see the file in organization of the project in xcode .

双击下载文件后,可以在xcode中看到项目组织中的文件。

the name of the bundle id is the type like com.yourname.appname

捆绑ID的名称是像com.yourname.appname类型

the xcode device choose the ios device and the codesign of the target should choose distribution which is one of the file in organization of the project in xcode .

xcode 设备选择 ios 设备,目标的协同设计应选择分布,它是 xcode 项目组织中的文件之一。

f.y.i.

供参考

回答by user1443032

I went straight to "but it seems to in the project settings, check in the build settings under CODE_SIGN_IDENTITIY, in my project the first line was set to a old profile but not visible in the list, only if you open the pulldown, after removing that it worked."

我直接去了“但它似乎在项目设置中,检查 CODE_SIGN_IDENTITIY 下的构建设置,在我的项目中,第一行设置为旧配置文件但在列表中不可见,只有当你打开下拉菜单,删除后它奏效了。”

And that seems to have done the trick.

这似乎成功了。

回答by JoriDor

I fixed it by updating the bundle identifier in the project settings > targets > appName in the info tab.

我通过更新信息选项卡中的项目设置 > 目标 > appName 中的包标识符来修复它。

回答by HenryRootTwo

I had this problem, and fixed it by putting my scheme back to Debug, as opposed to Release.

我遇到了这个问题,并通过将我的方案放回调试而不是发布来修复它。

回答by Carl Hoffstedt

I faced the same problem after upgrading to Xcode 4.3.2and SDK 5.1. Everything worked perfectly in the previously version of Xcodewith SDK 5.0. After many hours of hair pulling I created a new distribution certificate in the iOS Provisioning Portal->Provisioning-> Distribution Taband after downloading it and installing it into Xcode(drag-and-drop) it works to archive after selecting the new certificate in the Code Signing areafor my target.

升级到Xcode 4.3.2和后我遇到了同样的问题SDK 5.1。在以前版本的Xcodewith 中一切正常SDK 5.0。经过几个小时的头发拉扯,我创建了一个新的分发证书,iOS Provisioning Portal->Provisioning-> Distribution Tab下载并安装到Xcode(拖放)后,它可以在Code Signing area为我的目标选择新证书后进行存档。