Passport strategies for authenticating with Google using OAuth 1.0a and OAuth 2.0.
Questions tagged [passport-google-oauth]
178 questions
18
votes
4 answers
How can I make passportjs google login oauth work with JWT instead of creating session through serialize/deserialize method?
The below code will works perfectly If I add the serialize/deserialize passportjs method, which creates a session. I am working to create Json Web Token, not session. Any tutorial, suggestion or clear sample would be greatly appreciated.I use…

sdfdsf sdf
- 383
- 1
- 5
- 12
15
votes
2 answers
Passport & JWT & Google Strategy - Disable session & res.send() after google callback
Using: passport-google-oauth2.
I want to use JWT with Google login - for that I need to disable session and somehow pass the user model back to client.
All the examples are using google callback that magically redirect to '/'.
How do I:
1. Disable…

chenop
- 4,743
- 4
- 41
- 65
11
votes
5 answers
Missing required parameter: redirect_uri with passport-google-oauth
Using passport-google-oauth: "0.2.0" in my MEAN Stack application (found here: https://github.com/jaredhanson/passport-google-oauth). When I run the application and attempt to sign in with a Google API this error is returned
That’s an…

Trewaters
- 949
- 3
- 13
- 23
10
votes
1 answer
Access google connections using google people API
I would like to fetch all the google private connections of a user signed in from my app.
I've enabled the Google People and the Google Plus API's. I set up the credentials API key, client id & client secret. The url with which I'm trying to fetch…

Parth Vyas
- 487
- 4
- 16
9
votes
3 answers
Passport Google Oauth2 not prompting select account when only 1 google account logged in
I'm trying to authenticate users in my node + nestjs api and want to prompt the user to select an account.
The prompt does not show up if you have only 1 account logged in and even when you are logged in with 2 accounts and you get prompted, the…

SebastianG
- 8,563
- 8
- 47
- 111
7
votes
1 answer
Invalid parameter value for redirect_uri: Missing scheme: /auth/google_auth_code/callback
edit: here is a minimal viable project
I am trying to get an access and refresh token from Google from an authorization code for the server-side flow. I followed Google's guide here:…

SamB
- 2,621
- 4
- 34
- 39
6
votes
4 answers
passport-google-oauth Failed to fetch user profile ECONNRESET
login via google on my meanjs website stopped working all of the sudden after three years, without any change to the code.
The request sent:
/**
* Module dependencies
*/
var passport = require('passport'),
GoogleStrategy =…

Dor Moshkovitz
- 371
- 1
- 3
- 9
5
votes
1 answer
localhost redirect_uri does not work for Google Oauth2 (results in 400: invalid_request error)
There was a recent update to the Google Cloud Platform oauth service enforcing strict usage of HTTPS for all redirect URIs. However, localhost urls should be exempt, and those are allowed to use http. More generally, the rules for validation are…

Funtao Bang
- 59
- 1
- 9
5
votes
2 answers
when does the passport.js failure redirect gets hit?
I have been using passport.js to perform OAuth. So the redirect URI gets hit after successful authentication,
However for the failure scenarios. I am not able to trigger it anyway,
What happens in the following scenarios?
1. When the…

Mahesh Kumaran
- 887
- 2
- 12
- 30
4
votes
1 answer
Cookies not being set when login using Google Login and passport
I am using nodejs and react on heroku and passport js. I have code that logs a user in using google; however, a cookie is not being set for that user. The first time the user tries to log in using google, he is redirected back to the server endpoint…

Chris Hansen
- 7,813
- 15
- 81
- 165
4
votes
1 answer
setting cookie after google passport callback
I am using facebook and google oauth2 login using passport js, with this flow
User clicked the login button
Redirects to facebook/google auth page (depending on what login the user chooses)
The auth page redirects back to a callback page…

littlechad
- 1,202
- 17
- 48
4
votes
1 answer
NodeJS passport How to migrate project from Google+ sign in to Google sign In?
Few days back, I had received a message from google that they are removing their Google+ Api's. Is there any way I can migrate the project using passportJS. What are the required steps?

Unity Hour
- 550
- 2
- 7
- 22
4
votes
0 answers
Google Auth with Android as client side and node js as server
I have searched many links but didn't find any tutorial about :
https://developers.google.com/identity/sign-in/android/backend-auth
I want to configure my backend server for google authentication
my android code:
public class SignInActivity extends…

Yash Arora
- 360
- 1
- 5
- 10
4
votes
2 answers
req.user is undefined after logging in with google-passport-oauth
After I successfully log in using a Google account, in the callback request, req.user is set to the right user and req.isAuthenticated() is true. Great!
However, any subsequent request will have req.user as undefined. No matter what I do.
The…

Andre Pena
- 56,650
- 48
- 196
- 243
3
votes
1 answer
Google Oauth2.0 Unpublished Test App accepts users not in test user list
I use google Ouath2.0 with passport.js in my Next.js/Node.js web-app. Registering and logging in works as expected. However, anyone with a google account is able to register, regardless of being in the test users list. The app is unpublished, and so…

oddgrd
- 308
- 3
- 6