AspNet.Security.OAuth.Providers: Apple Signin redirects to a blank page 404 Error

Describe the bug I’ve added the .AddApple nuget package and extension method but when I complete the apple sign in flow, at the last step when it asks to “Continue”, it then redirects to a blank screen. When I look at the network tab, I see that it tried to make a POST request to https://mydomain.com/identity/signin-Apple, since I set the CallbackPath to /identity/signin-Apple but this gives a 404 error.

image

Steps To reproduce Validate the domain in the apple developer portal and add the redirect urls. Add apple authentication using .AddApple with the required settings in your solution. Try login with apple

Expected behaviour Login with apple redirects back to calling application and produces a token

Actual behaviour Login with apple redirects but then gives a 404 error so the browser is stuck on a blank page

About this issue

  • Original URL
  • State: closed
  • Created 4 years ago
  • Comments: 31 (15 by maintainers)

Most upvoted comments

It’s correct that the user information endpoint hasn’t been implemented by Apple. However they do return you the name and email, but only on the first ever request for that user through Sign in with Apple (which is annoying).

If you’re happy it’s working, log into your Apple ID you’re using to test and delete the association with your app (I forget exactly where you do this). Then log in to your test app again with the same Apple ID and you’ll get the name and email address again then.

The way Apple have implemented it, you only have one chance to get the name or email address and if you miss it then it’s gone forever unless the user deletes the association with your app.

As this is all working now, I’m going to close this issue. Glad I could help you get it working!

I see that makes a big difference then because I’m running this as a linux container. I’ll try and convert the .p8 file into a .pfx and test to see what happens. Ideally, I’d move to 3.1 but don’t have bandwidth to make the switch right now.

Thanks for the article link, will read through it now.