Attempt cracking a proctected zip file using simple brute force.
This is a fun project to learn more about python modules, this project uses three:
- Tqdm: For the Progress Bar
- ZipFile: For working with zips
- PathLib: To check the validity of paths entered
from pathlib import Path
from zipfile import ZipFile
from tqdm import tqdm
root
|--- zips/
|--- secret.zip
|--- script.py
To actually run this script, you need a wordlist
which is like a collection of passwords that we're going to cycle through and test against,
be sure to place this file in the root directory (or any folder in the root directory) and pass in the correct path to the text file in the terminal otherwise it won't work, you can use this one [133 MB] containing about 14 million commonly used passwords stored in decreasing order of frequency
I stored my wordlist
text file which is called passwords in the root directory. I also have a zip in the zips/
directory which I called secret.
This command executes the script if you've added python to your PATH VARIABLES
~ python script.py
as you can see, I've cracked the zip file in just under 4 mins. It's an unusual password, but it works
This project was made to learn more about python libraries and modules, it's not intended to be used in any malicious way. You're responsible for how you chose to use the script.
Made with python and ☕