# OTP Random generation

**URL:** <https://community.auth0.com/t/otp-random-generation/53096>\
**Category:** Get Help\
**Tags:** otp, mfa\
**Created:** [November 12, 2020, 2:43am UTC](https://community.auth0.com/t/otp-random-generation/53096 "2020-11-12T02:43:38Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![paul.a.stonehewer](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/paul.a.stonehewer/32/12809_2.png) [@paul.a.stonehewer](https://community.auth0.com/u/paul.a.stonehewer)\
**Post date:** [November 12, 2020, 2:43am UTC](https://community.auth0.com/t/otp-random-generation/53096/1 "2020-11-12T02:43:38Z")

</div>

During testing of an application where are customers need to use MFA via SMS we have noticed that the SMS generated by auth0 and sent to our Twilio vendor has had the same SMS OTP number for the last 3 requests. Each request was at least 55 min apart.

is this a standard Auth0 process or can i set a configuration to ensure each number generated is unique?

regards  
Paul

---

<div class="post-metadata">

**Author:** ![rashid779939](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/rashid779939/32/27027_2.png) [@rashid779939](https://community.auth0.com/u/rashid779939)\
**Post date:** [November 12, 2020, 6:10am UTC](https://community.auth0.com/t/otp-random-generation/53096/2 "2020-11-12T06:10:46Z")

</div>

Hi @paul.a.stonehewer,

The MFA or second factor authetication is managed by the system. If you got same code multiple times then it may be by system. We can not update anything related to MFA code generation.

---

<div class="post-metadata">

**Author:** ![paul.a.stonehewer](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/paul.a.stonehewer/32/12809_2.png) [@paul.a.stonehewer](https://community.auth0.com/u/paul.a.stonehewer)\
**Post date:** [November 13, 2020, 12:32am UTC](https://community.auth0.com/t/otp-random-generation/53096/3 "2020-11-13T00:32:42Z")

</div>

Hi Rashid

thanks for you comment, my question is, should the Auth0 system produce the same code three time in a row over a two hour period to the same device or mobile number? From a security perspective this is bad.

regards

paul

---

<div class="post-metadata">

**Author:** ![rashid779939](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/rashid779939/32/27027_2.png) [@rashid779939](https://community.auth0.com/u/rashid779939)\
**Post date:** [November 19, 2020, 10:36am UTC](https://community.auth0.com/t/otp-random-generation/53096/4 "2020-11-19T10:36:28Z")

</div>

Well, this is not a expected behavior. Did you try this multiple time or just face it one time.

---

<div class="post-metadata">

**Author:** ![paul.a.stonehewer](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/paul.a.stonehewer/32/12809_2.png) [@paul.a.stonehewer](https://community.auth0.com/u/paul.a.stonehewer)\
**Post date:** [November 22, 2020, 10:55pm UTC](https://community.auth0.com/t/otp-random-generation/53096/5 "2020-11-22T22:55:46Z")

</div>

Hi Rashid  
it happened multiple times. We are testing and it does happen often.

We have raised a ticket with Auth0 and waiting on the reply

regards  
Paul

---

<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:** [November 24, 2020, 1:44pm UTC](https://community.auth0.com/t/otp-random-generation/53096/6 "2020-11-24T13:44:21Z")

</div>

If you raised a ticket you should be contacted by one of our developer support engineers shortly!
