ubuntu 下通过 wireshark 抓取 wifi 数据包

获取当前的 network interface

mali@ubuntu:~$ ifconfig
enp1s0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 192.168.3.6  netmask 255.255.255.0  broadcast 192.168.3.255
        inet6 fe80::892c:5025:2488:6e7a  prefixlen 64  scopeid 0x20<link>
        ether c8:f7:50:f3:dd:24  txqueuelen 1000  (Ethernet)
        RX packets 7166  bytes 6708001 (6.7 MB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 5540  bytes 854385 (854.3 KB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
        loop  txqueuelen 1000  (Local Loopback)
        RX packets 484  bytes 44117 (44.1 KB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 484  bytes 44117 (44.1 KB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

wlx00259cf84e51: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
        unspec 00-25-9C-F8-4E-51-30-3A-00-00-00-00-00-00-00-00  txqueuelen 1000  (UNSPEC)
        RX packets 151204  bytes 33129551 (33.1 MB)
        RX errors 0  dropped 151204  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

mali@ubuntu:~$ 

将无线网卡配置为 monitor 模式

sudo ifconfig wlx00259cf84e51 down
sudo iwconfig wlx00259cf84e51 mode monitor
sudo ifconfig wlx00259cf84e51 up
          
mali@ubuntu:~$ iwconfig
enp1s0    no wireless extensions.

lo        no wireless extensions.

wlx00259cf84e51  IEEE 802.11  Mode:Monitor  Frequency:2.412 GHz  Tx-Power=20 dBm   
          Retry short  long limit:2   RTS thr:off   Fragment thr:off
          Power Management:on
          

使用 wireshark 抓包

wireshark

添加无线 ColoringRules

Coloring of Wireless Lan Packets
在这里插入图片描述

设置 filter
wlan.sa --- source address
wlan.da --- destination address
wlan.addr
wlan.ssid
...
加密的无线报文以明文显示

在这里插入图片描述
在 802.11 preference 菜单里面点击 Edit 弹出密码设置菜单
在这里插入图片描述
选择 wpa-pwd 输入 psk:ssid 点击确定后,原先加密的报文就可以明文显示了。
在这里插入图片描述

抓取到的数据包

在这里插入图片描述
在这里插入图片描述
在这里插入图片描述

参考链接

https://blog.csdn.net/neal_hddnwpu/article/details/82586235

  • 1
    点赞
  • 11
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值