-
Notifications
You must be signed in to change notification settings - Fork 10.9k
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
Google OAuth Login broken in 4.4.0 #24355
Comments
For people coming here, I fixed it by removing
Did this |
@sampaiodiego we might need to call this out as a breaking change or at least a note in release notes? |
Don't know if related to this, but now in version 4.4.1, everyone trying to login with Google is getting an "Internal Server Error". |
@danielfariati did you end up removing |
No. We actually have both there. Google: RocketChat: I can see in the settings that Accounts_OAuth_Google_callback_url is https://[our-domain]/_oauth/google (without the ?close). But that is not customizable and I assume is the server default. The google auth page that open show the redirect URI as https://[our-domain]/_oauth/google?close, so it should work... But it doesn't. |
Confirmed. We have the same issue while also having both redirect urls authorized (with and without it logs as
Google auth page is opened with query parameter But settings/administrations claims that the redirect uri should be the one without |
@sampaiodiego
As you can see, the URL is defined without the ?close . Admins also can't change that, as it is readonly.
|
@danielfariati good idea. db.rocketchat_settings.update({
_id: 'Accounts_OAuth_Google_callback_url'
}, {
$set: { value: "_oauth/google?close" }
}) (of course be careful when tinkering with DB...) |
Workaround for now:
db.migrations.update({_id: "control", version: 254}, {$set: {version: 253}})
Migration |
I downgraded to 4.4.0 from 4.4.1 and added both URL with and without Step to reproduce
Expected behaviorThe mobile app should be logged in Actual behaviorThe login screen is shown again |
looks like there was a missing piece on the fix.. I'm working in a new fix right now |
so... does that mean this should be reopened, then? |
the missing part was already done (#24450) and released on 4.4.2 |
Then why is it still broken for the MacPorts Rocket.Chat instance? |
not sure @cooljeanius .. can you please provide more information? any error message on the logs? |
Just the "Internal Server Error" in the upper right-hand corner: |
The exact error we see in the logs is:
|
Same error in The toast error we're getting is: |
Downstream issue on the MacPorts Trac: https://trac.macports.org/ticket/65937 |
Description:
After upgrading to 4.4.0, Google OAuth complains about
redirect_uri
mismatch. Nothing has changed in the config, only upgraded from 4.3.0 to 4.4.0 caused this.Steps to reproduce:
Expected behavior:
Google OAuth should work normally as it was working a version before.
Actual behavior:
Server Setup Information:
Client Setup Information
Chrome Version 97.0.4692.99 (Official Build) Arch Linux (64-bit)
Additional context
The OAuth URL is correct and unchanged in the settings:
Relevant logs:
The text was updated successfully, but these errors were encountered: