How To Crack Encrypted ZIP Archives

To start, I created a couple text files on my Windows machine and stored them into an encrypted ZIP archive using 7-zip.

Let’s transfer over the CrackMe.zip file to our Kali machine.

Once the CrackMe.zip file is present on the filesystem, go ahead and Right-Click and select Extract Here .

You’ll get a prompt stating that there is a Password Required .

In order for us to crack this password, we need to first extract its hash. Luckily, John The Ripper has everything we need built-in. Let’s spin up a Terminal window and get started. Start by making sure you’re in the correct directory that contains the ZIP file.

Run the following command to decrypt any hashes that are contained within the archive. This will create a new text document titled hash-to-crack.txt

sudo zip2john CrackMe.zip > hash-to-crack.txt

We can verify the contents of the file by utilizing cat .

cat hash-to-crack.txt

Great! Now that we have a hash contained in the text document, let’s try our hand at cracking it. First, we’ll need a wordlist. I always like to utilize the rockyou.txt wordlist built into Kali first. This list can be found at /usr/share/wordlists/rockyou.txt . If you haven’t first unzipped this list, you’ll want to do that before proceeding. Check out this guide for help with that.

With wordlist in hand, let’s run the following command to start our brute-force.

sudo john --format=zip hash-to-crack.txt --wordlist=/usr/share/wordlists/rockyou.txt

Based on the result above, we see that our password is password123 ! Let’s attempt to extract the archive again, and enter that password to make sure it works.

Doing so creates a new folder titled CrackMe . Let’s go ahead and expand the contents of this and see what we can find!

That’s it! Super quick and easy to crack this if you have a weak password. As you’ve heard 1000 times, strong passwords are essential for keeping your data secure, and this is just one example that proves that.

Source: infinitelogins

18 Likes

Thanks Mate, Great Share, I’ll try this one.

Awesome Share! :star_struck:
Thanks for Sharing!! :100: :+1: @Astrid
Bookmarked! :sunglasses:

Could you explain how to crack on android or/and Windows system?

@Astrid
i followed all the steps but it didn’t fetch me anything. wt should i do now any advice

1 Like

I am not very good at this type of stuff…Does it perform brute force in order to find the password?

I´ve used these brute force rar/zip password recovery programs in the past and, if the password is hard or complicated (many especial characters) it can take days before finding it.