My organisation maintains multiple applications and there's a confusion about how the APNs keys are supposed to be used. We are using firebase to send push notifications.
So far we have two apple keys for two different applications. But cannot create a third key with APNs activated.
This question indicates that we're supposed to use the same key for all applications.
My questions are:
If we only can create two keys for one organisation is one supposed to be used for production and one for testing/development?
If we use the same keys for multiple unrelated application (unrelated except that the apps are all created by the same organisation) what stops cloud messages from being pushed to the wrong application. Is it related to identifiers for apps? Are we supposed to create a convention to circumvent the problem of sending messages to the wrong app? ( I don't actually think this is a very valid option. It feels very wrong.)
For example:
I've asked this question here as well: https://forums.developer.apple.com/message/415911#415911
Actually you can create only 2 apple push certificates for one App ID and no more.
[1] To begin, visit the Apple Developer Member Center and log in with your credentials. [2] Click Certificates, Identifiers & Profiles. [3] Click Keys then the “+” button in the top right corner to create a new key. [4] Enter a descriptive name for your APNS Auth Key, then select Apple Push Notification Service (APNs).
No. APNs Auth Key will never expire as Apple suggests. It is now a more preferred way to handle Push Notifications than using APNs Certificate.
An Access Point Name (APN) a allows device's network to connect to the internet. With the APN settings in place, your device builds a connection to a carrier's gateway. Part of this process involves the carrier using a defined APN network to choose the assigned IP address(s) and security settings where applicable.
The key is used to authenticate to the service. It identifies your organisation to the service.
The reason you can have two keys is so that you can create a new one before revoking the old one if the key is compromised.
When an app registers for remote notifications you receive an identifier that is unique for that app on that device. If you have multiple apps on that device each will get a different identifier.
When you send a push notification the identifier ensures that it gets to the right app on the right device.
You need to ensure that you store the identifier against the right app on your backend (or you may have different backends for different apps).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With