Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Add Google Sign-In Authentication

Aperta
#126 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

@gopikrishna-20 ci sta già lavorando.

Dal 17/10/2026.

  • #129 di @gopikrishna-20 — aperta

Valutazione

Difficoltà
5/5
Tempo stimato
Più di una settimana
Idoneità per principianti
15/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
javascript

Direzione di ricerca

Start from the login page and the existing email/password auth flow, then check how GOOGLE_CLIENT_ID configuration is read. The work spans GET /api/auth/config, POST /api/auth/google with token verification, an oauth_identities table with a unique provider index, account-deletion cleanup, and the Cross-Origin-Opener-Policy header. Done means a Google sign-in creates or links a user, the button stays hidden without a Client ID, and failures are handled gracefully. This is multi-subsystem design work, so it suits a maintainer more than a first-timer.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Description

Add Google Sign-In to AlphaLearn using Google Identity Services, allowing users to authenticate with their Google accounts instead of relying only on the existing email and password login flow.

Proposed Implementation

Frontend
  • Add a Continue with Google button to the login page.
  • Display the Google Sign-In option only when GOOGLE_CLIENT_ID is configured.
  • Integrate Google Identity Services to obtain the user's ID token.
  • Reuse the existing authentication and redirect flow after successful login.
Backend
  • Add GET /api/auth/config to expose the public Google Client ID.
  • Add POST /api/auth/google to verify Google credentials and authenticate users.
  • Validate the token's signature, issuer, audience, expiration, and verified email claim.
  • Link Google identities to existing accounts with the same email address.
  • Store Google identity references using a hashed provider identifier rather than storing the raw Google subject.
  • Apply rate limiting and handle authentication failures safely.
Database and Security
  • Add an oauth_identities table to associate external identities with AlphaLearn users.
  • Add an index on user_id and enforce uniqueness for provider identities.
  • Clean up OAuth identity records when an account is deleted.
  • Update the Cross-Origin-Opener-Policy header to support Google popup sign-in.
  • Keep OAuth credentials out of source control.

Expected Behavior

  1. Users can sign in using Google from the login page.
  2. New users are registered automatically and redirected to the dashboard.
  3. Existing users can sign in through their linked Google identity.
  4. Existing accounts with matching email addresses are handled without creating duplicate accounts.
  5. Google Sign-In remains hidden when no Client ID is configured.
  6. Authentication failures are handled gracefully.
Lingua principale
HTML
Stelle
3
Fork
29
Merge medio
2g 1h
PR unite (30g)
9

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di alphaonelabs/learn

Tutte le issue di alphaonelabs/learn

Issue simili

Altre issue su Security

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.