如何在 Kali Linux 上破解 7z zip 文件
发布: (2026年3月4日 GMT+8 08:15)
1 分钟阅读
原文: Dev.to
Source: Dev.to
使用 John the Ripper 破解受密码保护的 7z 压缩包
前置条件
sudo apt update && sudo apt install john john-data p7zip-full -y
提取哈希值
John the Ripper 不能直接处理 .7z 文件;首先使用 7z2john 提取密码哈希。
7z2john secrets.7z > secret_hash.txt
破解密码
使用词典(例如 rockyou.txt)配合 John:
john --wordlist=/usr/share/wordlists/rockyou.txt secret_hash.txt
如果成功,John 会显示明文密码。随后可使用以下命令查看:
john --show secret_hash.txt
解压压缩包
得到密码后(例如 butterfly),解压压缩包:
7z x secrets.7z
系统提示时输入已破解的密码,文件将会解压到当前目录。