Skip to content

Add optional per-user authenticator two-factor authentication - #431

Merged
asselstine merged 1 commit into
mainfrom
codex/factorize-totp
Nov 24, 2026
Merged

asselstine merged 1 commit into
mainfrom
codex/factorize-totp

Conversation

@asselstine

Copy link
Copy Markdown
Collaborator

What changes

  • Add Account settings → Two-factor authentication with local QR setup, an authenticator code to confirm enrollment, and ten hashed, single-use recovery codes shown once. Off by default; no team enforcement.
  • Settings changes require the current Factorize password or fresh proof of the linked Google account for Google-only users. Disabling also requires an authenticator or recovery code.
  • Gate password, Google and email-based session handoffs before issuing a full browser session. Keep pending MCP consent available after a valid second factor. Password reset does not remove 2FA.
  • Enforce short-lived browser-bound attempts, account-level throttling, and atomic authenticator/recovery-code consumption.

Validation

240 API tests against isolated PostgreSQL, 39 Playwright tests, and all 18 static checks passed locally. Google and mail were mocked. Worker runtime validation remains with CI.

Activation

Normal deployment applies migration 0105. Enrollment requires a separate Worker TOTP_ENCRYPTION_KEY (32 cryptographically random bytes encoded as base64, distinct from the credential-encryption key). Back up the key; do not replace it without preserving or re-encrypting existing secrets. Setting changes revoke earlier sessions and delegated grants. No production configuration or deployment was performed.

@asselstine
asselstine merged commit 0dd1a94 into main Nov 24, 2026
8 checks passed
@asselstine
asselstine deleted the codex/factorize-totp branch November 24, 2026 19:24
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