Skip to content

Conversation

tnantoka
Copy link
Contributor

Thank you for the great gem!

By the following implementation, all authorize_options can be overridden with request parameters.

options[:authorize_options].each do |k|
params[k] = request.params[k.to_s] unless [nil, ''].include?(request.params[k.to_s])
end

For example, even if we restrict it with hd: 'exanple.com', end-users can use any hd with /oauth/google_oauth2?hd=example.net.
It's flexible and convenient, but it may be unexpected behavior in some apps.

I have added an option to control this behavior with this pull request.
If you don't need this change, feel free to close it.

Thanks,

@zquestz zquestz merged commit d7e862c into zquestz:master Sep 3, 2022
@zquestz
Copy link
Owner

zquestz commented Sep 3, 2022

Thanks, decided this should go in. Appreciate the work. =)

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

Successfully merging this pull request may close these issues.

2 participants