aboutsummaryrefslogtreecommitdiff
path: root/modules/sasl
diff options
context:
space:
mode:
authorGravatar jesopo2019-02-15 01:21:24 +0000
committerGravatar jesopo2019-02-15 01:21:39 +0000
commita7d3fd93fc901de46fee0d3d9ce4b6422408965d (patch)
tree363de8403a2d1366f556d1c776f26a0a3ab5789f /modules/sasl
parentOnly send `+draft/delivered` and `+draft/read` on private message (diff)
signature
`hmac.digest` -> `hmac.new` (the former is too new) (sasl.scram)
Diffstat (limited to 'modules/sasl')
-rw-r--r--modules/sasl/scram.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/sasl/scram.py b/modules/sasl/scram.py
index 80c6cbad..b3c75313 100644
--- a/modules/sasl/scram.py
+++ b/modules/sasl/scram.py
@@ -48,7 +48,7 @@ class SCRAM(object):
return dict((piece[0], piece[1]) for piece in pieces)
def _hmac(self, key: bytes, msg: bytes) -> bytes:
- return hmac.digest(key, msg, self._algo)
+ return hmac.new(key, msg, self._algo).digest()
def _hash(self, msg: bytes) -> bytes:
return hashlib.new(self._algo, msg).digest()