Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upAdd OAUTH_SIGNATURE EncodeSet #148
Conversation
This character set is defined in rfc5849 https://tools.ietf.org/html/rfc5849#section-3.6 and is used to encode the signature base string and and the "Authorization" header field
|
Since this part of the OAuth 1.0 RFC is just refering to I'm currently a bit confused about the naming scheme that is used for encoding sets, but it seems |
Unreserved character set defined in rfc3986 https://tools.ietf.org/html/rfc3986#section-2.3
|
updated. agree it is a better name. I'm not sure what the comment should be changed to, if anything, to fit with the UNRESERVED name while keeping the "is used for" phrasing. incidentally I noticed HTTP_VALUE_ENCODE_SET is not listed in the docs (https://servo.github.io/rust-url/url/percent_encoding/index.html), though it does exist in the copy of the file in the repo (https://github.com/servo/doc.servo.org/blob/gh-pages/url/percent_encoding/index.html#L89), but I don't know whether this is in error or where it would make sense to report this. |
|
Not sure either. ISTM that
So perhaps:
|
Ironically rust-url doesn't do percent-encoding normalization, so I've filed #149 |
|
thank you, updated. |
|
Rather than add this (and later another set for another use case, and another…) I’d like to do something like #151 so you could define this in your own crate. What do you think? |
|
@SimonSapin This particular set might actually be needed depending on your response to #149 |
|
@untitaker I don’t understand how that particular set is relevant to #149, but that should probably be discussed there since this PR is originally about supporting OAuth. |
|
@SimonSapin if I understand correctly, this would allow me to call the I don't know enough on the topic to have an opinion on whether this particular set ought to be in the lib proper for normalization in-browser and leave it to your judgement. |
Yes, exactly.
My opinion of the scope of rust-url is "things defined in https://url.spec.whatwg.org/" |
|
|
|
1.0.0 will be published tomorrow. It has a mechanism for defining your own encode set: |
alicemaz commentedNov 28, 2015
This character set is defined in rfc5849
https://tools.ietf.org/html/rfc5849#section-3.6
and is used to encode the signature base string and
and the "Authorization" header field
relevant bit of the oauth 1.0 rfc is:
tested with all ascii values 32-126 in both the signature and the header