-
Notifications
You must be signed in to change notification settings - Fork 0
/
wifi.sh
30 lines (27 loc) · 887 Bytes
/
wifi.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#Author: Goktug Cetin
#ShellScript (bash)
#!/bin/bash
wifichip=$(sudo airmon-ng | grep -v Driver | awk -F" " {'print $2'})
echo -e "Your avaible wifi card here,select one for start process"
echo -e " $wifichip "
read interface
sudo airmon-ng start $interface
if sudo airmon-ng | grep mon
then
echo "MONITORING NOW XD"
else
echo "Not in monitor mode"
fi
monitor=$(sudo airmon-ng | grep "phy" | awk -F" " {' print $2 '})
echo -e "Specify a output file name(not important, just write something)"
read output
sudo airodump-ng $monitor --write $output
sudo mv $output-01.csv $output.csv
sudo rm -f $output-01*
sudo grep PSK $output.csv | while read line ; do
BSSID=$(echo $line | awk -F"," {' print $1 '})
NAME=$(echo $line | awk -F"," {' print $14 '})
CH=$(echo $line | awk -F"," {' print $4 '})
ENC=$(echo $line | awk -F"," {' print $6 '})
echo " $NAME , $BSSID , $CH , $ENC "
done