macos下安装john the ripper并配置zip2john+破解加密zip文件

为了破解加密的zip文件,需要用到john进行爆破密码。


1、首先使用homebrew安装john,可以安装它的增强版john-jumbo:
brew install john-jumbo
2、安装后可以使用 john 命令验证:
 john

3、配置zip2john的环境——.zshrc下,(因为homebrew的环境变量只到bin目录下,但是zip2john在比较深的目录下,因此需要手工添加环境变量)
export PATH="$PATH:/opt/homebrew/Cellar/john-jumbo/1.9.0_1/share/john/"

配置成功后,如何破解加密的zip文件呢?

4、先获得Hash文件,然后再上John工具

第一步:zip2john 获得中间 Hash 文件

zip2john [options] [zip file] > [output file]

示例代码(加密zip文件名:尸姐全集.zip): 

获得hash文件:尸姐合集.hash

zip2john desktop/mypro/尸姐合集.zip > zip.hash

 如果执行不成功,可以试试:

zip2john desktop/mypro/尸姐合集.zip > zip.hashes

(获取到了之后本地应该有一个.hash的文件)

第二步:john破解中间Hash文件

john zip.hash

破解文件后显示密码 

john zip.hash --show

密码就是红色下划线这一段:

 破解模式的具体方法      破解的密码长度       所包含的字符
Incremental:all         0-8                  All 95 printable ASCII characters
Incremental:all15       0-5                  All 95 printable ASCII characters
Incremental:all6        6                    All 95 printable ASCII characters
Incremental:all7        7                    All 95 printable ASCII characters
Incremental:all8        8                    All 95 printable ASCII characters
Incremental:alpha       1-8                  A-Z     纯大写字母
Incremental:digits      1-8                  0-9     纯数字
Incremental:lanman      0-7            A-Z, 0-9, and some special characters   大写字母,数字加一些特殊字符

猜你喜欢

转载自blog.csdn.net/YiMiMMMi/article/details/131973055