Invalid Github Auth scope
See original GitHub issueThe github auth url is https://github.com/login?client_id=2b2a9dcc53df88ddf452&return_to=/login/oauth/authorize?client_id=2b2a9dcc53df88ddf452&redirect_uri=http://www.freecodecamp.com/auth/github/callback&response_type=code&
scope=email
Here, scope=email
parameter is not a valid scope according to https://developer.github.com/v3/oauth/#scopes
If it is meant to retrieve only the public data of a user, scope
is not required to be given.
Or if it is meant to retrieve both public data and private email id, then scope
should be set to user:email
.
Currently, using an invalid scope
, only public data is retrieved but not the private email id (if this was not intentional).
https://github.com/FreeCodeCamp/FreeCodeCamp/blob/staging/server/passport-providers.js#L147
https://github.com/FreeCodeCamp/FreeCodeCamp/blob/staging/server/passport-providers.js#L161
This was added in commit https://github.com/FreeCodeCamp/FreeCodeCamp/commit/2256f3ef6e2cfec7dd82b975ca5795ba792d2401
Issue Analytics
- State:
- Created 7 years ago
- Comments:6 (6 by maintainers)
I am sure he meant you @abhisekp ! 😅
@BerkeleyTrue OK - great. Thank you for confirming this. @abhisekp since you discovered this issue, would you like to be the contributor to create the pull request?