Код: Выделить всё
import hashlib
# Prompt the user to enter the target SHA-1 hash
target_hash = input("Enter the target SHA-1 hash: ")
# Path to the dictionary file
dictionary_file = r'C:\Users\johnny\Documents\Security\src\wordlist.txt'
def dictionary_attack(target_hash, dictionary_file):
with open(dictionary_file, 'r') as file:
for line in file:
word = line.strip()
word_hash = hashlib.sha1(word.encode()).hexdigest()
if word_hash == target_hash:
print(f"Found the original string: {word}")
return word
print("Could not find the original string in the dictionary.")
return None
original_input = dictionary_attack(target_hash, dictionary_file)
Теперь я могу перевернуть его с помощью грубой силы
но проблема в том, что слово состоит из прописных букв, например "JoeJoe" или "j0ej0e" не найдено в списке
но в списке есть "joejoe", как преобразовать его в верхний регистр или есть способ сделать это
извините, я просто начал изучать Python.
Подробнее здесь: https://stackoverflow.com/questions/792 ... rute-force
Мобильная версия