Ticket: AUTH-T105 · Epic: E3 Authentication Core · Phase: Phase 4 — Aplio, SenatePath, retention
Priority: Medium · Estimate: 5 points · Labels: epic:auth-core, phase:4, backend, frontend, security, better-auth
Depends on:
Suggested by Benedikt and accepted: add the Better Auth passkey plugin (WebAuthn) as an optional, per-user sign-in method. Passkeys cost no email, resist phishing, and suit students who prefer not to manage passwords.
- Enrollment from
/account/security after fresh re-auth (AUTH-T32); users may register several passkeys and name/remove them. Relying-party ID is auth.northeasternsga.com (dev: auth-dev.northeasternsga.com), so passkeys are only usable on SGAuth's own login page; products never see WebAuthn.
- Sign-in: the login page offers 'Sign in with a passkey' alongside email + password, including conditional UI (browser autofill) where supported. A successful passkey sign-in creates the same parent-domain session as a password sign-in.
- Password stays as the account's fallback and for recovery; passkeys do not replace the password in v1.
- MFA: a passkey does not satisfy the admin TOTP requirement in v1 (admins still enroll TOTP); revisit later.
- Lockout counters (AUTH-T64) are unaffected by passkey attempts; failed WebAuthn ceremonies are rate-limited (AUTH-T63).
- Schema: plugin's
Passkey table via Prisma; audit PASSKEY_ADDED / PASSKEY_REMOVED / LOGIN_SUCCESS with method=passkey.
- Tombstoning (AUTH-T78) and admin deactivation remove passkeys.
Acceptance criteria
Generated from the SGAuth design (docs/sgauth-design in SGAOperations/auth). SGAuth is built on Neon and does not use Supabase.
Ticket: AUTH-T105 · Epic: E3 Authentication Core · Phase: Phase 4 — Aplio, SenatePath, retention
Priority: Medium · Estimate: 5 points · Labels: epic:auth-core, phase:4, backend, frontend, security, better-auth
Depends on:
Suggested by Benedikt and accepted: add the Better Auth
passkeyplugin (WebAuthn) as an optional, per-user sign-in method. Passkeys cost no email, resist phishing, and suit students who prefer not to manage passwords./account/securityafter fresh re-auth (AUTH-T32); users may register several passkeys and name/remove them. Relying-party ID isauth.northeasternsga.com(dev:auth-dev.northeasternsga.com), so passkeys are only usable on SGAuth's own login page; products never see WebAuthn.Passkeytable via Prisma; audit PASSKEY_ADDED / PASSKEY_REMOVED / LOGIN_SUCCESS with method=passkey.Acceptance criteria
Generated from the SGAuth design (docs/sgauth-design in SGAOperations/auth). SGAuth is built on Neon and does not use Supabase.