ó J(Zc@sŹdZdZdddgZddlTddlmZyddlZejZWn#e k rsddl Z e ZnXdefd „ƒYZ dd „Z e jZe jZdS( sSHA-1 cryptographic hash algorithm. SHA-1_ produces the 160 bit digest of a message. >>> from Crypto.Hash import SHA >>> >>> h = SHA.new() >>> h.update(b'Hello') >>> print h.hexdigest() *SHA* stands for Secure Hash Algorithm. This algorithm is not considered secure. Do not use it for new designs. .. _SHA-1: http://csrc.nist.gov/publications/fips/fips180-2/fips180-2.pdf s$Id$tnewt digest_sizetSHA1Hashi˙˙˙˙(t*(tHashAlgoNcBs>eZdZedƒZdZdZdd„Zdd„Z RS(sJClass that implements a SHA-1 hash :undocumented: block_size s+ii@cCstj|t|ƒdS(N(Rt__init__t hashFactory(tselftdata((s1/tmp/pip-build-LvEk9W/pycrypto/Crypto/Hash/SHA.pyRIscCs t|ƒS(N(R(RR((s1/tmp/pip-build-LvEk9W/pycrypto/Crypto/Hash/SHA.pyRLsN( t__name__t __module__t__doc__tbtoidRt block_sizetNoneRR(((s1/tmp/pip-build-LvEk9W/pycrypto/Crypto/Hash/SHA.pyR6s   cCstƒj|ƒS(sReturn a fresh instance of the hash object. :Parameters: data : byte string The very first chunk of the message to hash. It is equivalent to an early call to `SHA1Hash.update()`. Optional. :Return: A `SHA1Hash` object (RR(R((s1/tmp/pip-build-LvEk9W/pycrypto/Crypto/Hash/SHA.pyROs (R t _revision__t__all__tCrypto.Util.py3compattCrypto.Hash.hashalgoRthashlibtsha1Rt ImportErrortshaRRRRR(((s1/tmp/pip-build-LvEk9W/pycrypto/Crypto/Hash/SHA.pyt$s