Skip to content

Instantly share code, notes, and snippets.

@matteocrippa
Created April 18, 2013 13:13
Show Gist options
  • Save matteocrippa/5412581 to your computer and use it in GitHub Desktop.
Save matteocrippa/5412581 to your computer and use it in GitHub Desktop.
iOS Push Notification Certificates - How to create
1- Open your OSX keychain
2- Click on Keychain Access > Certificate Assistant > Request a Certificate from a Certificate Authority
3- Set a readable common name (eg. NameApp DEV o NameApp PROD according the certificate your are creating)
4- Select Save to disk
5- Proceed uploading to Apple portal and download the .CER file
6- Use Keychain search and search for NameApp, select the private certificate and export it to your disk (use a readable name eg. key_dev.p12 or key_prod.p12)
7- Open your Terminal
8- Move to the dir you placed P12 and CER files
9- openssl x509 -in aps_development.cer -inform DER -outform PEM -out app_dev.pem
10- openssl pkcs12 -in key_dev.p12 -out key_dev.pem -nodes
11- Move key_dev.pem & app_dev.pem to your apns system
The example above covers the dev certificate creation, for production one you can follow the steps above changing _dev with _prod
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment