Skip to content

Identity and access

Login lockout and recovery: test abuse controls safely

Assess login throttling and recovery using isolated accounts, a small agreed request budget and evidence of the intended user experience.

By BugSnaps · Updated

Add BugSnaps as a preferred source on Google(opens in a new tab)

Want more of our security guides? Select BugSnaps and confirm your choice on Google.

Direct answer

Login abuse controls should make repeated guessing harder while allowing legitimate users to recover safely. Test configured thresholds and reset behavior using dedicated accounts and explicit limits.

Agree on the test boundary

Ask the owner for a disposable account, expected threshold, test window, monitoring contacts and recovery method. Avoid real user accounts: lockout and high-rate traffic can prevent legitimate access or trigger an incident response.

Reference: OWASP Authentication Cheat Sheet.

Observe a bounded sequence

Use the agreed number of incorrect sign-ins, recording response and time. Verify the expected delay, challenge or temporary restriction. Then try the correct password when the design allows, and document whether the account is recoverable without weakening the control.

  • Set a maximum request count and stop condition.
  • Use a known-good login before the sequence.
  • Check both browser and API entry points where authorized.

Assess the control's coverage

Ask how counters are keyed and whether multiple login routes, IP changes or distributed sources change behavior. A per-IP limit alone may not protect a targeted account, while account-only lockout can be abused to deny service. Review monitoring and exception handling with the system owner.

Verify restoration

Allow the agreed cooldown or use the supported recovery procedure; confirm a legitimate login succeeds after recovery. Record the effective behavior, false-positive impact and any remaining monitoring gaps, then remove temporary test access.

Assessment limits

A short bounded test cannot simulate a real distributed attack or prove detection across all sources. Thresholds must be considered with account recovery, user impact and incident response.

Frequently asked questions

Is permanent lockout always safer?

No. A hostile party could lock out a legitimate user. Balance resistance to guessing with safe recovery and operational monitoring.

Does a CAPTCHA replace rate limiting?

A challenge can add friction, but it should be assessed alongside throttling, account protections and monitoring rather than treated as a complete control.

Primary sources and further reading

These guides combine published security guidance with practical assessment planning. Adapt checks to the owner's policy, environment, and authorized scope.

This guide was prepared with AI assistance using the linked sources and illustrative examples. Check current vendor guidance and your environment before making changes.

Apply the guide to your own assessment.

Start with an authorized target, known test data, and a clear scope. Use the report's evidence and coverage limits to decide which checks need further review.

Open MyPentest