2017-08-20 19:51:10 -06:00
|
|
|
#!/bin/bash
|
|
|
|
|
2017-12-31 09:02:12 -07:00
|
|
|
if [ -d "lib" ]; then source lib/InterfaceUtils.sh
|
|
|
|
elif [ -d "../lib" ]; then source ../lib/InterfaceUtils.sh
|
2017-12-05 20:12:23 -07:00
|
|
|
else
|
2017-12-31 09:02:12 -07:00
|
|
|
echo "YOU MUST EXECUTE THIS SCRIPT FROM FLUXION'S ROOT!"
|
|
|
|
exit 1
|
2017-12-05 20:12:23 -07:00
|
|
|
fi
|
|
|
|
|
2017-12-31 09:02:12 -07:00
|
|
|
if [ ! "$1" ]; then
|
|
|
|
echo "Usage ./scripts/diagnostics <wireless_interface>"
|
|
|
|
exit 1
|
2017-08-20 19:51:10 -06:00
|
|
|
fi
|
|
|
|
|
|
|
|
echo "[ FLUXION Info ]"
|
2017-12-31 23:56:55 -07:00
|
|
|
if [ -f "./fluxion.sh" ]
|
|
|
|
then declare -r FLUXIONInfo=($(grep -oE "FLUXION(Version|Revision)=[0-9]+" fluxion.sh))
|
|
|
|
else declare -r FLUXIONInfo=($(grep -oE "FLUXION(Version|Revision)=[0-9]+" ../fluxion.sh))
|
|
|
|
fi
|
2017-08-20 19:51:10 -06:00
|
|
|
echo "FLUXION V${FLUXIONInfo[0]/*=/}.${FLUXIONInfo[1]/*=/}"
|
|
|
|
echo -ne "\n\n"
|
|
|
|
|
|
|
|
echo "[ BASH Info ]"
|
|
|
|
bash --version
|
2017-12-31 09:02:12 -07:00
|
|
|
echo "Path: $(ls -L $(which bash))"
|
2017-08-20 19:51:10 -06:00
|
|
|
echo -ne "\n\n"
|
|
|
|
|
|
|
|
echo "[ Interface ($1) Info ]"
|
2017-12-31 09:02:12 -07:00
|
|
|
if interface_physical "$1"; then echo "Device: $InterfacePhysical"
|
2017-08-20 19:51:10 -06:00
|
|
|
else echo "Device: Unknown"
|
|
|
|
fi
|
|
|
|
|
2017-12-31 09:02:12 -07:00
|
|
|
if interface_driver "$1"; then echo "Driver: $InterfaceDriver"
|
2017-08-20 19:51:10 -06:00
|
|
|
else echo "Driver: Unsupported"
|
|
|
|
fi
|
|
|
|
|
2017-12-31 09:02:12 -07:00
|
|
|
if interface_chipset "$1"; then echo "Chipset: $InterfaceChipset"
|
2017-08-20 19:51:10 -06:00
|
|
|
else echo "Chipset: Unknown"
|
|
|
|
fi
|
|
|
|
|
2017-08-27 02:15:18 -06:00
|
|
|
echo -n "Injection Test: "
|
|
|
|
aireplay-ng --test "$1" | grep -oE "Injection is working!|No Answer..." || echo "failed"
|
2017-08-20 19:51:10 -06:00
|
|
|
echo -ne "\n\n"
|
|
|
|
|
|
|
|
echo "[ XTerm Info ]"
|
2017-12-31 09:02:12 -07:00
|
|
|
echo "Version: $(xterm -version)"
|
|
|
|
echo "Path: $(ls -L $(which xterm))"
|
2017-08-27 14:06:01 -06:00
|
|
|
echo -n "Test: "
|
2017-12-31 09:02:12 -07:00
|
|
|
if xterm -hold -fg "#FFFFFF" -bg "#000000" -title "XServer/XTerm Test" -e "echo \"XServer/XTerm test: close window to continue...\"" &>/dev/null; then echo "XServer/XTerm success!"
|
|
|
|
else echo "XServer/XTerm failure!"
|
2017-08-27 14:06:01 -06:00
|
|
|
fi
|
2017-08-20 19:51:10 -06:00
|
|
|
echo -ne "\n\n"
|
|
|
|
|
|
|
|
echo "[ HostAPD Info ]"
|
|
|
|
hostapd -v
|
2017-12-31 09:02:12 -07:00
|
|
|
echo "Path: $(ls -L $(which hostapd))"
|
2017-08-20 19:51:10 -06:00
|
|
|
echo -ne "\n\n"
|
|
|
|
|
|
|
|
echo "[ Aircrack-ng Info ]"
|
|
|
|
aircrack-ng -H | head -n 4
|
|
|
|
echo -ne "\n\n"
|
|
|
|
|
|
|
|
echo "[ System Info ]"
|
2017-12-31 09:02:12 -07:00
|
|
|
if [ -r "/proc/version" ]; then cat /proc/version
|
2017-08-20 19:51:10 -06:00
|
|
|
else uname -r
|
|
|
|
fi
|