From: Thierry Parmentelat Date: Mon, 25 Nov 2024 15:17:54 +0000 (+0100) Subject: fix plc_crypt name X-Git-Tag: plcapi-7.2-6~1 X-Git-Url: http://git.onelab.eu/?a=commitdiff_plain;h=eac360afff0fb4baab0d5f401dd394857d26a33a;p=plcapi.git fix plc_crypt name --- diff --git a/PLC/plc_crypt.py b/PLC/plc_crypt.py index f8ba4da8..2715495b 100644 --- a/PLC/plc_crypt.py +++ b/PLC/plc_crypt.py @@ -115,7 +115,7 @@ def crypt_md5(password: str, salt: str) -> str: salt = salt[3:].encode() return bin_crypt_md5(key, salt)[1] -crypt = crypt_md5 +plc_crypt = crypt_md5 # some test cases @@ -139,7 +139,7 @@ def test_crypt(): ] for plaintext_password, expected in BY_STANDARD_CRYPT: - computed = crypt(plaintext_password, expected) + computed = plc_crypt(plaintext_password, expected) if computed == expected: print(f"match: {plaintext_password:>30} == {computed}") else: