ankurpiyush26 / pubsubhubbub

Automatically exported from code.google.com/p/pubsubhubbub
Other
1 stars 0 forks source link

Hub: Bad interaction between sha1 body signing and unicode characters #127

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
#

1 more subscribers to contact for: topic = 
http://www.google.com/reader/public/atom/user%2F06483858957752435088%2Fstate%2Fc
om.google%2Fbroadcast, delivery_mode = normal

#
E 12-18 10:54PM 04.018

chr() arg not in range(256)
Traceback (most recent call last):
  File "/base/python_runtime/python_lib/versions/1/google/appengine/ext/webapp/__init__.py", line 517, in __call__
    handler.post(*groups)
  File "/base/data/home/apps/pubsubhubbub/anti-dos.347017557013756752/main.py", line 652, in decorated
    return func(myself, *args, **kwargs)
  File "/base/data/home/apps/pubsubhubbub/anti-dos.347017557013756752/main.py", line 2837, in post
    sub.secret or sub.verify_token or '', payload_utf8),
  File "/base/data/home/apps/pubsubhubbub/anti-dos.347017557013756752/main.py", line 629, in sha1_hmac
    return hmac.new(secret, data, hashlib.sha1).hexdigest()
  File "/base/python_runtime/python_dist/lib/python2.5/hmac.py", line 121, in new
    return HMAC(key, msg, digestmod)
  File "/base/python_runtime/python_dist/lib/python2.5/hmac.py", line 68, in __init__
    self.outer.update(_strxor(key, opad))
  File "/base/python_runtime/python_dist/lib/python2.5/hmac.py", line 9, in _strxor
    return "".join(map(lambda x, y: chr(ord(x) ^ ord(y)), s1, s2))
  File "/base/python_runtime/python_dist/lib/python2.5/hmac.py", line 9, in <lambda>
    return "".join(map(lambda x, y: chr(ord(x) ^ ord(y)), s1, s2))
ValueError: chr() arg not in range(256)

Original issue reported on code.google.com by bslat...@google.com on 19 Dec 2010 at 6:58