I had a working application with the Facebook and email function, since I am updating the Firebase console (only, sdk did not update).
The release of the application before Firebase 3.0 worked earlier, but it can no longer subscribe / register with Facebook after the console has been updated.
What I've done:
1 - Upgraded Firebase Console
Due to the Firebase and Facebook console updates, I also had to put Oauth Callback in the Facebook app
2 - Paste the Firebase Facebook OAuth callback into the Facebook console (before it was invalid) `` https://xxx.firebaseapp.com/__/auth/handler ``
An exception:
Firebase Auth listener fires Firebase Error:
Invalid authentication credentials. and Facebook: {"providerErrorInfo": {"code": 400, "message": "Unsuccessful debug_token response from Facebook: {\" error \ ": {\" message \ ": \" (# 100) You must provide a token access to applications or access token of the user who owns or develops the application \ "\" Type \ ": \" OAuthException \ ", \" \ "code: 100, \" fbtrace_id \ ": \" DG4lLRJHFBS \ "}}" }}
FirebaseError Code:
In the decompiled FirebaseAndroidSdk code, the error object:
0 = { java.util.LinkedHashMap$LinkedEntry@22680 } "code" β "INVALID_CREDENTIALS"
1 = { java.util.LinkedHashMap$LinkedEntry@22681 } "message" β "Invalid authentication credentials provided."
2 = { java.util.LinkedHashMap$LinkedEntry@22682 } "details" β "{" providerErrorInfo ": {" code ": 400," message ":" Unsuccessful debug_token reply from Facebook: {\ "error \": {\ "message \": \ "(# 100) You must provide the application access token or the access token of the user who owns or the application developer \", \ "type \": \ "OAuthException \", \ "code \": 100, \ "fbtrace_id \ ": \" BtB3JF2qmku \ "}}"}} "
with decompiled code:
private void makeAuthenticationRequest(String urlPath, Map<String, String> params, AuthResultHandler handler) { final AuthenticationManager.AuthAttempt attempt = this.newAuthAttempt(handler); this.makeRequest(urlPath, HttpRequestType.GET, params, Collections.emptyMap(), new RequestHandler() { public void onResult(Map<String, Object> result) { Object errorResponse = result.get("error"); String token = (String)Utilities.getOrNull(result, "token", String.class); if(errorResponse == null && token != null) { if(!AuthenticationManager.this.attemptHasBeenPreempted(attempt)) { AuthenticationManager.this.authWithCredential(token, result, attempt); } } else { FirebaseError error = AuthenticationManager.this.decodeErrorResponse(errorResponse); AuthenticationManager.this.fireAuthErrorIfNotPreempted(error, attempt); } } public void onError(IOException e) { FirebaseError error = new FirebaseError(-24, "There was an exception while connecting to the authentication server: " + e.getLocalizedMessage()); AuthenticationManager.this.fireAuthErrorIfNotPreempted(error, attempt); } }); }
At AuthListener level, firebaseError code: -20
https://www.firebase.com/docs/java-api/javadoc/com/firebase/client/FirebaseError.html
The credentials provided are invalid.
Facebook error code:
code 400
Nothing relevant was found here: https://developers.facebook.com/docs/graph-api/using-graph-api/#errors
Code for Authing:
public void authWithFirebase(final String provider, Map<String, String> options) { if (options.containsKey(AUTH_OPTIONS_ERROR)) { EventBus.getDefault().post(new MessageToDisplayEvent(options.get(AUTH_OPTIONS_ERROR), true)); } else { if (provider.equalsIgnoreCase(AUTH_PROVIDER_TWITTER)) {
TOKEN. Validity:
From the above code, the token is valid, as:
https://graph.facebook.com/app?access_token=%7Byour_access_token%7D return a valid JSON
And the Facebook AccessToken tool https://developers.facebook.com/tools/debug/accesstoken returns the still valid TOKEN
What has changed from the point of view of the user:
Now, when I click on FacebookLoginButton, I have a new dialog box asking "connect as% FacebookUserName" with two buttons ("Unconnect" and "Cancel")
I published a bug report in Firebase, but I donβt even know if it is Facebook or Firebase, any help, advice for exploring a new surface or solving a problem is welcome.