Xcode一直要求密码才能使用System Keychain

时间:2012-04-09 03:25:12

标签: objective-c ios xcode

我在Lion 10.7.3下运行Xcode 4.3.2,但每次我在设备上安装我的iPhone应用程序时,它都会一直询问我管理员用户名和密码。

我已经完成了这里建议的所有事情,甚至重新安装了Xcode:

Another StackOverflow related question

但到目前为止没有成功。

以下是一直出现的窗口图片:

Xcode 4.3.2 keeps asking for an Admin user name and password

有关如何解决此问题的其他建议吗?

7 个答案:

答案 0 :(得分:155)

问题是我的钥匙串开发人员证书位于左侧面板上的“系统”下,该面板始终处于锁定状态,需要我的密码才能解锁!

然后我将开发者证书移动到“登录”,它总是被解锁,现在一切正常。 xCode要求密码的烦恼消失了。

请参阅此图片了解更多详情:enter image description here

答案 1 :(得分:40)

  1. 转到“钥匙串访问
  2. 双击证书使用下的私钥以对您的应用程序进行代码签名
  3. 将“Xcode”添加到“访问控制”部分列表下的“始终允许这些应用”。

答案 2 :(得分:20)

以下是我在Xcode 7.2上修复它的方法(也适用于7.3):

1) Open KeyChain.
2) Select System, Choose Certificates category.  
3) Select developer certificate  and double click the private key.
4) Check Access Control and tick on 'Allow all item to access this'.
5) Restart Xcode and run the app on device.

答案 3 :(得分:9)

我这样做是为了解决上述问题:

  1. 转到钥匙串访问

  2. 选择系统>> 您的证书>> 右键点击“获取信息”

    < / LI>
  3. 证书信息窗口将打开&gt;&gt; 选择“信任”部分

  4. 从下拉选项中选择“始终信任”

  5. enter image description here

答案 4 :(得分:1)

希望这些步骤可以解决您的问题。

- Open Keychain Access.
- In the top-left corner, unlock the keychain (if it is locked).
- Choose the System keychain from the top-left corner.
- Find your distribution certificate and click the disclosure triangle.
- Double-click ‘Private key’ under your distribution certificate.
- In the popup, go to the Access Control tab.
- Select ‘Allow all applications to access this item’.
- Save the changes.
- Close all windows.
- Run the application.

答案 5 :(得分:1)

command+c 系统钥匙串中的分发证书

会话登录钥匙串中的command+v

答案 6 :(得分:0)

在我的情况下,带有私钥的所需证书保存在系统钥匙串,证书类别中。要解决此问题,我已导出证书(包括私钥),并将其移至登录钥匙串,证书类别。