Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Force Google OAuth to request a username/password when authenticating a user

When I try to authenticate a user through Google OAuth 1.0, if the user is already logged in with Google, he's automatically asked if he'd like to allow access to my application. I would like to force the user into submitting his/her credentials again to Google, so he may provide a different account than the one he's logged in with (both FB and Twitter OAuth handshake have an option for this).

Also, is there a parameter I can pass on to Google that would make it aware it's in a popup, so it may adjust the layout better ? Again, FB and Twitter take "ownership" of the popup and resize it so their layout fits perfectly. They're also aware of being presented in a popup so a different layout is presented.

Google seems so far behind with its API's. I found the overall implementation difficult to work with, the XML's are creepy and full of useless data, documentation incomplete and overall procedures are not consistent across it's services, or even across the same service!

like image 826
George Avatar asked Nov 08 '11 22:11

George


1 Answers

Try adding max_auth_age=0 to the first OAuth URL. This worked for me.

like image 153
offex Avatar answered Sep 25 '22 23:09

offex