Closed robinw777 closed 6 years ago
@hzalaz can this be merged?
Thanks for this @robinw777, we've encountered the same problem recently.
However can it be made more selective to only pass connection
parameter through?
When all the parameters are being passed through it's causing problems when the application using this gem is both OAuth2 provider (for some other applications) and OAuth2 client (for Auth0).
In such case the nested redirect_uri
it being passed through to Auth0 and overrides the most outer one.
So for example when the chain of OAuth2 authentications looks like this:
A -> B -> Auth0 -> Google
Auth0 will receive redirect_uri
pointing to A
instead of B
.
I've created a PR based on your solution but passing only connection
parameter - https://github.com/auth0/omniauth-auth0/pull/54
@joshcanhelp would rather have params to specify redirect / connection etc Can you look at this in tandem with #54 Thanks
Closing in favor of #54
Although the documentation https://github.com/auth0/omniauth-auth0#auth-parameters says you can append query string (e.g.
redirect_to '/auth/auth0?connection=google-oauth2'
), it's not added to the authorize_url. This makes it hard to dynamically specify a connection in our app.