Files
Epicure/package.json
T
Arnaud acc93de708 feat: two-factor authentication (TOTP + backup codes)
Uses better-auth's built-in twoFactor plugin rather than hand-rolling
TOTP — adds the two_factors table and users.twoFactorEnabled, wires
the server/client plugins (allowPasswordless: true so OAuth-only
accounts aren't locked out of managing 2FA), and adds a custom rate
limit for the verify endpoints (5/min — far stricter than the default
100/10s, since a 6-digit code has a much smaller keyspace than a
password).

New Settings → Security section walks through enable (password
confirm -> QR + backup codes -> confirm a live code before it's
actually turned on, per the plugin's default flow) and disable. New
/verify-2fa page handles the post-password mid-login step, with a
backup-code fallback. Verified live end-to-end: enable, confirm,
forced re-auth on next sign-in, TOTP accepted, backup code accepted
(single-use), disable.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-07-13 23:08:15 +02:00

24 lines
632 B
JSON

{
"name": "epicure",
"version": "0.23.0",
"private": true,
"scripts": {
"dev": "pnpm --filter web dev",
"build": "pnpm --filter web build",
"lint": "pnpm -r lint",
"typecheck": "pnpm -r typecheck",
"db:generate": "pnpm --filter @epicure/db generate",
"db:migrate": "pnpm --filter @epicure/db migrate",
"db:seed": "pnpm --filter @epicure/db seed",
"db:backfill-usernames": "pnpm --filter @epicure/db backfill-usernames",
"db:studio": "pnpm --filter @epicure/db studio"
},
"devDependencies": {
"typescript": "^5.8.3"
},
"engines": {
"node": ">=22",
"pnpm": ">=11"
}
}