Checksum routine - new to Python

Peter Schneider-Kamp petersc at stud.ntnu.no
Fri May 19 01:29:49 EDT 2000


Alex wrote:
> 
> > Is there a difference between the binascii.crc_hqx and the zlib.crc32
> > call?
> 
> I don't know.  The place to check would be the source code of the two
> modules, I guess.

And the results (as far as I can see) are:

1) zlib.crc32:
is just a wrapper for the zlib's crc32 algorithm. probably
good for speed but you don't know what you get (and depending in
availability on zlib is not perfect either).

2) binascii.crc_hqx:
seems to be a crc16 implementation used for the hqx-encoding.

3) binascii.crc32:
obviously a crc32 algorithm with a nice documentation and
some ISO blur. I think that'd be the way to go.

spam-and-egg-ly y'rs
--
Peter Schneider-Kamp          ++47-7388-7331
Herman Krags veg 51-11        mailto:peter at schneider-kamp.de
N-7050 Trondheim              http://schneider-kamp.de




More information about the Python-list mailing list