How to Set Retry Limits for Liveness Checks
Design a liveness retry policy that distinguishes capture problems, service errors and suspicious attempts, with a clear fallback.
Table of contents
A bad camera angle and a suspicious result can both end a liveness attempt, but they should not send the applicant through the same next step. For the first, better instructions may help. For the second, a policy may call for review. Network failures need a separate recovery path, especially if the server already received a valid submission.
Decide what each reason counts against, which record owns the count and what happens at the limit. Give genuine users a supported way forward without making a reload or a new tab an easy way to reset the policy.
1. Classify what failed before counting an attempt
| Outcome | Policy question |
|---|---|
| Camera denied or unsupported | Can the applicant use a supported device or alternate method? |
| Quality problem before usable capture | Would concrete guidance make another attempt useful? |
| Network or service failure | Can the existing session resume, or should a new one be issued? |
| Low-confidence or inconclusive result | Is an approved retry, another check or human review appropriate? |
| Suspicious signal or policy decline | Which restricted review or escalation path should apply? |
| Session expired | Can the applicant safely start a new attempt within the wider policy? |
The OKIAS error documentation distinguishes certain capture-quality problems from verification and session errors. Amazon Rekognition describes its own liveness session and result model. Use the categories your chosen product actually returns. Check which codes your app can turn into clear user guidance and which need restricted internal handling.
Decide whether each category counts against a security budget, a technical retry budget or both. A transient service failure can have a limit to prevent a broken loop without being recorded as a failed liveness decision. A submitted attempt with a suspicious outcome can require stricter handling. Keep those differences in the state model even if your user-facing messages remain deliberately simple.
2. Enforce the limit across tabs and sessions
A limit per capture session is useful for stopping repetitive interactions in one browser window. It may be insufficient if a user can open a new session or switch devices. Define the limit against the business action you are protecting, using the authorized account or application reference where possible. Use separate scopes for rate limiting and for the applicant’s verification decision.
Enforce the policy where the decision can be trusted. The client can show remaining actions when appropriate, but a refresh should not reset the backend’s view. Record which attempt is active, which category was returned and whether the event has already been applied. Duplicate result notifications should not consume the retry budget twice. Concurrent attempts should not both advance the same application.
Define when a count resets. A cooldown, a resolved support case, a new application or a changed policy may justify a reset in some designs. Make each condition explicit and review how it interacts with repeated attempts across contexts. An authorized override should have a reason and audit trail. If support can issue unlimited sessions through a separate tool, that path needs the same policy review.
3. Use recovery evidence to set the limit
Review the NIST identity proofing guidelines in the context of your own policy and threat model. A number intended for biometric authentication is not automatically appropriate for a different remote proofing flow. Use pilot results to see when another attempt resolves a genuine capture problem and when the case needs an approved alternative or review.
Measure recovery in a pilot. Track the number of initial attempts, reasons for failure, retries offered, retries used, outcomes and cases requiring fallback. Break down the result by supported device and condition. Ask whether the second attempt succeeds because an instruction corrected a common issue or because the threshold changed. Those are very different explanations for a higher completion rate.
Set a threshold with an exit route. A candidate policy might allow a bounded retry for correctable quality failures and route repeated issues to an approved alternative. The exact counts should come from the policy and pilot. Document what would cause the team to revisit them, such as a new capture SDK, a different applicant mix or an increase in support escalations. See the liveness device and network test guide for test conditions to include.
4. Give the applicant a clear retry, fallback or review path
When a problem can be corrected, describe the action rather than showing a technical code. Tell the applicant to check their camera permission or adjust the capture conditions when the system can establish that this is appropriate. Show the instruction before restarting. Let people leave the camera step and resume or choose another supported method where the policy allows.
Use a different message for a service problem. If the result is still processing, a second capture may waste effort and create a conflicting attempt. Tell the applicant whether to wait, return later or start a fresh authorized session. Preserve the previous attempt reference so support can distinguish an outage from a failure at the capture stage.
Do not provide detailed feedback about detection logic for suspicious outcomes. Give an approved explanation of what the user can do, such as using an alternate verification route or contacting support. Review how the wording works for people with accessibility needs and for users who do not recognize the difference between a capture issue and a decision. Provide the permitted help route even when the original check cannot be completed.
Give the same error a different outcome when the evidence changes
Imagine an applicant receives a quality message on the first capture, follows the instructions and then sees a provider timeout. The first event can warrant a guided retry. The timeout might mean the second capture is still pending, so another attempt could create two competing sessions. Ask support to explain the next action for both events without opening media or guessing from the last screen.
Now repeat the exercise with a result your policy routes to review. A generic “try again” button can weaken the intended control. Record which result is authoritative, when a reviewer can reopen the case and what the applicant is allowed to see. That is more useful than setting a maximum count before anyone agrees what qualifies as an attempt.
Decide what fallback and manual review can do
An alternative needs to satisfy the applicable assurance policy. It may use a supported device, a different capture method or a review route with additional evidence, depending on the product and the reason the first path failed. Compare the fallback’s requirements and evidence to the original flow. The on-device and server-side liveness guide explains why an alternate capture architecture may have different data handling.
Give a reviewer a clear case with the attempt history, policy version and reason for escalation. Limit access to any media or identity information, and record the authorized decision. Make sure a manual review cannot silently turn a technical issue into an approval without the required evidence. Document who can reopen or override a decision and the conditions that allow it.
If no approved fallback applies, choose the appropriate outcome under the service’s policy. Avoid leaving people in a loop where they continue to open sessions that cannot change the decision. Give a clear status and the relevant support or appeal route where available. Review how a closed outcome affects related flows so the product does not request the same check without explaining what changed.
5. Test races and document who can override the limit
Test a legitimate retry after poor lighting, a failure to open the camera, an upload interrupted by a network change and a result delayed after capture. Confirm that each produces the intended counter and applicant message. Reopen the journey in a second browser and deliver duplicate or stale notifications. Make sure a completed or superseded session does not unlock a separate restricted action.
Run an authorized security exercise that reflects the threats for your supported capture paths. Keep its results separate from usability tests. For the evidence questions to ask, see presentation versus injection attacks. Test whether the fallback can be invoked repeatedly without review, whether a cooldown is respected and whether an approved override appears in the audit trail. Avoid using real identity evidence in logs or test records without a defined purpose and approval.
Track how the policy performs after launch. Useful measures include reasons for retries, successful recoveries, unavailable methods, manual queue time and cases that reached the limit. Compare similar cohorts and inspect changes after SDK updates or product releases. A spike in exhausted retries on one supported browser can indicate a technical problem, even if the total pass rate appears stable.
Also test the point at which two actions compete for the last permitted attempt. Submit the current capture while another tab requests a replacement, then confirm the backend accepts only the action the policy permits. The result should be consistent regardless of which response reaches the applicant first. Record whether support can explain the resulting state without overriding it manually.
Write the policy so every team can run it
Record the action being protected, accepted method, reason categories, counter scope, reset rules and the next step for every terminal outcome. Assign owners for support, engineering and policy changes. Have someone who did not write it use the record to handle a hypothetical case. Revise any instruction that relies on guessing what the supplier meant by a status.
When evaluating products, ask each supplier to demonstrate a recovery path and a case that must go to review. Verify that the backend can enforce the boundaries your team needs and that support can explain the approved next action. Start with the liveness provider directory and bring the same retry scenarios to each demo. A retry policy should give legitimate users a way through and give your team a predictable outcome when the check remains unresolved.