Commit graph

2 commits

Author SHA1 Message Date
Satanas1275
487a6e1481 fix: remove OAuth tokens from localStorage, add HttpOnly cookie auth
- Stop storing discord_token and google_token in localStorage (XSS risk)
  These tokens are never read, only written; backend already stores them
  server-side in user data files.
- Remove discord_token and google_token from AUTH_KEYS array
- Add cookie-parser middleware to Express app
- Add setAuthCookie() helper to set JWT as HttpOnly; Secure; SameSite=Lax cookie
- Update auth routes (BIP39 register/login, Discord, Google) to set cookie
- Update getAuthIfValid() to read JWT from cookie first, then Authorization header
- Add extractJwtFromRequest() helper for dual-mode auth (cookie + header)
- Add GET /api/auth/session endpoint to rehydrate JWT from cookie on page reload
2026-07-02 00:13:41 +02:00
Movix
1401dc20f3 tird release
mon compte github a été détecté comme du spam je crois
2026-04-28 17:55:00 +02:00