Created
January 21, 2022 22:42
-
-
Save vgmoose/caecf2d03becc41dba82bc530a92e5cb to your computer and use it in GitHub Desktop.
Multithreaded luks bruteforcing based on newline separated word list
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os, time, random | |
from collections import deque | |
import threading | |
words = deque([]) | |
f1 = open("words.txt", "r") | |
for word in reversed(f1.readlines()): | |
word = word.strip() | |
words.append(word) | |
def consume(): | |
id = random.randint(0, 10000) | |
while True: | |
word = words.pop() | |
print(f"{id} -- Trying {word}: ") | |
os.system(f"echo -n {word} | cryptsetup luksOpen /dev/nvme3n1p3 drive3") | |
print(f"{id} -- Moving on") | |
for x in range(60): | |
t1 = threading.Thread(target=consume) | |
t1.start() | |
while True: | |
time.sleep(30) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment