Will generating new APNS certificate invalidate existing active certificate - ios

We already have existing valid APNS certificate for push notifications in production which will be expiring in a month. If I generate new certificate now, will it make existing certificate invalid?
Note:- I want to do this to get rid of window between the time certificate expires and generating a new certificate, so that push notifications do not get missed.
Edit:- With current architecture, it is not easy to immediately start using new certificate

No, generating a new APNS certificate will not invalidate your existing active certificate, and it will not affect your current push notification functionality. Push notification certificates are not part of your build, so you only need to change certificates on your server.
You can also check this answer and discussion to better understand how this works:
Renew Push certificate and keep current App Store App working

Related

What is the use of multiple APNS certifcate for one App ID |

I am new to iOS and developing push notification application.
I am very much curious to know what is the significance of multiple APNS certificates associated with one App Id.
As per my understanding one possible use case - If my application is receiving push notification from multiple vendors than at some point of time we want to stop allowing push notification from a specific vendor and we are using single APNS certificate than on revoking the certificate app will stop receiving push from all the vendors.
If we are using different APNS certificate for all different vendors than we can revoke a specific vendor certificate and as a result app will only stop receiving push from the specific vendor.
Please correct me if I am on a wrong direction.
It will be great help if someone can explain the use of having multiple APNS certificate associated with one App Id.
Thanks in advance!!
This has only this use case If an application is receiving push notification from multiple vendors than at some point of time we want to stop allowing push notification from a specific vendor and we are using single APNS certificate than on revoking the certificate app will stop receiving push from all the vendors. If we are using different APNS certificate for all different vendors than we can revoke a specific vendor certificate and as a result app will only stop receiving push from the specific vendor. Please correct me if I am on a wrong direction.

iphone apns cert(.p12) file expired

my app use apns to send notifications, after one year, the cert file had expired,
but my CSR(.certSigningRequest) cannot been found, here is the question.
If i create a new CSR file, and new ios aps_distribution, do i need submit a new
app to AppStore?
No you don't.
You certificate is only used to access Apple's APNS from your server (or your PUSH service provider's). Your app will not expire.
Edit:
i use javapns-2.2 to send notification to my app, when use
aps_development cert, i can receive the message, but when i use the
new created aps_distribution, it shows send success, but my app cannot
receive msg, do you know why? or do you know how to test production
push?
As Aanabidden stated, don't forget that you can't use a production certificate for development and a development certificate for production. Apple's servers are separated for those schemes and an invalid certificates won't work.

Azure Notification Hub registrations disappear when sending a notification

Recently our Azure Notification Hub became a very mysterious entity. When Apple devices register we can see them in Service Bus Explorer and as soon as we try sending any notifications (from SBE or Azure Portal) we get a "Notification Successful" message, but nothing appears on the device. Refreshing registration list uncovers the fact that the registrations were deleted.
We are not removing them anywhere in code, and the TTL has not expired.
Any suggestions?
Notification hub cleans up registrations with invalid tokens during the send flow. Looks like for some reasons APNS rejects your tokens and NH just removes registrations. Make sure:
you are getting token from physical device (not emulator);
APNS certificate uploaded to NH is not expired;
APNS certificate uploaded to NH corresponds APNS endpoint you are
using in application (sandbox or production).
Turns out the front end guys were unsubscribing too eagerly. Removing the unsubscribe code sorted out the issue. Also there was a problem with the APNS certificate, in order to run the front end app in debug it requires a sandbox certificate, not a production one, for the messages to be delivered properly.
We had this exact error, but it turned out we were accidently using a "distribution" provisioning profile with a "development"/ sandbox push notification certificate. After switching to a development provisioning profile, push notifications worked!

Still receiving push notifications after revoking APNs cert

My APNs cert is expiring soon so I revoked the APNs cert (just to make sure everything is working fine). But after 30 min I am still receiving testing push notifications. Is it because of Apple's cache? How long will it last?
Your old certificate is not expired yet from your question. So If your server uses the same cert, your existing iOS application will receive push notification. You should replace the old cert with new one.
Usually, it will take 24 Hrs to reflect APNS Certificate revoke! - After that you will get SSLException with "certificate_revoked" .

Push Notification queries

I hope someone can help me with the following.
My app is in app store and its not receiving any push notification and my Production Push SSL Certificate got expire yesteday only.
Do i need to generate the new Production Push SSL Certificate and put on server.
Please help me on these.
Yes, you have to fetch a renewed push certificate for your application from the Apple Developer Center. After that you have to put it on your server (adjust the password,...) and then your server should be able to send messages again.

Resources