-
-
Notifications
You must be signed in to change notification settings - Fork 156
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
Updated Azure to allow defining authorization_url_params #288
Conversation
Codecov Report
@@ Coverage Diff @@
## master #288 +/- ##
==========================================
+ Coverage 96.63% 96.66% +0.02%
==========================================
Files 28 28
Lines 922 929 +7
==========================================
+ Hits 891 898 +7
Misses 31 31
Continue to review full report at Codecov.
|
This is great! Thank you so much for doing this! However, it sounds like your goal is being able to set For example, the Google blueprint does this for the Does that seem closer to what you want? Or is there a reason why you want to allow users to set |
Also, thanks for fixing the documentation tests! I've cherry-picked that commit onto the master branch, so you can remove it from this pull request. 😄 |
No problem! The only argument I really need is I will add them to the argument list as you suggest. Would you like me to do it under a new PR or keep this one open? Thanks |
You can rebase this pull request and make the changes here, or close this one and open a new one. Whichever you prefer -- it makes no difference to me! |
Here's a handy guide for how to rebase, if you're not familiar with it: https://github.com/edx/edx-platform/wiki/How-to-Rebase-a-Pull-Request |
Thanks for the link, I have rebased and will work on the aforementioned changes |
promt, domain_hint and login_hint
All tests pass. Hopefully this is okay. I couldn't implement exactly like the Google one using bools, as Azure SSO only allows one prompt not multiple. Thanks |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fantastic! However, there's one other change you need to make: please move these new function arguments to the end of the list, after the "tenant" argument. If people are calling make_azure_blueprint()
with positional arguments, this change in argument ordering could cause backwards incompatibilities. For example, if someone calls make_azure_blueprint("my-id", "my-secret", "scope1,scope2,scope3")
, they would expect the third argument to be treated as scopes
-- but right now, it would suddenly become domain_hint
!
I think that once you make this change (and reorder the documentation for these arguments to match) this will be ready to merge!
Hello, Very valid point, I forgot people might not specify the param name when calling the function! Hopefully this is now complete. Thanks |
Fantastic! This is now merged, and released with Flask-Dance 3.0! 😄 |
Awesome, thank you! 😊 |
I hope this is all okay. I have updated the Azure provider to allow someone to define authorization_url_params to pass additional data.
Azure supports extra parameters such as
prompt
,login_hint
anddomain_hint
https://docs.microsoft.com/en-us/azure/active-directory/develop/v1-protocols-oauth-code#request-an-authorization-code