Login fails for user after verifying email address

I have a problem with logging in once I’ve verified a users’ email address.

I’m using an Auth0 database on the Free plan, so all very basic. When I run my app and register a new user, I can login/out in my app perfectly well, until I validate the email address. As soon as I do that, on all subsequent logins for that user, I receive an error.

I’ve gone into the Auth0 dashboard and to the database in question, and if I test the DB access using a user with a verified email address, I get the following error…

{
  "error": "access_denied",
  "error_description": "{\"statusCode\":401,\"error\":\"Unauthorized\",\"message\":\"Invalid token\"}"
}

If I test the database with a user who has not validated their email address, it all works fine and I can login successfully. It took a while to track this down, but I’ve now repeated this with two other new users and both get the same.

Can someone please give me some assistance! This is affecting my ability to use Auth0.

Thanks in advance, Morgan

Hi @morganski,

Welcome to the Auth0 Community!

Thank you for posting your question. I’ve checked your tenant, and it looks like this error is raised by the Rule responsible for linking accounts with the same email address. If you disable this Rule, your verified users will be able to log in. I would encourage you to move to the Action from Rules, as Rules are deprecated and in Read-only mode.

https://auth0.com/docs/manage-users/user-accounts/user-account-linking/link-user-accounts

Thanks
dawid

Dawid,

Thanks for your assistance here - I can confirm that removing the rule you mentioned has addressed the error and it’s now working. I’ve had my Auth0 account for some years and I think this rule is from back in the day.

Regards, Morgan