-
Notifications
You must be signed in to change notification settings - Fork 211
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 auth redirect loop with hapi v18 #394
Comments
Also seeing this with the FB provider. From what I can tell when the OAuth client code gets to here: https://github.com/hapijs/bell/blob/master/lib/oauth.js#L176
|
I'm seeing this behavior too on my first time using Bell. Is it looking like a module error or user error? EDIT: I'm using Discord |
I can confirm this is happening with hapi@18 🙊 |
I'm seeing the same issue with the Twitch provider. I've rolled back to Hapi@17 for now and the problem goes away. |
I think this is an issue with just the oAuth flow code and hapi@18. |
Some of the errors appear to be because of a change to server.inject in hapi@18. Specifically it seems to eat the port now if it's port 80 (and I assume 443 though I haven't tested it). That doesn't explain the loop being caused in real code, but does cover some of the broken tests. |
This PR includes two fixes related to [hapi 18](hapijs/hapi#3871): 1. Many tests broke because hapi now strips the default port from `request.info.host` (a side effect of using the WHATWG URL API) – causing lots of assertions to fail. I decided to use a non-default port in the tests instead of removing the default port from the assertions. This verifies that port info is still propagated correctly. 2. `request.url.query` is no longer available. I’ve changed it to `request.query` which works for hapi 18 and older versions. (I’ve tested it with hapi 17 and 18). This fixes #394.
This thread has been automatically locked due to inactivity. Please open a new issue for related bugs or questions following the new issue template instructions. |
Upgrading from v17.8.1 -> v18.0.0 seems to cause a redirect loop. Following the same exact configuration pattern as https://github.com/hapijs/bell/blob/master/examples/google.js
My router handler is never actually called, instead the route is redirected to the google SSO login page, and when the correct google account is selected, it redirects back, but the handler is never called. Instead it redirects back to Google. Downgrading to 17.8.1 it works fine.
The text was updated successfully, but these errors were encountered: