Skip to content

fix: serialize password confirmation prompts and prioritize strict retries#1466

Draft
joshtrichards wants to merge 1 commit into
nextcloud-libraries:mainfrom
joshtrichards:jtr/fix-password-handling-robustness
Draft

fix: serialize password confirmation prompts and prioritize strict retries#1466
joshtrichards wants to merge 1 commit into
nextcloud-libraries:mainfrom
joshtrichards:jtr/fix-password-handling-robustness

Conversation

@joshtrichards

@joshtrichards joshtrichards commented Jul 13, 2026

Copy link
Copy Markdown

Summary

Rework password-confirmation prompt handling to support concurrent requests and multiple Axios instances:

  • Serialize confirmation requests so each successful validation uses its own dialog session.
  • Keep Strict-mode validation pending until the authenticated request response is known.
  • Preserve the open dialog for wrong-password responses and prioritize the matching Strict retry.
  • Settle the active Strict confirmation and reject queued requests on terminal validation errors, allowing the dialog to close as unsuccessful.
  • Track interceptor initialization per Axios instance.
  • Avoid logging request configuration objects that may contain the entered password.
  • Store Strict-mode tracking metadata under namespaced string config keys so it is preserved across Axios configuration merges and retries.

Testing

  • Lax password confirmation succeeds.
  • Strict password confirmation succeeds.
  • Strict wrong password keeps the dialog open and allows retry.
  • Strict terminal request error closes the dialog as unsuccessful.
  • Concurrent confirmation requests are handled sequentially.
  • Cancelling the dialog rejects the active and queued requests.

🤖 AI (if applicable)

  • The content of this PR was partly or fully generated using AI

TODO

  • Test test test
  • Review debug logging for additional usefulness in the field
  • Fix commits/signing to add AI assistance acknowledgement

Assisted-by: Copilot:gpt-5.6-terra

Signed-off-by: Josh <josh.t.richards@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant