生成用于设置苹果推送通知.pem文件 [英] Generate .pem file Used to setup Apple PUSH Notification

查看:231
本文介绍了生成用于设置苹果推送通知.pem文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试了又试,生成质子交换膜文件,每次生成时间证书从客户的账户,然后生成质子交换膜使用终端的文件,但没有用它。我遵循了相同的许多环节。请帮助我,如果任何一个有关于如何产生任何想法质子交换膜或有给出质子交换膜生成。


解决方案

要启用推送通知你的iOS应用程序,你需要创建和上传苹果推送通知证书(.pem文件)给我们,以便我们能够连接到苹果推送服务器代表你。

更新版本更新的屏幕截图这里

第1步:登录到iOS Provisioning Portal中,单击左侧导航栏上的证书。然后,点击+按钮。

第二步:选择苹果推送通知服务SSL(生产)根据分配部分中的选项,然后单击继续按钮

第三步:选择您要使用您的BYO应用(如何创建一个应用程序ID),然后点击继续进入下一步的应用程序ID

第四步:按照以下步骤关于创建证书签名请求(CSR)创建证书签名请求

要补充由苹果公司提供的说明。下面是一些附加的截图来帮助您完成所需的步骤:

步骤4补充截图1:浏览到您的Mac上钥匙串访问证书助理

步骤4补充截图2:证书信息填写,点击继续。

第五步:上传这是在第4步中产生的.certSigningRequest文件,然后点击生成按钮

第六步:点击完成即可完成注册,iOS的配置门户页面将会被刷新,看起来像下面的屏幕:

然后点击下载按钮,下载证书(.cer文件)你创建刚才。 - 双击下载文件到您的Mac上安装证书到钥匙串访问

第7步:在你的Mac,进入钥匙串,寻找你刚才安装的证书。如果不确定该证书是正确的,就应该先从苹果IOS生产推送服务:后跟您的应用程序的包ID

步骤8:展开证书,你应该看到无论是您的姓名或公司名称的私有密钥。通过使用选择键盘上的键,右键点击选择这两个项目(或者,如果你使用一个按钮鼠标CMD单击),选择导出2项,如下图所示:

然后用名pushcert.p12的P12文件保存到您的桌面 - 现在会提示你输入密码来保护它,您可以点击回车键跳过密码或输入您希望有一个密码

步骤9:现在最困难的部分 - 开放Mac上的终端,并运行以下命令:

  CD
CD桌面
OpenSSL的PKCS12 -in pushcert.p12退房手续pushcert.pem -nodes -clcerts

第10步:从桌面上删除pushcert.p12以免发生误上传到建立自己的区域。打开终端你的Mac上,并运行以下命令:

  CD
CD桌面
RM pushcert.p12

现在您已成功创建了苹果推送通知证书(.pem文件)!您需要将这个文件上传到我们建立自己的区域以后。 :)

I tried and tried to generate .pem file , every time generating certificates from client's account and then generating .pem file using terminal, but its of no use. i followed many links for the same. please help me if any one have any idea about how to generate .pem or have any link that gives a step by step procedure for .pem generation.

解决方案

To enable Push Notification for your iOS app, you will need to create and upload the Apple Push Notification Certificate (.pem file) to us so we will be able to connect to Apple Push Server on your behalf.

(Updated version with updated screen shots Here)

Step 1: Login to iOS Provisioning Portal, click "Certificates" on the left navigation bar. Then, click "+" button.

Step 2: Select Apple Push Notification service SSL (Production) option under Distribution section, then click "Continue" button.

Step 3: Select the App ID you want to use for your BYO app (How to Create An App ID), then click "Continue" to go to next step.

Step 4: Follow the steps "About Creating a Certificate Signing Request (CSR)" to create a Certificate Signing Request.

To supplement the instruction provided by Apple. Here are some of the additional screenshots to assist you to complete the required steps:

Step 4 Supplementary Screenshot 1: Navigate to Certificate Assistant of Keychain Access on your Mac.

Step 4 Supplementary Screenshot 2: Fill in the Certificate Information. Click Continue.

Step 5: Upload the ".certSigningRequest" file which is generated in Step 4, then click "Generate" button.

Step 6: Click "Done" to finish the registration, the iOS Provisioning Portal Page will be refreshed that looks like the following screen:

Then Click "Download" button to download the certificate (.cer file) you've created just now. - Double click the downloaded file to install the certificate into Keychain Access on your Mac.

Step 7: On your Mac, go to "Keychain", look for the certificate you have just installed. If unsure which certificate is the correct one, it should start with "Apple Production IOS Push Services:" followed by your app's bundle ID.

Step 8: Expand the certificate, you should see the private key with either your name or your company name. Select both items by using the "Select" key on your keyboard, right click (or cmd-click if you use a single button mouse), choose "Export 2 items", like Below:

Then save the p12 file with name "pushcert.p12" to your Desktop - now you will be prompted to enter a password to protect it, you can either click Enter to skip the password or enter a password you desire.

Step 9: Now the most difficult part - open "Terminal" on your Mac, and run the following commands:

cd
cd Desktop
openssl pkcs12 -in pushcert.p12 -out pushcert.pem -nodes -clcerts

Step 10: Remove pushcert.p12 from Desktop to avoid mis-uploading it to Build Your Own area. Open "Terminal" on your Mac, and run the following commands:

cd
cd Desktop
rm pushcert.p12

Now you have successfully created an Apple Push Notification Certificate (.pem file)! You will need to upload this file to our Build Your Own area later on. :)

这篇关于生成用于设置苹果推送通知.pem文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆