Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stuck in Google account picker loop #18

Open
kmcital opened this issue Aug 17, 2017 · 8 comments
Open

Stuck in Google account picker loop #18

kmcital opened this issue Aug 17, 2017 · 8 comments
Assignees
Labels

Comments

@kmcital
Copy link

kmcital commented Aug 17, 2017

A setup using no login path in the Login plugin settings seems to work if I have all the redirect URI's added to my google API credentials, but when I use the login path (eg. /login) so that I only have to use one redirect URI (eg. www.mysite.com/login) then I get stuck during authorization in a loop where I pick my google account and it redirects, redirects and then goes back to picking a google account (that's on Safari). On Chrome, I get "accounts.google.com redirected you too many times."

I deleted my Google API credentials and redeployed a new Google credentials, cleared cookies and tried again. No luck.

@Vivalldi Vivalldi added the bug label Aug 17, 2017
@Vivalldi Vivalldi self-assigned this Aug 17, 2017
@Vivalldi
Copy link
Collaborator

@kmcital what does your config file look like? (please comment out API keys).

@kmcital
Copy link
Author

kmcital commented Aug 18, 2017

@Vivalldi here you go...

login-oauth.yaml:

enabled: true
built_in_css: true
providers:
  Facebook:
    enabled: false
    enable_email: false
  Google:
    enabled: true
    credentials:
      key: xxxxxxxxxx
      secret: xxxxxxxxxxx
    whitelist:
      - mydomain.com
  GitHub:
    enabled: false
  Twitter:
    enabled: false
  Linkedin:
    enabled: false

login.yaml (with current workaround of no login route path specified, otherwise I would add /login):

enabled: true
built_in_css: true
route_activate: /activate_user
route_forgot: /forgot_password
route_reset: /reset_password
route_profile: /user_profile
route_register: /user_register
parent_acl: true
protect_protected_page_media: false
user_registration:
  enabled: true
  fields:
    - username
    - password
    - email
    - fullname
    - title
  access:
    site:
      login: 'true'
  options:
    validate_password1_and_password2: true
    set_user_disabled: false
    login_after_registration: true
    send_activation_email: false
    send_notification_email: false
    send_welcome_email: '1'
rememberme:
  enabled: true
  timeout: 604800
  name: grav-rememberme
max_pw_resets_count: 0
max_pw_resets_interval: 60
max_login_count: 0
max_login_interval: 2

@Vivalldi
Copy link
Collaborator

@kmcital I am unable to reproduce this. I've used the same configuration (save for client keys) and added the login path as you specified. I am able to login as normal with Google.

@Vivalldi
Copy link
Collaborator

Can you PM me on slack?

@mlzy
Copy link

mlzy commented Feb 6, 2018

@Vivalldi I encountered same problem. Is this issue resolved or not yet? Thank you!

@kmcital
Copy link
Author

kmcital commented Feb 6, 2018 via email

@jacobm001
Copy link

I'm having this same issue on my site. The Google account picker is returning a state in the URL, but the Grav login system doesn't appear to be picking it up for some reason. Like another user, I have manually configured the login route to /login. Having that unset doesn't allow the direct login page to work.

Might these issues be related?

@jorgemfm
Copy link

jorgemfm commented May 15, 2018

I have updated grav and all plugins last night and i'm having the same issue.

Has this been solved or is there anything I can do as a Work around besides disabling it?

EDIT:
Another thing I noticed is that even if I want to use the username/password combination, there's no password field.

grav_login

This is the form from the comments plugin which is rather strange

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

5 participants