QuizzifyTech

Bug library › Backend testing

Backend testing · Auth log

The same OTP is accepted twice, the second time from a new device

P1 · CriticalIntermediateAuth log

Want to find it yourself first? This page gives away the answer. Play this bug on a fake app screen and see if you can spot it in three tries.

Spot this bug

The clue

A one-time password should work how many times?

Steps to reproduce

  1. Request an OTP and sign in with it
  2. Use the same code again from another device

Expected result

The second use is rejected: “Code already used”

Actual result

Code 482913 is accepted again at 10:03 on a new device

Why it matters

This is a critical (P1) bug. It can lose money, expose private data or stop people from finishing a key task. A bug like this should block a release and be fixed straight away.

Testing tip

For OTPs and reset links, test reuse, expiry and too many attempts. “One-time” must really mean once.

How to find bugs like this

Backend bugs hide behind a screen that looks fine: jobs that run twice, retries that never stop, stale caches, reports that say success when nothing happened. When you test, try these checks:

  • Check that each action happens exactly once.
  • Look at logs, outboxes and job history, not just the screen.
  • Test what happens on a slow network, a retry and a double click.
  • Compare cached values with the source of truth.

More Backend testing bugs

See all 158 bugs