Permalink
Browse files

Fix bug in HTTP-digest auth w/ URI having query string

  • Loading branch information...
1 parent 6af6a08 commit 79f5d532c6a9ffcbb32b8cfcae8ec542c2699ff1 Tom Moertel committed Jan 10, 2012
Showing with 3 additions and 1 deletion.
  1. +3 −1 requests/auth.py
View
@@ -86,7 +86,9 @@ def handle_401(self, r):
# XXX not implemented yet
entdig = None
p_parsed = urlparse(r.request.url)
- path = p_parsed.path + p_parsed.query
+ path = p_parsed.path
+ if p_parsed.query:
+ path += '?' + p_parsed.query
A1 = '%s:%s:%s' % (self.username, realm, self.password)
A2 = '%s:%s' % (r.request.method, path)

0 comments on commit 79f5d53

Please sign in to comment.