Skip to content
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

Use more restrictive non-escaped character set, per RFC 5849 Section 3.6 #36

Merged
merged 1 commit into from
Aug 16, 2021

Conversation

bdaz
Copy link

@bdaz bdaz commented Aug 6, 2021

Use more restrictive non-escaped character set, per OAuth Spec (RFC 5849 Section 3.6)

https://datatracker.ietf.org/doc/html/rfc5849#section-3.6

Motivation: \n should be percent encoded. Rather than keep battling this (ala #23), here's a PR that I think is literally what the OAuth spec demands for URL encoding characters that aren't a-z, A-z, 0-9, and the reserved characters:

I confirm that this contribution is made under the terms of the license found in the root directory of this repository's source tree and that I have the authority necessary to make this contribution on behalf of its copyright owner.

@adamkaplan
Copy link
Contributor

adamkaplan commented Aug 16, 2021

Sorry for the delay. I spent a very long time carefully pouring over the RFC 5849 when I rewrote this in Swift. Because your PR pertains to the RFC, I wanted to wait until I had enough spare cycles to read it very carefully.

That said, the is valid and your change looks correct. I must have missed this one and copied this old code over to the new branch... Thanks so much for taking the time to submit this.

@adamkaplan
Copy link
Contributor

Tests pass

@adamkaplan adamkaplan merged commit 4cbcdac into yahoo:master Aug 16, 2021
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.

3 participants