From 8486206ca9d050c536df821834317dedcce498e5 Mon Sep 17 00:00:00 2001 From: vvalouch Date: Mon, 12 Sep 2022 14:31:30 +0200 Subject: [PATCH] Replace md5 with sha512 MD5 is not FIPS compliant thus I am proposing this tiny change. --- dateparser/conf.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dateparser/conf.py b/dateparser/conf.py index 3a7c41f89..846636b07 100644 --- a/dateparser/conf.py +++ b/dateparser/conf.py @@ -46,7 +46,7 @@ def get_key(cls, settings=None): return 'default' keys = sorted(['%s-%s' % (key, str(settings[key])) for key in settings]) - return hashlib.md5(''.join(keys).encode('utf-8')).hexdigest() + return hashlib.sha512(''.join(keys).encode('utf-8')).hexdigest() @classmethod def _get_settings_from_pyfile(cls):