Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Third Party Sign in for IOS11 - GIDSignInButton

I am testing for IOS 11 updates and notice that my Firebase Auth using Google Sign in does not work

I get an error

A problem repeatedly occurred on https://accounts.google.com/signin/oauth? client_id nosignup pproval_state=???? passive=????

I can see many press reports about Apple removing part of the social media integration Apple to stop third party login on apps through social media in iOS 11

But I cannot find anything aimed at developers on what we should do about this.

Google sign in web page does not mention anything that I can see about IOS11 Google Sign-In for iOS

Nor does Firebase

Could anyone provide clarification on whether these libraries will still be relevant going forward in IOS11, or provide links where these issues have been discussed.

------ adding link to Firebase sample app -----------

Firebase sample app also fails for the Google login, I have not tested all others https://github.com/firebase/quickstart-ios/authentication/AuthenticationExampleSwift

like image 566
Ryan Heitner Avatar asked Jul 13 '17 12:07

Ryan Heitner


1 Answers

It is true that Apple has removed the special handling of certain 3rd party social networking sites (FB, Flickr, Twitter), but Google was never among that list. So, your error should not be related to that.

The library you are using relies on a well adopted mechanism for providing in-app out-of-context OAuth signin. Basically, the app presents a SFSafariViewController with the OAuth page, then once authorization has completed it opens a special URL which gets forwarded back to the application which then dismisses the SFSafariViewController. Google and FB I know for sure do it this way in their SDKs.

In iOS 11, Apple is providing a new mechanism to do this workflow. It is called SFAuthenticationSession. They aren't deprecating the currently supported method, and you will likely see the libraries you use migrate to this new mechanism for iOS 11 devices.

The answer to your question is that these libraries are still relevant and you should continue to investigate your error (make sure you're not getting the error on iOS 10, obviously)

Update

In response to further questioning, I fired up a sample project from the link provided. I ran into the same problem on the simulator, but when I ran it on my old iPhone 6 with iOS 11 beta 3 it worked fine. So, at the movement, this seems like a simulator bug. One theory may be simulator's reliance on the host operating system for certain libraries, so it's possible that if you were running High Sierra you might not experience this problem.

I tried fiddling with all sorts of switches in settings to get the page to load correctly to no avail. It looks like the course of action is:

  1. File a feedback

  2. Test on the device until the simulator is fixed (this is beta software after all)

Update #2

The simulator issue seems to be fixed in Xcode 9 beta 4. 🎉

like image 153
allenh Avatar answered Oct 25 '22 07:10

allenh