summaryrefslogtreecommitdiffstats
path: root/Doc/library/hmac.rst
diff options
context:
space:
mode:
Diffstat (limited to 'Doc/library/hmac.rst')
-rw-r--r--Doc/library/hmac.rst11
1 files changed, 9 insertions, 2 deletions
diff --git a/Doc/library/hmac.rst b/Doc/library/hmac.rst
index 1d928ea..8fa1435 100644
--- a/Doc/library/hmac.rst
+++ b/Doc/library/hmac.rst
@@ -18,13 +18,20 @@ This module implements the HMAC algorithm as described by :rfc:`2104`.
Return a new hmac object. *key* is a bytes or bytearray object giving the
secret key. If *msg* is present, the method call ``update(msg)`` is made.
- *digestmod* is the digest constructor or module for the HMAC object to use.
- It defaults to the :data:`hashlib.md5` constructor.
+ *digestmod* is the digest name, digest constructor or module for the HMAC
+ object to use. It supports any name suitable to :func:`hashlib.new` and
+ defaults to the :data:`hashlib.md5` constructor.
.. versionchanged:: 3.4
Parameter *key* can be a bytes or bytearray object. Parameter *msg* can
be of any type supported by :mod:`hashlib`.
+ Paramter *digestmod* can be the name of a hash algorithm.
+
+ .. deprecated:: 3.4
+ MD5 as implicit default digest for *digestmod* is deprecated.
+
+
An HMAC object has the following methods:
.. method:: HMAC.update(msg)