-
Notifications
You must be signed in to change notification settings - Fork 481
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
SNOW-1825621 OAuth code flow PKCE support #2137
base: mkeller/SNOW-1825621/oauth-code-flow-support
Are you sure you want to change the base?
SNOW-1825621 OAuth code flow PKCE support #2137
Conversation
dc687f4
to
3684460
Compare
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.
I tried to take a quick look at only the PKCE changes...
hashlib.sha256(self._verifier.encode("utf-8")).digest() | ||
) | ||
.decode("utf-8") | ||
.replace("=", "") |
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.
if it's URL-safe it shouldn't have any padding?
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.
from https://docs.python.org/3/library/base64.html#base64.urlsafe_b64encode
The result can still contain =.
Unfortunately this remains necessary
4591ea1
to
6ae67ca
Compare
6ae67ca
to
81627af
Compare
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.
Looks reasonable to me but I'd prefer to stamp after we see a "clean" diff with the preceding work merged first.
Please answer these questions before submitting your pull requests. Thanks!
What GitHub issue is this PR addressing? Make sure that there is an accompanying issue to your PR.
Fixes SNOW-1825621
Fill out the following pre-review checklist:
Please describe how your code solves the related issue.
This PR builds on top of #2135 and it adds PKCE support on top of OAuth code flow.
This change has been tested manually, as it's fairly complicated to setup and we don't do unit tests for the different authentication methods.