Summary
internal/api/handler/auth_handler.go (796 lines) implements 20+ auth flows in one file: register/verify, login, passkey, TOTP, recovery, sessions, wallet init, nonce. It also contains wallet-seed derivation and passkey-pepper helpers (lines 734-766) that belong in a domain service.
Acceptance Criteria
Complexity
High — broad surface, must preserve HTTP contracts.
Summary
internal/api/handler/auth_handler.go(796 lines) implements 20+ auth flows in one file: register/verify, login, passkey, TOTP, recovery, sessions, wallet init, nonce. It also contains wallet-seed derivation and passkey-pepper helpers (lines 734-766) that belong in a domain service.Acceptance Criteria
Complexity
High — broad surface, must preserve HTTP contracts.