ios 将证书添加到钥匙串并生成 .p12 文件格式

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/14315205/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-30 21:50:47  来源:igfitidea点击:

Adding certificates to keychain and generating .p12 file format

iosobjective-capple-push-notificationsapns-sharp

提问by Lasang

I am following the step given in https://github.com/Redth/PushSharp/wiki/How-to-Configure-&-Send-Apple-Push-Notifications-using-PushSharpto while working step by step for Apple Push Notifications.

我正在按照https://github.com/Redth/PushSharp/wiki/How-to-Configure-&-Send-Apple-Push-Notifications-using-PushSharp 中给出的步骤逐步处理 Apple 推送通知.

I got stuck in the middle. I added Apple Push Notification development Certificates. But the certificates appears under SYSTEM/Certificates instead of LOGIN/Certificates section. May be due to this or may be not, I did't get save as .p12 file format option when i try to save file as p12 format as explained in step 19. I also tried generating certificates without checking LET MY SPECIFY KEY PAIR CHAIN INFORMATION as explained in step 10.

我被卡在了中间。我添加了 Apple 推送通知开发证书。但是证书出现在 SYSTEM/Certificates 而不是 LOGIN/Certificates 部分。可能是因为这个,也可能不是,当我尝试将文件另存为 p12 格式时,我没有得到另存为 .p12 文件格式选项,如步骤 19 中所述。我还尝试生成证书而不检查 LET MY SPECIFY KEY PAIR CHAIN信息如步骤 10 中所述。

Can anybody suggest me how to make aps-development.cer under login/certificates in key chain and then proceed the given step to obtain .p12 file?

有人可以建议我如何在钥匙串中的登录名/证书下制作 aps-development.cer,然后继续执行给定的步骤以获取 .p12 文件吗?

Thanks in advance for your help and support.

在此先感谢您的帮助和支持。

回答by Girish

Please try following Three steps

请尝试以下三个步骤

Step 1:Open your Keychain Access app.

第 1 步:打开您的 Keychain Access 应用程序。

Step 2:You will see list in left side as 'Login' ,'System' and 'System Roots', just drag your certificate in 'Login' option.

第 2 步:您将在左侧看到“登录”、“系统”和“系统根目录”列表,只需将您的证书拖到“登录”选项中即可。

Step 3: You will get certificate install successfully in Keychain Access.

第 3 步:您将在 Keychain Access 中成功安装证书。

After this process you can create the .p12 certificate.

在此过程之后,您可以创建 .p12 证书。

回答by marika.daboja

Step by step instruction how to download certificate and generate .p12

分步说明如何下载证书并生成 .p12

You need a valid certificate to be able to generate .p12 file. Step 1-3 describe steps to download valid certificate from the Apple Developer Account. Step 4-8 describe how to use this certificate to generate .p12 file.

您需要有效的证书才能生成 .p12 文件。步骤 1-3 描述了从 Apple Developer Account 下载有效证书的步骤。步骤 4-8 描述了如何使用此证书生成 .p12 文件。

  1. Logon to DEVELOPER.APPLE.COM
  2. (From the left menu) Go to 'Certificates, ID's & Profiles' or (From the main panel) Click on 'Certificates, Identifiers & Profiles'
  3. (From the left menu) Click on Certificate type ie Production -> Click on the Certificate name to expand more options -> Click on 'Donwload'
  4. (From the mac menu) Go to Utilities -> Key Chain
  5. (From the top menu of Key Chain) Go to Key Chain Access
  6. Open location where certificate has been downloaded and double click on it (This should auto generate new record in the Key Chan Access certificate list)
  7. (From the Key Chain Access certificate list) right click on the newly created certificate record and choose 'Export...'
  8. Save file as .p12
  1. 登录 DEVELOPER.APPLE.COM
  2. (从左侧菜单)转到“证书、ID 和配置文件”或(从主面板)单击“证书、标识符和配置文件”
  3. (从左侧菜单中)单击证书类型即生产 -> 单击证书名称以展开更多选项 -> 单击“下载”
  4. (从 mac 菜单)转到实用程序 -> 钥匙链
  5. (从 Key Chain 的顶部菜单)转到 Key Chain Access
  6. 打开已下载证书的位置并双击它(这应该会在 Key Chan Access 证书列表中自动生成新记录)
  7. (从密钥链访问证书列表中)右键单击新创建的证书记录并选择“导出...”
  8. 将文件另存为 .p12