rtCamp / login-with-google

Minimal plugin which allows WordPress user to login with google.
https://wordpress.org/plugins/login-with-google/
GNU General Public License v2.0
57 stars 17 forks source link

Could not retrieve the access token, please try again. #150

Closed icepcp closed 1 year ago

icepcp commented 1 year ago

I am getting the error: Could not retrieve the access token, please try again. image I am not sure if this is due to WordPress multisite configurations. If you require additional information/logs please let me know.

Update: created a new wp site in the multisite and it works however still doesn't work on the site with access token issue

icepcp commented 1 year ago

Solved by copying and pasting my client secret

Ferrari1976 commented 1 year ago

I am facing the same issue on my website (equitymidas.com).

Were you able to get the authentication working on your original site (the one which faced the issue)? If yes, how?

Thank you.

icepcp commented 1 year ago

I am facing the same issue on my website (equitymidas.com).

Were you able to get the authentication working on your original site (the one which faced the issue)? If yes, how?

Thank you.

Hi @Ferrari1976

Apologies for the late reply. I managed to get it to work after copying and pasting my client secret again. I hope this helps, do let me know if you still face the same issue. :)

Thank you.

Ferrari1976 commented 1 year ago

Thank you for your response icepcp. Unfortunately for me, the plugin just stopped working and the error did not go-away even when I tried to change the client id and secret login (created a new one). I had to uninstall the plugin and use an alternate one to get the functionality working again.

Thank you again.

cschiefelbein commented 10 months ago

One of my beta site users is having this issue (she's an admin).

Two of them are not (they can log in, not admins).

And both of my admin accounts are having a different symptom: blank window with the url not fully redirected: https://actonscouts.org/wp-login.php?state=%3D%3D&code=&scope=email+profile+https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fuserinfo.email+openid+https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fuserinfo.profile&authuser=0&hd=actonscouts.org&prompt=none

Fortunately I can log in via hosting provider.

I had switched to this plugin because another one mysteriously stopped working when I wasn't looking. Can't keep switching plugins as a long term solution...

Anyone have any ideas how to troubleshoot?

ETA: it seems that my admins can only log in with GAuth if Administrator is the only role they have (I am using the "Members" plugin from MemberPress to create site-specific roles for RBAC on pages and menu items). Other non-admin users can have multiple roles defined and log in with GAuth and "Login With Google" plugin.

icepcp commented 10 months ago

Hi @cschiefelbein, May i double check that your admins can't log in with many roles, and only with the admin role? I feel like this might be an issue of MemberPress. I don't use WordPress anymore but when i was using it, I used Ultimate Member. If you are on a MultiSite cofig, try creating a new blank website and replicating the extensions

cschiefelbein commented 10 months ago

Hi, thanks for the quick reply.

When I wrote you, my admins could only log in if they had a single role (Administrator).

Now it's a couple of days later and my admins AGAIN can't log in... with a single role. I'm getting the blank page with the redirect URL shown in the URL bar.

Non-admin users can log in just fine. It's maddening :)

I'm not on a multisite config but I'm almost ready to through in the towel on Gauth altogether. What am I missing.... a million sites do use it successfully... I'm happy to pull up whatever might help in theChrome inspector or wireshark. I'm on GoDaddy for Managed WordPress, if that suggests anything.

thanks, Curran

On Mon, Sep 4, 2023 at 10:29 PM Aung Kaung Myat @.***> wrote:

Hi @cschiefelbein https://github.com/cschiefelbein, May i double check that your admins can't log in with many roles, and only with the admin role? I feel like this might be an issue of MemberPress. I don't use WordPress anymore but when i was using it, I used Ultimate Member. If you are on a MultiSite cofig, try creating a new blank website and replicating the extensions

— Reply to this email directly, view it on GitHub https://github.com/rtCamp/login-with-google/issues/150#issuecomment-1705860531, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAAXSFMK6LBBOC3CFKXAUCLXY2E7TANCNFSM6AAAAAAVOSP4N4 . You are receiving this because you were mentioned.Message ID: @.***>

icepcp commented 10 months ago

Hi, Maybe the issue is coming from GoDaddy's WordPress service? I am not sure what plan you are but one of them has a WordPress code optimizer, that could be the issue, but once again, I am not sure. At this point, I suggest just allowing your admins to log in with a username and password. You should also create a new issue in GitHub, however not sure if the developers will respond. When I was having this issue, I was self hosting WordPress and had control of everything.

cschiefelbein commented 10 months ago

Hi,

I just installed the update for your plugin and at least one admin could log in -- but about 15 mins later, the same account started getting "Incorrect CAPTCHA" and "Registration not allowed" errors, displayed on the wp-login.php, instead of being logged in. (We don't use CAPTCHA with Google Login.)

Non-admin account is also getting CAPTCHA errors.

Bummer.

On Thu, Sep 7, 2023 at 12:40 AM Aung Kaung Myat @.***> wrote:

Hi, Maybe the issue is coming from GoDaddy's WordPress service? I am not sure what plan you are but one of them has a WordPress code optimizer, that could be the issue, but once again, I am not sure. At this point, I suggest just allowing your admins to log in with a username and password. You should also create a new issue in GitHub, however not sure if the developers will respond. When I was having this issue, I was self hosting WordPress and had control of everything.

— Reply to this email directly, view it on GitHub https://github.com/rtCamp/login-with-google/issues/150#issuecomment-1709464912, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAAXSFMW4SOSR6BBLMU6XDTXZFF27ANCNFSM6AAAAAAVOSP4N4 . You are receiving this because you were mentioned.Message ID: @.***>

icepcp commented 10 months ago

Hi @cschiefelbein I am not the developer of this plugin and am unable to assist. Do open a new issue on the same repository. I wish you all the best