Answer the question
In order to leave comments, you need to log in
How to create your own dictionary using iterations?
I want to try to write my own dictionaries for various hashes: md5, sha-256, sha-1, DES, RSA. So that in output-file.txt you can see something like (for md4 hash):
bde52cb31de33e46245e05fbdbd6fb24:a
7aeafcb2818e533b384433dea80992f5:b
9a8b795af56c9a4e3d2fc23794edc209:c
5d3f7ed29552c4ab4612fb7686bb52bb:d
import hashlib
# доступные символы
stringAvailable = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890 _-+!?"
availableSymbols = list(stringAvailable)
# hashtype
hashtype = 'md4'
# максимальное количество символов в генерируемой строке
maxsize = 20
# массив в котором буду хранить строки и их хеш-суммы
generated = {}
def generate(symbols, size):
#...
string # должна быть сгенерированная строка входа
hashed = hashlib.new(hashtype, string.encode("utf-8")).hexdigest() # хеш сумма
generated[string] = hashed
#...
generate(availableSymbols, maxsize)
Answer the question
In order to leave comments, you need to log in
I have hash 647ecbe1a0666a9022f96eb402ce8124. How can I get a string that gives the same hash amount?You need to write not a brute, but a reverse hash: finding all areas when intermediate values converge to form a correct source string (more precisely and most likely, a list of matching strings or, in other words, all "collisions" of a given hash).
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question