python-oauth2 icon indicating copy to clipboard operation
python-oauth2 copied to clipboard

URLs are not normalised properly

Open emanchado opened this issue 15 years ago • 3 comments
trafficstars

According to http://oauth.net/core/1.0a/#rfc.section.9.1.2, URLs must be normalised before using for signatures.

To fix it, it seems enough to change http://github.com/simplegeo/python-oauth2/blob/master/oauth2/init.py#LID292 to read:

self.normalized_url = urlparse.urlunparse((scheme.lower(), netloc.lower(), path, None, None, None))

Otherwise it will break when using URLs like HTTP://Example.com/foo/bar

emanchado avatar Sep 21 '10 11:09 emanchado

@joestump might see if we can get #133 to include changes to close this?

jaitaiwan avatar Jul 29 '15 12:07 jaitaiwan

@jaitaiwan this is a separate issue from #133, but related.

joestump avatar Jul 29 '15 15:07 joestump

Sorry yes that's what I meant.

jaitaiwan avatar Jul 29 '15 22:07 jaitaiwan