Firebase Authentication


#1

Does anyone know if Firebase Authentication qualifies for Realm custom authentication? If yes, would there be a pointer on how this can be implemented.

There are some Firebase components that I want to use and it will be awkward to ask the user for two authentication in one app.

Thanks


#2

@valokafor Sure that could use our custom authentication - see the guide here:
https://realm.io/docs/realm-object-server/#custom-authentication

There is a cognito example here on the server side that would be analogous to the firebase code you would right, let me know how it goes:


#3

How is the login flow then? Client login to Firebase, receive token, login to ROS via that token a then is logged in? Or there is no need to use Firebase on client then?

Reasons I want to use Firebase auth is a possibility to change user sign up email and a password reset via email.


#4

@naimashhab Correct - ROS would validate the token against Firebase and check to make sure it is valid - then grant access.


#5

@naimashhab @ianward If either of you feel motivated to publish your solution using Firebase Auth with the custom JWT login for Realm, please do.


#6

@ogtimothymiller I do not have an already built one but you would use the Firebase SDK shown here:
https://firebase.google.com/docs/auth/admin/verify-id-tokens

And call it from our Custom Auth callback:
https://docs.realm.io/platform/using-synced-realms/user-authentication/additional-providers#custom-authentication