Mari12
Mari12

Reputation: 1

Flutter Firebase Forgot password

I'm working on a project where I'm using the authentification of firebase to use the forgot password thing. However, I have a collection users that I use as well and need the password field to be updated in the collection as well. Any solutions please ? I can't seem to find a way to get password from authentification.

Upvotes: 0

Views: 1285

Answers (1)

Frank van Puffelen
Frank van Puffelen

Reputation: 598728

There is (very intentionally) no way to get a user's password from Firebase, and wanting to do so typically indicates an anti-pattern in your implementation.

If you already verify the user's credentials elsewhere, you shouldn't use Firebase to do the same (but for example mint a custom token based on the external credentials). If you use Firebase to verify the user's password, you shouldn't repeat that in your code (although you can for example decode the user's ID token to determine their identity).

Upvotes: 1

Related Questions