[英]Code Sign error: Certificate identity 'iPhone Developer: My Name (xxx)' appears more than once in the keychain
I m stuck with this error: 我坚持这个错误:
Code Sign error: Certificate identity 'iPhone Developer: My Name (xxx)' appears more than once in the keychain. 代码签名错误:证书身份'iPhone开发人员:我的名字(xxx)'在钥匙串中出现不止一次。 The codesign tool requires there only be one. 代码签名工具要求只有一个。
I try to renew the build a new CSR, remove the old certificate, build a new one, again and again and again and this error is still present 我尝试更新构建新的CSR,删除旧证书,一次又一次地构建一个新证书,此错误仍然存在
in the keychain I dont see any duplicated certificate and if I remove the only one I can see in the keychain , Xcode complains that the certificate can't be found ... 在钥匙串中我没有看到任何重复的证书,如果我删除了唯一一个我可以在钥匙串中看到的,Xcode抱怨无法找到证书......
Xcode 4.3 now searches all keychains for signing certificates but that is increasing the frequency of the build error: Xcode 4.3现在搜索所有密钥链以签署证书,但这会增加构建错误的频率:
Certificate identity (x) appears more than once in the keychain... 证书身份(x)在钥匙串中出现不止一次......
Apple's steps to resolve it are here: " How do I resolve the CodeSign error: Certificate identity appears more than once in the keychain? " Apple解决问题的步骤如下:“ 我如何解决CodeSign错误:证书身份在钥匙串中出现不止一次? ”
However, if you are affected by the keychain bug mentioned in the final note of that guide, following is a simpler and preferred solution to problem: 但是,如果您受到该指南最后一个注释中提到的钥匙串错误的影响,以下是一个更简单且首选的问题解决方案:
1) Keychain Access > Edit > Keychain List, uncheck "Shared" for the login keychain. 1)Keychain Access> Edit> Keychain List,取消选中登录钥匙串的“Shared”。
2) next, IF going back into the Keychain List you find the login keychain is still marked as Shared, create a backup of the following files and then remove them if they exist: 2)接下来,如果返回到Keychain List,您会发现登录密钥链仍然标记为Shared,创建以下文件的备份,如果存在则删除它们:
/Library/Preferences/com.apple.security-common.plist
~/Library/Preferences/com.apple.security.plist
3) Retry your build. 3)重试您的构建。
I've had the same issue after updating XCode to 4.3. 将XCode更新为4.3后,我遇到了同样的问题。 Deleting certificates and provisioning profiles didn't change anything. 删除证书和配置配置文件没有任何改变。 There were no duplicates or expired ones anyway. 无论如何,没有重复或过期的。
It turned out the problem was that my private key was in both the session and the system keychains in the keychain access. 事实证明问题是我的私钥在会话和钥匙串访问中的系统钥匙串中。 I just had to remove it from the system keychain and i could build my projects again. 我只需将其从系统钥匙串中删除,我就可以再次构建我的项目。
If you already deleted all other Developer Certificates in your KeyChain and the Error is still coming up, then try to delete all old/unused keys (private key) with your name. 如果您已经删除了KeyChain中的所有其他开发人员证书并且错误仍然存在,则尝试使用您的姓名删除所有旧/未使用的密钥(私钥)。 The one that's necessary, is the one with the little "folder-enhancer-icon" next to its name. 必要的是,在其名称旁边有一个小“folder-enhancer-icon”。 Keeping this and deleting the rest fixed it for me. 保留这个并删除其余部分为我修复了它。
I've had the same issue and I fixed it deleting every certificate from my keychain, every provisioning from my Xcode and every provisioning profile from my device and later... redone it again. 我遇到了同样的问题,我修复了它从我的钥匙串中删除每个证书,从我的Xcode中提供的每个配置以及我设备上的每个配置文件以及稍后再次重做它。 I guess, It normally happens when you are working with differents profiles and you have created many certificates for the same provisioning. 我想,这通常发生在您使用不同的配置文件并且您为同一配置创建了许多证书时。
I've had the same issue as well. 我也有同样的问题。 I think you can get to this state in a variety of ways, but for me, it was because a certificate had recently expired. 我认为你可以通过各种方式进入这个州,但对我来说,这是因为证书最近已经过期了。
What I didn't realize was that Keychain Access will hide expired certificates. 我没有意识到Keychain Access将隐藏过期的证书。 Go under "View" and make sure you're not hiding the duplicate certificate. 转到“查看”下,确保您没有隐藏重复的证书。
I had the same problem. 我有同样的问题。 I checked every related question I could find on SO and followed the steps - but had no luck. 我检查了我在SO上找到的所有相关问题并按照步骤进行 - 但没有运气。 It kept telling me that my distribution cert appeared more than once, but I could see that it only appeared once. 它一直告诉我,我的发行证书出现不止一次,但我可以看到它只出现过一次。 I revoked certificates and closed X-Code many times, but it turned out that there was a 'hidden' certificate. 我多次撤销证书并关闭X-Code,但事实证明有一个“隐藏”证书。 I had an older Distribution Certificate that was not in the login keychain . 我有一个旧的分发证书,不在登录钥匙串中 。 It was in an unnamed keychain. 这是一个未命名的钥匙串。 When I deleted that one, it worked! 当我删除那个,它工作了! So its worth looking around keychain access thoroughly! 因此,值得仔细查看钥匙串访问权限!
After moving to a new development mac, I had this problem. 转移到新的开发mac后,我遇到了这个问题。 I tried deleting the duplicates and checking that there were no hidden expired ones, but the error persisted. 我尝试删除重复项并检查没有隐藏的过期项,但错误仍然存在。 The solution that worked for me was to copy the keychain pair from the old mac and imported it in the new mac. 对我有用的解决方案是从旧mac复制钥匙串对并将其导入新mac。 The problem was then solved with the following: 然后通过以下方式解决问题:
For me, I was then able to rebuild the app successfully. 对我来说,我当时能够成功重建应用程序。
Hope that helps someone :-) 希望能帮到某人:-)
This works sometimes for me: 这有时对我有用:
Then rebuild. 然后重建。 Worked for me this minute after getting this error the millionth time. 在第一百万次获得此错误后,这一分钟为我工作。
Solution: 解:
In keychain: I've found that if you switch to the “All Items” view, on the left hand side, the deletion seems to work every time. 在钥匙串中:我发现如果你切换到左侧的“所有项目”视图,删除似乎每次都有效。 But maybe that was just blind luck. 但也许这只是盲目的运气。 Even if it fails, the act of switching back and forth between “All Items” and “My Certificates” seems to force KA to refresh the view, and tells you if the delete has “worked” yet: 即使它失败了,在“所有项目”和“我的证书”之间来回切换的行为似乎迫使KA刷新视图,并告诉你删除是否“有效”:
link: 链接:
http://viggnesh.com/blog/problem-faced/ http://viggnesh.com/blog/problem-faced/
I had this issue with XCODE 4.5, because Organizer was still keeping the developer certificates. 我在XCODE 4.5中遇到了这个问题,因为Organizer仍然保留了开发人员证书。
通过组织者 - >团队(选择您的团队) - >刷新(右下角)修复它。
我删除了所有证书和配置文件并重新启动系统并重新添加它,它工作正常。
Just move the other cer. 只需移动另一个cer。 from "login" to "system" ... and dont delete it... Trust me 从“登录”到“系统”...并且不要删除它...相信我
尝试从xcode管理器中删除证书。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.