[Python-Dev] PEP 247 and hashlib (original) (raw)

Seo Sanghyeon tinuviel at sparcs.kaist.ac.kr
Mon Jan 16 05:37:18 CET 2006


"PEP 247 -- API for Cryptographic Hash Functions" specifies a standard API for hashing modules.

new([string]) ... the optional 'string' parameter, if supplied, will be immediately hashed into the object's starting state, as if obj.update(string) was called.

But hashlib.new() takes the algorithm name... Does PEP need an update?

By the way, I am thinking about mapping .NET's System.Security.Cryptography.HashAlgorithm.Create and created object's ComputeHash method to Python's hash API for IronPython. For that, I'd like to see a clarification.

Seo Sanghyeon



More information about the Python-Dev mailing list