这事让我非常担心。我刚刚下载了iPhone 3.0 SDK,但现在我无法让我的配置文件工作。以下是我的尝试:

删除所有配置配置文件 删除登录keychain 创建新的“登录”钥匙链,使它 默认的 创建一个新的证书签名请求 创建新的开发人员和分销渠道 证书在苹果开发者中心 下载并安装它们 下载并安装WWDR证书 创建一个新的配置文件和 双击它来安装

所有的证书报告都是有效的,但是Xcode仍然不能识别它们。接下来我该试试什么?

编辑:

我完全重新安装了Mac OS X,从一个新的安装安装了3.0 SDK,仍然有同样的问题。


当前回答

Because I keep coming back to this question, I will leave my answer here for the solution that works for me. It turns out that for a same public/private key developer identifier of me, it's installed twice in my keychain. Both have private key. But when I compare, one is private key of me within my developer organisation, and another one is private key of me as a personal developer. It turns out Xcode keeps trying using the wrong key. Removing the wrong duplicate key solves all the problem. Hey future me, check this one first next time!

其他回答

你需要:

1)私钥和公钥。

你的钥匙链上有这个符号

2)由这些密钥的签名请求生成的证书

3)连接到该证书的配置文件

假设你换了电脑,想重新设置Xcode配置文件。你是怎么做到的?

Open Xcode, press ctrl + O to open the Organizer, and delete all provisioning profiles you might have installed already. Open keychain access, and create a signing request which you save to file (when you create the request, a private and public key is created in your keychain). Create/Update a certificate in the provisioning portal by sending apple this signing request Download and install the newly created certificate. Revoke your provisioning profiles and update them with the new certificate. Download and install the newly updated provisioning profiles.

确保这种情况干净地发生的一个好方法是首先完全清理您的登录密钥链。

另外,一个非常重要的步骤是在导入私钥和公钥之前解锁您的钥匙链

 security unlock-keychain -p password ~/Library/Keychains/login.keychain 

将私钥导入登录keychain:

security import PrivateKey.p12 -k ~/Library/Keychains/login.keychain 

导入1个身份。

将公钥导入登录keychain:

security import PublicKeyName.pem -k ~/Library/Keychains/login.keychain 

1键导入。

这里的每个人都错了。你所需要做的就是按照苹果在“管理你的数字身份”中提供的步骤操作。

它指导你通过Xcode导出你的证书,并通过Xcode重新导入。它工作得很好,但要确保你的用户名在两台电脑上是相同的,否则就会失败。

Xcode 4需要注意的是:在组织者的左边有两个不同的区域:

库>配置配置文件 设备>您的设备>配置文件

我总是把我的配置文件放在2中。即使在清洁和正确安装之后,它也不能工作。然后我发现。最后我找到了刷新按钮。如果您在1中选择“自动设备供应”。然后单击刷新,然后所有内容都得到验证(2中没有黄色警告。了)。

嘿,伙计们,我昨天遇到了一堆麻烦。我经历了整个过程几次,使用助手向权威机构请求新的证书,清除门户中的所有内容,上传证书,创建新的配置文件并下载所有内容。不行。

但是,看看这个。

首先清除门户上的所有证书,重新开始。

在使用助手创建新的证书请求后,按“在查找器中显示”,然后双击那个坏男孩。您应该会看到一个证书助手的弹出窗口,屏幕上显示“请指定颁发证书的颁发机构”等。如果你没有,只要关闭它,再次双击。 现在继续对话框选择 “从现有CA请求证书”-继续 请求已“保存到磁盘”-继续 保存在任何你喜欢的地方,甚至覆盖文件。

最后你会看到神奇的“创建密钥对”

跑到钥匙链访问,你会看到你的钥匙在那里!将这个证书上传到apple门户,然后正常地通过他们的向导,现在一切都应该工作得很好了。