pr00f Posted April 6, 2015 Report Posted April 6, 2015 """md5pybrute----------plain retarded `bruteforcer' for md5based on a dictionary----------Usage: BruteHash(hash, dictionary).start()"""import hashlibimport threadingclass BruteHash(threading.Thread): """ theaded worker """ def __init__(self, uhash, filename): self.uhash = uhash self.filename = filename try: self.filehandler = open(self.filename, "r", encoding="utf-8") except FileNotFoundError: print("No such file, exiting.") exit(1) except IsADirectoryError: print("No directories, files only.") exit(1) else: self.lines = self.filehandler.readlines() threading.Thread.__init__(self) def run(self): for line in self.lines: line = line.replace("\n", "").encode("utf-8") thash = hashlib.md5(line).hexdigest() if thash == self.uhash: print("Found a match!\n", line.decode()) exit() Quote
MasterLight Posted April 9, 2015 Report Posted April 9, 2015 (edited) . Edited July 5, 2016 by MasterLight Quote