[issue18240] hmac unnecessarily restricts input to "bytes"

2013-06-18 Thread Jonas Borgström
Jonas Borgström added the comment: Of course. I've now signed and filed the agreement. -- ___ Python tracker <http://bugs.python.org/issue18240> ___ ___ Pytho

[issue18240] hmac unnecessarily restricts input to "bytes"

2013-06-18 Thread Jonas Borgström
Jonas Borgström added the comment: Patch updated to include tests and versionchanged tags -- Added file: http://bugs.python.org/file30637/hmac2.patch ___ Python tracker <http://bugs.python.org/issue18

[issue18240] hmac unnecessarily restricts input to "bytes"

2013-06-17 Thread Jonas Borgström
Changes by Jonas Borgström : -- keywords: +patch Added file: http://bugs.python.org/file30628/hmac.patch ___ Python tracker <http://bugs.python.org/issue18

[issue18240] hmac unnecessarily restricts input to "bytes"

2013-06-17 Thread Jonas Borgström
New submission from Jonas Borgström: Problem: In hmac.py there's a type check that verifies that the msg parameter is of type bytes(). if not isinstance(msg, bytes): raise TypeError("expected bytes, but got %r" % type(msg).__name__) That is incorrect. The hmac module should