且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

如何将现有的私钥用于新的iOS开发证书?

更新时间:2023-09-21 13:55:34

来自keychain的私钥作为p12文件。

First, I had to export my private key from the keychain as a p12 file. I tried scripting this, but was unsuccessful.


  1. 打开钥匙串并选择您的私钥

  2. 右键 - 点击并选择导出

  3. 使用p12文件类型。

openssl命令将您的密码保护的p12文件转换为pem。 openssl将提示输入密码。

Run the following openssl command to convert your password-protected p12 file to a pem. openssl will prompt for a password.

openssl pkcs12 -in your-newly-exported-p12-file.p12 -out your-newly-exported-p12-file-as-a-pem.pem -nodes

运行以下命令在您的pem文件上生成csr。

Run the following command on your pem file to generate the csr.

openssl req -new -key your-newly-exported-p12-file-as-a-pem.pem -out your-csr-to-submit-to-apple.csr