save handshakes to predefined path

This commit is contained in:
strasharo 2016-03-18 02:43:32 +02:00
parent ef73ad35e2
commit c007574381
1 changed files with 13 additions and 4 deletions

17
fluxion
View File

@ -15,6 +15,7 @@ clear
##################################### < CONFIGURATION > ##################################### ##################################### < CONFIGURATION > #####################################
DUMP_PATH="/tmp/TMPflux" DUMP_PATH="/tmp/TMPflux"
HANDSHAKE_PATH="/root/handshakes"
# Deauth duration during handshake capture # Deauth duration during handshake capture
DEAUTHTIME="30" DEAUTHTIME="30"
revision=1 revision=1
@ -449,11 +450,17 @@ function checkdependences {
mostrarheader mostrarheader
checkdependences checkdependences
# Create Workbook # Create working directory
if [ ! -d $DUMP_PATH ]; then if [ ! -d $DUMP_PATH ]; then
mkdir $DUMP_PATH &>$flux_output_device mkdir -p $DUMP_PATH &>$flux_output_device
fi fi
# Create handshake directory
if [ ! -d $HANDSHAKE_PATH ]; then
mkdir -p $HANDSHAKE_PATH &>$flux_output_device
fi
if [ $FLUX_DEBUG != 1 ]; then if [ $FLUX_DEBUG != 1 ]; then
@ -2298,6 +2305,7 @@ function checkhandshake {
if [ "$handshakemode" = "normal" ]; then if [ "$handshakemode" = "normal" ]; then
if aircrack-ng $DUMP_PATH/$Host_MAC-01.cap | grep -q "1 handshake"; then if aircrack-ng $DUMP_PATH/$Host_MAC-01.cap | grep -q "1 handshake"; then
killall airodump-ng &>$flux_output_device killall airodump-ng &>$flux_output_device
wpaclean $HANDSHAKE_PATH/$Host_SSID-$Host_MAC.cap $DUMP_PATH/$Host_MAC-01.cap &>$flux_output_device
webinterface webinterface
break break
else else
@ -2308,13 +2316,14 @@ function checkhandshake {
if pyrit -r $DUMP_PATH/test.cap analyze 2>&1 | grep -q "good,"; then if pyrit -r $DUMP_PATH/test.cap analyze 2>&1 | grep -q "good,"; then
killall airodump-ng &>$flux_output_device killall airodump-ng &>$flux_output_device
pyrit -r $DUMP_PATH/test.cap -o $HANDSHAKE_PATH/$Host_SSID-$Host_MAC.cap strip &>$flux_output_device
webinterface webinterface
break break
else else
if aircrack-ng $DUMP_PATH/$Host_MAC-01.cap | grep -q "1 handshake"; then if aircrack-ng $DUMP_PATH/$Host_MAC-01.cap | grep -q "1 handshake"; then
Handshake_statuscheck="${yellow}Corrupt$transparent" Handshake_statuscheck="${yellow}Corrupted$transparent"
else else
Handshake_statuscheck="${red}Not_Found$transparent" Handshake_statuscheck="${red}Not_found$transparent"
fi fi
fi fi