freeCodeCamp / classroom

BSD 3-Clause "New" or "Revised" License
144 stars 120 forks source link

Config Next-Auth to allow account linking between different auth providers #219

Closed GuillermoFloresV closed 1 year ago

GuillermoFloresV commented 1 year ago

Describe the bug Currently, if you have an account signed in using Google OAuth and you try to sign in using that same email, but through a different OAuth provider (Github), you are not allowed to sign in despite it being the same email. For ease of use, we want to enable account linking (so long as they are the same email under different Auth providers) for development experience only.

Steps to reproduce:

  1. Must build locally (do not use the Gitpod setup)
  2. Please use this guide to set up the dev environment locally.
  3. Sign in and make an account using the Google provider option
  4. Sign out
  5. Sign in to the Classroom App again using a different provider option, but make sure it still falls under the auth0 options (for example, Github). The Github account must be associated with the same Gmail address as when you signed in on step 3. (For example, your Gmail used in step 3 is coolcoder123@gmail.com, and your GitHub account also needs to have the email address:coolcoder123@gmail.com

Current Behavior:

Desired Behavior:

This document also explains how to reproduce

rahulio96 commented 1 year ago

CTI Team U is working on this.