CodeSign error: Certificate identity 'iPhone Developer:xxx appears more than once in the keychain.

来源:互联网 发布:phpstorm js压缩 编辑:程序博客网 时间:2024/04/28 23:42
当重新下载安装了.cer文件,更新了profile 后,再编译iphone项目时,发现下面的错误:
CodeSign error: Certificate identity 'iPhone Developer:xxx appears more than once in the keychain'

这是证书重复的错误,需要将钥匙串里重复的证书删掉编译才能通过。

打开钥匙串访问CodeSign <wbr>error: <wbr>Certificate <wbr>identity <wbr>'iPhone <wbr>Developer:xxx <wbr>appears <wbr>more <wbr>than <wbr>once <wbr>in <wbr>the <wbr>keychai ,将重复出现的iPhone Developer:XXXXX 证书删除只留下最近安装的,重新编译,不出意外的话应该能顺利通过。

但是,如果你把Xcode 和 钥匙访问都关闭再重新打开,会发现之前删除的证书又回来了(可能低版本的Xcode 不会出现这问题)。因为将证书注册进钥匙串的同时也在Xcode里注册了,当重新启动Xcode时,Xcode里的证书会被拷贝进钥匙串里,所以在删除钥匙串中重复出现的证书的同时,也应将Xcode中多余的证书(profile)删掉。
打开Xcode 的Organizer,类似:
CodeSign <wbr>error: <wbr>Certificate <wbr>identity <wbr>'iPhone <wbr>Developer:xxx <wbr>appears <wbr>more <wbr>than <wbr>once <wbr>in <wbr>the <wbr>keychai
删掉重复或多余的profile,再将钥匙串中多余的证书删掉后,再次重启看看效果。