From 332d43c77d02587dbfaa32aa2842f48facbb1362 Mon Sep 17 00:00:00 2001 From: exploide Date: Wed, 15 May 2024 17:02:27 +0200 Subject: [PATCH] python: recommend pycryptodome package over PyCrypto PyCrypto is old and deprecated, pycryptodome works as a drop-in replacement --- doc/Auditing-Kerio-Connect.md | 4 ++-- run/DPAPImk2john.py | 2 +- run/telegram2john.py | 8 ++++---- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/doc/Auditing-Kerio-Connect.md b/doc/Auditing-Kerio-Connect.md index c918630572..448b43157c 100644 --- a/doc/Auditing-Kerio-Connect.md +++ b/doc/Auditing-Kerio-Connect.md @@ -41,7 +41,7 @@ The following script can be used to reverse these "D3S" scrambled password strin #!/usr/bin/env python import sys -from Crypto.Cipher import DES3 # pip install --user pycrypto +from Crypto.Cipher import DES3 # pip install --user pycryptodome # Password unscrambler for Kerio Connect. # @@ -180,7 +180,7 @@ follows, #!/usr/bin/env python import sys -from Crypto.Cipher import DES # pip install --user pycrypto +from Crypto.Cipher import DES # pip install --user pycryptodome # Password unscrambler for Kerio Connect. diff --git a/run/DPAPImk2john.py b/run/DPAPImk2john.py index 6fb47176e7..49659e6614 100755 --- a/run/DPAPImk2john.py +++ b/run/DPAPImk2john.py @@ -30,7 +30,7 @@ from Crypto.Cipher import DES from Crypto.Cipher import DES3 except ImportError: - sys.stderr.write("Error: Please install PyCrypto package.\n") + sys.stderr.write("pycryptodome python package is missing, please install it using 'pip install --user pycryptodome' command.\n") sys.exit(1) debug = False diff --git a/run/telegram2john.py b/run/telegram2john.py index 16a3f111a9..569144f2e7 100755 --- a/run/telegram2john.py +++ b/run/telegram2john.py @@ -59,8 +59,8 @@ from Crypto.Cipher import AES except ImportError: check_empty_pass = False - sys.stderr.write("For additional functionality, please install the PyCrypto package.\n") - sys.stderr.write("run 'pip install --user PyCrypto' to install it!\n") + sys.stderr.write("For additional functionality, please install the pycryptodome package.\n") + sys.stderr.write("run 'pip install --user pycryptodome' to install it!\n") PY3 = sys.version_info[0] == 3 @@ -153,7 +153,7 @@ def is_correct_ige_decryption(file_path, key, data): def is_map0_empty_pass(file_path, salt_hex, data_hex): if not check_empty_pass: - sys.stderr.write("ATTENTION: it couldn't be verified if a password was set for the file/account: '%s' (please install the PyCrypto package)\n" % file_path) + sys.stderr.write("ATTENTION: it couldn't be verified if a password was set for the file/account: '%s' (please install the pycryptodome package)\n" % file_path) return False salt = binascii.unhexlify(salt_hex) @@ -165,7 +165,7 @@ def is_map0_empty_pass(file_path, salt_hex, data_hex): def is_key_datas_empty_pass(file_path, salt_hex, data_hex): if not check_empty_pass: - sys.stderr.write("ATTENTION: it couldn't be verified if a password was set for the file/account: '%s' (please install the PyCrypto package)\n" % file_path) + sys.stderr.write("ATTENTION: it couldn't be verified if a password was set for the file/account: '%s' (please install the pycryptodome package)\n" % file_path) return False salt = binascii.unhexlify(salt_hex)