Is anybody knows about a linkable, quick MD5/SHA1 calculator library ?
Fredrik Lundh
fredrik at pythonware.com
Mon May 29 15:50:03 EDT 2006
DurumDara wrote:
> I use the Python standard modules, but I think that it can be faster if
> I use C, or other module for it.
Python's MD5 and SHA-1 code is written in C, and is quite fast:
python -m timeit -s "import sha; s = sha.new(); S = '*'*1000000"
"s.update(S)"
100 loops, best of 3: 12.2 msec per loop
python -m timeit -s "import md5; s = md5.new(); S = '*'*1000000"
"s.update(S)"
100 loops, best of 3: 6.45 msec per loop
are you sure it's really a CPU-bound problem?
</F>
More information about the Python-list
mailing list