[英]Xcode: How to export a developer profile in order to import it on another Mac
I need to export my developer profile from my old Mac and import it on another Mac because I'm getting the following error:我需要从旧 Mac 导出我的开发人员配置文件并将其导入另一台 Mac,因为我收到以下错误:
Your account already has a valid iOS Development certificate
您的帐户已有有效的 iOS 开发证书
I found out that I can export it from here:我发现我可以从这里导出它:
But on my mac I have 2 accounts there, if I click export accounts do I export both of them?但是在我的 mac 上,我有 2 个帐户,如果我单击导出帐户,我是否同时导出它们? Because I just need one account.
因为我只需要一个账号。 Is there any other solution?
还有其他解决方案吗? Like exporting the private key used to sign the iOS Development certificate and import it on the new Mac?
像导出用于签署iOS开发证书的私钥并在新Mac上导入?
I'd recommend not using Xcode's export option, but instead to go into your Keychain Access.app, and copy the key/cert manually.我建议不要使用 Xcode 的导出选项,而是进入您的 Keychain Access.app,并手动复制密钥/证书。
To do so, in Keychain Access, create a new keychain (by default it will be stored in ~/Library/Keychains
).为此,在 Keychain Access 中,创建一个新的钥匙串(默认情况下它将存储在
~/Library/Keychains
)。 Select your login
keychain, and then My Certificates
under Category
.选择您的
login
钥匙串,然后选择“ Category
下的“ My Certificates
”。 You should now see your certificate in the right panel.您现在应该在右侧面板中看到您的证书。 It should have a disclosure arrow on the left side, and toggling that should show you your private key.
它的左侧应该有一个披露箭头,切换时应该会显示您的私钥。 Select the certificate, and copy/paste it into your new keychain (don't drag it, or it will remove it from your
login
keychain).选择证书,然后将其复制/粘贴到您的新钥匙串中(不要拖动它,否则会将其从您的
login
钥匙串中删除)。
Now you can copy that keychain to your new computer, open it in Keychain Access.app and copy the key/cert to your login
keychain there.现在您可以将该钥匙串复制到您的新计算机,在 Keychain Access.app 中打开它并将密钥/证书复制到您的
login
钥匙串中。
And the reason I don't recommend using Xcode for this, is exactly what you mention, that it exports all accounts.我不建议为此使用 Xcode 的原因正是您提到的,它导出所有帐户。 I've had clients in the past send me 'their developer key/cert' exported in this manner, that included the key/cert for dozens of other developers in their company.
我过去曾有客户向我发送以这种方式导出的“他们的开发人员密钥/证书”,其中包括他们公司中数十名其他开发人员的密钥/证书。
The way I solved it was to:我解决的方法是:
backup/delete_all_but
procedure in Xcode Keychain app for "my certificates" (not 100% sure this is necessary, but doesn't hurt)backup/delete_all_but
过程(不是 100% 确定这是必要的,但不会造成伤害)
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.