You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs-devsite/auth.md
+7-6
Original file line number
Diff line number
Diff line change
@@ -28,14 +28,14 @@ Firebase Authentication
28
28
|[confirmPasswordReset(auth, oobCode, newPassword)](./auth.md#confirmpasswordreset)| Completes the password reset process, given a confirmation code and new password. |
29
29
|[connectAuthEmulator(auth, url, options)](./auth.md#connectauthemulator)| Changes the [Auth](./auth.auth.md#auth_interface) instance to communicate with the Firebase Auth Emulator, instead of production Firebase Auth services. |
30
30
|[createUserWithEmailAndPassword(auth, email, password)](./auth.md#createuserwithemailandpassword)| Creates a new user account associated with the specified email address and password. |
31
-
|[fetchSignInMethodsForEmail(auth, email)](./auth.md#fetchsigninmethodsforemail)| Gets the list of possible sign in methods for the given email address. |
31
+
|[fetchSignInMethodsForEmail(auth, email)](./auth.md#fetchsigninmethodsforemail)| Gets the list of possible sign in methods for the given email address. This method returns an empty list when \[Email Enumeration Protection\](https://cloud.google.com/identity-platform/docs/admin/email-enumeration-protection) is enabled, irrespective of the number of authentication methods available for the given email. |
32
32
|[getMultiFactorResolver(auth, error)](./auth.md#getmultifactorresolver)| Provides a [MultiFactorResolver](./auth.multifactorresolver.md#multifactorresolver_interface) suitable for completion of a multi-factor flow. |
33
33
|[getRedirectResult(auth, resolver)](./auth.md#getredirectresult)| Returns a [UserCredential](./auth.usercredential.md#usercredential_interface) from the redirect-based sign-in flow. |
34
34
|[initializeRecaptchaConfig(auth)](./auth.md#initializerecaptchaconfig)| Loads the reCAPTCHA configuration into the <code>Auth</code> instance. |
35
35
|[isSignInWithEmailLink(auth, emailLink)](./auth.md#issigninwithemaillink)| Checks if an incoming link is a sign-in with email link suitable for [signInWithEmailLink()](./auth.md#signinwithemaillink)<!---->. |
36
36
|[onAuthStateChanged(auth, nextOrObserver, error, completed)](./auth.md#onauthstatechanged)| Adds an observer for changes to the user's sign-in state. |
37
37
|[onIdTokenChanged(auth, nextOrObserver, error, completed)](./auth.md#onidtokenchanged)| Adds an observer for changes to the signed-in user's ID token. |
38
-
|[sendPasswordResetEmail(auth, email, actionCodeSettings)](./auth.md#sendpasswordresetemail)| Sends a password reset email to the given email address. |
38
+
|[sendPasswordResetEmail(auth, email, actionCodeSettings)](./auth.md#sendpasswordresetemail)| Sends a password reset email to the given email address. This method does not throw an error when \[Email Enumeration Protection\](https://cloud.google.com/identity-platform/docs/admin/email-enumeration-protection) is enabled. |
39
39
|[sendSignInLinkToEmail(auth, email, actionCodeSettings)](./auth.md#sendsigninlinktoemail)| Sends a sign-in email link to the user with the specified email. |
40
40
|[setPersistence(auth, persistence)](./auth.md#setpersistence)| Changes the type of persistence on the [Auth](./auth.auth.md#auth_interface) instance for the currently saved <code>Auth</code> session and applies this type of persistence for future sign-in requests, including sign-in with redirect requests. |
41
41
|[signInAnonymously(auth)](./auth.md#signinanonymously)| Asynchronously signs in as an anonymous user. |
Gets the list of possible sign in methods for the given email address.
399
+
Gets the list of possible sign in methods for the given email address. This method returns an empty list when \[Email Enumeration Protection\](https://cloud.google.com/identity-platform/docs/admin/email-enumeration-protection) is enabled, irrespective of the number of authentication methods available for the given email.
400
400
401
401
This is useful to differentiate methods of sign-in for the same provider, eg. [EmailAuthProvider](./auth.emailauthprovider.md#emailauthprovider_class) which has 2 methods of sign-in, [SignInMethod](./auth.md#signinmethod)<!---->.EMAIL\_PASSWORD and [SignInMethod](./auth.md#signinmethod)<!---->.EMAIL\_LINK.
Sends a password reset email to the given email address.
603
+
Sends a password reset email to the given email address. This method does not throw an error when \[Email Enumeration Protection\](https://cloud.google.com/identity-platform/docs/admin/email-enumeration-protection) is enabled.
604
604
605
605
To complete the password reset, call [confirmPasswordReset()](./auth.md#confirmpasswordreset) with the code supplied in the email sent to the user, along with the new password specified by the user.
Asynchronously signs in using an email and password.
805
805
806
-
Fails with an error if the email address and password do not match.
806
+
Fails with an error if the email address and password do not match. When \[Email Enumeration Protection\](https://cloud.google.com/identity-platform/docs/admin/email-enumeration-protection) is enabled, this method fails with "auth/invalid-credential" in case of an invalid email/password.
807
807
808
808
Note: The user's password is NOT the password used to access the user's email account. The email address serves as a unique identifier for the user, and the password is used to access the user's account in your Firebase project. See also: [createUserWithEmailAndPassword()](./auth.md#createuserwithemailandpassword)<!---->.
| user |[User](./auth.user.md#user_interface)| The user. |
1614
-
| newEmail | string | The new email address. |
1614
+
| newEmail | string | The new email address.<!---->Throws "auth/operation-not-allowed" error when \[Email Enumeration Protection\](https://cloud.google.com/identity-platform/docs/admin/email-enumeration-protection) is enabled. Deprecated - Use [verifyBeforeUpdateEmail()](./auth.md#verifybeforeupdateemail) instead.|
0 commit comments