parse-community / parse-community/parse-server
Parse server V6.2.0 & V7.2.0 don't return session token after logInWith google
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 21.4k
- Forks
- 4.8k
- Avg merge
- 7h 45m
- Merged PRs (30d)
- 11
Description
Issue Description
With the older versions of Parse server, after logInWith Google I could have access to user's session, but with the V6.2.0 & V7.2.0 it returns everything but the sessionToken!
Steps to reproduce
const session = await Parse.User.logInWith('google', {
authData: {
id,
id_token,
access_token,
},
});
Actual Outcome
{
"authData": {
"google": {
"id": "113****7",
"id_token": "****DUZ2I",
"access_token": "****Am"
}
},
"createdAt": "2024-05-06T09:07:55.392Z",
"username": "TE8******5Tv9",
"authDataResponse": {},
"updatedAt": "2024-05-06T09:07:55.392Z",
"objectId": "xoU****YHO",
"__type": "Object",
"className": "_User"
}
Expected Outcome
{
"authData": {
"google": {
"id": "10**17",
"id_token": "****dARiIF",
"access_token": "y***71"
}
},
"createdAt": "2024-05-06T09:06:15.828Z",
"username": "F0VTk9*********PSJGZM",
"sessionToken": "r:5fa4793a*********************ce3",
"updatedAt": "2024-05-06T09:06:15.828Z",
"objectId": "xoU****YHO",
"__type": "Object",
"className": "_User"
}
Environment
Server
- Parse Server version:
6.2.0&7.2.0
Database
- System (MongoDB or Postgres):
MongoDB - Local or remote host (MongoDB Atlas, mLab, AWS, Azure, Google Cloud, etc):
Tested on both
Client
- SDK (iOS, Android, JavaScript, PHP, Unity, etc):
JavaScript
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the JavaScript Parse.User.logInWith('google', ...) case against Parse Server 6.2.0 or 7.2.0 with MongoDB, comparing the returned user object with the expected sessionToken. Trace the login and session-creation entry points involved in Google authentication. Done means the response includes a valid sessionToken without removing the existing auth data.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, mongodb, nodejs
- Domain
- authentication
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100