Azure B2C Sign in with Apple generates 'invalid_grant'

Mathias Olsson 26 Reputation points
2022-03-19T21:50:08.733+00:00

We are facing a strange issue when Apple´s review team are trying to sign in into our Ionic app for iOS with Azure B2C and through Sign in with apple IDP. We get the message: "We encountered an 'invalid_grant' error connecting to the identity provider. Please try again later."
Activity Type
Federate with an identity provider

This is only happening for the Apple team. It works perfectly on our devices and XCode simulator. It has worked until now for them and the app is on AppStore and have not had any code changes that i know of that should affects this.

Can anyone please give any clue on where to start our troubleshooting?

Microsoft Entra External ID
Microsoft Entra External ID
A modern identity solution for securing access to customer, citizen and partner-facing apps and services. It is the converged platform of Azure AD External Identities B2B and B2C. Replaces Azure Active Directory External Identities.
2,892 questions
{count} votes

1 answer

Sort by: Most helpful
  1. AmanpreetSingh-MSFT 56,626 Reputation points
    2022-03-24T11:11:28.72+00:00

    @Mathias Olsson • Thank you for sharing the solution. Posting it as the answer so that it helps others in the community facing this issue.

    The issue is resolved by regenerating the application secret, as mentioned here: Add credentials


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.