Generate an apns PEM Certificate

Source: Internet
Author: User
Tags openssl rsa pkcs12 ssl certificate

The first thing to do with the push service is to get the push certificate. It is used to identify your communication with apns through SSL.


Generate an SSL Certificate for Apple push notification on Mac:

  1. Log on to the iPhone developer connection portal and click app IDs.
  2. Create an app ID that does not use wildcards. The wildcard ID cannot be used for the push notification service. For example, our iPhone program id is like this: ab123127cd.com. serverdensity. iPhone
  3. Click "Configure" next to the app ID, and then press the button to generate the push notification license. Follow the steps in the Wizard to generate a signature, upload the signature, and finally download the generated license. This step is also described in the Apple documentation.
  4. Double-click the. Cer file to introduce your aps_developer_identity.cer to the keychain.
  5. Start the keychain assistant on Mac, and then select the certificates category in login keychain. You will see an extensible option "Apple development push services"
  6. Expand this option and right-click "Apple development push services"> export "Apple development push services id123 ". Save as a apns-dev-cert.p12 file.
  7. Extend Apple development push services to do the same for private key and save it as a apns-dev-key.p12 file.
  8. You need to use terminal commands to convert these files to the PEM format:
    OpenSSL PKCS12-clcerts-nokeys-out apns-dev-cert.pem-In apns-dev-cert.p12 OpenSSL PKCS12-nocerts-out apns-dev-key.pem-In apns-dev-key.p12
  9. If you want to remove the password, do not set or execute it during export/conversion:
    OpenSSL RSA-In apns-dev-key.pem-out apns-dev-key-noenc.pem
  10. Finally, you need to synthesize keys and license files into apns-dev.pem files that are used when connecting to apns:
    Cat apns-dev-cert.pem apns-dev-key-noenc.pem> apns-dev.pem


Save this file as an easy-to-remember name that you may use later. The above steps are also suitable for generating product certificates.

Generate an apns PEM Certificate

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.