mirror of
https://github.com/certbot/certbot.git
synced 2026-07-30 16:14:44 +02:00
_JWAHS.verify constant compare warning
This commit is contained in:
@@ -71,7 +71,12 @@ class _JWAHS(JWASignature):
|
||||
return HMAC.new(key, msg, self.digestmod).digest()
|
||||
|
||||
def verify(self, key, msg, sig):
|
||||
# TODO: use constant compare to mitigate timing attack?
|
||||
"""Verify the signature.
|
||||
|
||||
.. warning::
|
||||
Does not protect against timing attack (no constant compare).
|
||||
|
||||
"""
|
||||
return self.sign(key, msg) == sig
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user