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

md4 hash type not supported on some platform

Open GoogleCodeExporter opened this issue 10 years ago • 0 comments

What steps will reproduce the problem?
1. build and install python 2.6.5 on suse linux
2. run the following python code
   digest = hashlib.new('md4', 'password'.encode('utf-16le')).digest()
3. you will see the following exception
  ... 
  File "/home/ejiaden/usr/local/lib/python2.6/hashlib.py", line 87, in __py_new
    return __get_builtin_constructor(name)(string)
  File "/home/ejiaden/usr/local/lib/python2.6/hashlib.py", line 80, in __get_builtin_constructor
    raise ValueError, "unsupported hash type"
ValueError: unsupported hash type


What is the expected output? What do you see instead?
you will see the exception that md4 hash type is not supported

What version of the product are you using? On what operating system?
python-ntlm revision 77, python 2.6.5 built on suse linux 2.6.16.60-0.21-smp

Please provide any additional information below.

for the quick patch, you need to install py-md4 from 
http://barryp.org/software/py-md4/ and apply the attached patch file ntlm.py

Original issue reported on code.google.com by [email protected] on 10 Aug 2010 at 4:36

Attachments:

GoogleCodeExporter avatar Apr 07 '15 17:04 GoogleCodeExporter