Skip to content

Commit 35a9f08

Browse files
hbsjoestump
authored andcommitted
Modified get_normalized_parameters so it does not encode '~' for full conformance with RFC 5849 section 3.6
1 parent 50ca957 commit 35a9f08

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

oauth2/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -369,7 +369,7 @@ def get_normalized_parameters(self):
369369
# spec draft 7, section 3.6
370370
# (http://tools.ietf.org/html/draft-hammer-oauth-07#section-3.6)
371371
# Spaces must be encoded with "%20" instead of "+"
372-
return encoded_str.replace('+', '%20')
372+
return encoded_str.replace('+', '%20').replace('%7E', '~')
373373

374374
def sign_request(self, signature_method, consumer, token):
375375
"""Set the signature parameter to the result of sign."""

0 commit comments

Comments
 (0)