Ignore:
Timestamp:
Mar 19, 2014, 11:31:01 PM (11 years ago)
Author:
dmik
Message:

python: Merge vendor 2.7.6 to trunk.

Location:
python/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • python/trunk

  • python/trunk/Doc/library/hmac.rst

    r2 r391  
    1 
    21:mod:`hmac` --- Keyed-Hashing for Message Authentication
    32========================================================
     
    1110.. versionadded:: 2.2
    1211
     12**Source code:** :source:`Lib/hmac.py`
     13
     14--------------
     15
    1316This module implements the HMAC algorithm as described by :rfc:`2104`.
    1417
     
    1821   Return a new hmac object.  If *msg* is present, the method call ``update(msg)``
    1922   is made. *digestmod* is the digest constructor or module for the HMAC object to
    20    use. It defaults to  the :func:`hashlib.md5` constructor.
     23   use. It defaults to  the :data:`hashlib.md5` constructor.
    2124
    22    .. note::
    23 
    24       The md5 hash has known weaknesses but remains the default for backwards
    25       compatibility. Choose a better one for your application.
    2625
    2726An HMAC object has the following methods:
    2827
    29 
    30 .. method:: hmac.update(msg)
     28.. method:: HMAC.update(msg)
    3129
    3230   Update the hmac object with the string *msg*.  Repeated calls are equivalent to
     
    3533
    3634
    37 .. method:: hmac.digest()
     35.. method:: HMAC.digest()
    3836
    3937   Return the digest of the strings passed to the :meth:`update` method so far.
     
    4240
    4341
    44 .. method:: hmac.hexdigest()
     42.. method:: HMAC.hexdigest()
    4543
    4644   Like :meth:`digest` except the digest is returned as a string twice the length
     
    4947
    5048
    51 .. method:: hmac.copy()
     49.. method:: HMAC.copy()
    5250
    5351   Return a copy ("clone") of the hmac object.  This can be used to efficiently
Note: See TracChangeset for help on using the changeset viewer.