# MFA Email factor failed for second time

**URL:** <https://community.auth0.com/t/mfa-email-factor-failed-for-second-time/106722>\
**Category:** Get Help\
**Tags:** email-factor, mfa\
**Created:** [May 11, 2023, 9:48am UTC](https://community.auth0.com/t/mfa-email-factor-failed-for-second-time/106722 "2023-05-11T09:48:03Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![hoai.pham](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/hoai.pham/32/72919_2.png) [@hoai.pham](https://community.auth0.com/u/hoai.pham)\
**Post date:** [May 11, 2023, 9:48am UTC](https://community.auth0.com/t/mfa-email-factor-failed-for-second-time/106722/1 "2023-05-11T09:48:03Z")

</div>

Hi,  
I tried to use MFA Email factor successfully for the first time. (login, enroll authenticators, and confirm authenticators)  
But It was failed when I tried for the second time with error with 2 attributes of multifactor\_last\_modified,multifactor:

```auto
{
    "error": "access_denied",
    "error_description": "Payload validation error: 'Additional properties not allowed: multifactor_last_modified,multifactor (consider storing them in app_metadata or user_metadata. See \"Users Metadata\" in https://auth0.com/docs/api/v2/changes for more details)'."
}

```

The expected result should be a json with error message that mfa\_required.

I did enabled 2FA via Rule by the code:

```auto
function multifactorAuthentication(user, context, callback) {
  /*
  You can trigger MFA conditionally by checking:
  1. Client ID:
  context.clientID === 'REPLACE_WITH_YOUR_CLIENT_ID'
  2. User metadata:
  user.user_metadata.use_mfa
  */

  if (context.clientID === 'm2tMUuWeq3RoLk8CQGJmC4jnziuFoY2b') {
    context.multifactor = {
      provider: 'any',

      // optional, defaults to true. Set to false to force authentication every time.
      // See https://auth0.com/docs/multifactor-authentication/custom#change-the-frequency-of-authentication-requests for details
      allowRememberBrowser: false
    };
  }

  callback(null, user, context);
}

```

Configuration on Tenant: ( Never so that the Rule will be applied by Application)

 ![Screenshot 2023-05-11 at 17.59.18](https://global.discourse-cdn.com/auth0/original/3X/5/6/56709eeb46b098815228acd78e912d42844ac1b6.png)

Configuration on Application:

 ![Screenshot 2023-05-11 at 18.00.37](https://global.discourse-cdn.com/auth0/original/3X/a/2/a202134045d00478717fbb9669305bcd36e061b4.png)

I’ve checked the log and saw that there is an “Api update user” after successfully confirmed the challenge. And that seem this update cause error.

 ![Screenshot 2023-05-11 at 16.25.10](https://global.discourse-cdn.com/auth0/original/3X/f/5/f52c1420e80a24272282212ce68785c6aec44b90.png)  
 ![Screenshot 2023-05-11 at 16.27.12](https://global.discourse-cdn.com/auth0/original/3X/c/a/cabf6610ec852dec056d091ae4a619e87ec14eab.png)

Can you please help that I missed something? Or how can I overcome this issue?

---

<div class="post-metadata">

**Author:** ![hoai.pham](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/hoai.pham/32/72919_2.png) [@hoai.pham](https://community.auth0.com/u/hoai.pham)\
**Post date:** [May 15, 2023, 9:05am UTC](https://community.auth0.com/t/mfa-email-factor-failed-for-second-time/106722/2 "2023-05-15T09:05:45Z")

</div>

Solved in this reply [https://community.auth0.com/t/additional-properties-not-allowed-multifactor-last-modified-multifactor/106801](https://community.auth0.com/t/additional-properties-not-allowed-multifactor-last-modified-multifactor/106801)

---

<div class="post-metadata">

**Author:** ![konrad.sopala](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/konrad.sopala/32/13516_2.png) [@konrad.sopala](https://community.auth0.com/u/konrad.sopala)\
**Post date:** [May 15, 2023, 9:08am UTC](https://community.auth0.com/t/mfa-email-factor-failed-for-second-time/106722/3 "2023-05-15T09:08:28Z")

</div>

Perfect! Thanks for sharing it with the rest of community!

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [May 29, 2023, 9:08am UTC](https://community.auth0.com/t/mfa-email-factor-failed-for-second-time/106722/4 "2023-05-29T09:08:40Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
