Advertisement
FlyFar

WiFiSpam.sh

Jul 18th, 2023
3,745
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 4.29 KB | Cybersecurity | 0 0
  1. #!/bin/bash
  2.  
  3. # TERMINAL COLORS
  4. # https://github.com/1225K/terminal-colors
  5. NO_COLOR="\e[0m"
  6. WHITE="\e[0;17m"
  7. BOLD_WHITE="\e[1;37m"
  8. BLACK="\e[0;30m"
  9. BLUE="\e[0;34m"
  10. BOLD_BLUE="\e[1;34m"
  11. GREEN="\e[0;32m"
  12. BOLD_GREEN="\e[1;32m"
  13. CYAN="\e[0;36m"
  14. BOLD_CYAN="\e[1;36m"
  15. RED="\e[0;31m"
  16. BOLD_RED="\e[1;31m"
  17. PURPLE="\e[0;35m"
  18. BOLD_PURPLE="\e[1;35m"
  19. BROWN="\e[0;33m"
  20. BOLD_YELLOW="\e[1;33m"
  21. GRAY="\e[0;37m"
  22. BOLD_GRAY="\e[1;30m"
  23. # END OF TERMINAL COLORS
  24.  
  25. function coolexit() {
  26. clear
  27. ifconfig $AD down > /dev/null 2>&1
  28. macchanger -p $AD > /dev/null 2>&1
  29. iwconfig $AD mode managed > /dev/null 2>&1
  30. ifconfig $AD up > /dev/null 2>&1
  31. rm RANDOM_wordlist.txt > /dev/null 2>&1
  32. nmcli device connect $AD > /dev/null 2>&1
  33. clear
  34. title
  35. echo -e "$BOLD_RED   Thanks for using this script"
  36. echo -e "   My GitHub:$BOLD_WHITE https://github.com/125K"
  37. exit
  38. }
  39.  
  40. function title() {
  41. echo -e "$BOLD_GREEN    _       ___ _______    _____                     "
  42. echo "   | |     / (_) ____(_)  / ___/____  ____ _____ ___ "
  43. echo "   | | /| / / / /_  / /   \\__ \\/ __ \\/ __ \`/ __ \`__ \\"
  44. echo "   | |/ |/ / / __/ / /   ___/ / /_/ / /_/ / / / / / /"
  45. echo "   |__/|__/_/_/   /_/   /____/ .___/\\__,_/_/ /_/ /_/"
  46. echo "                            /_/                      "
  47. echo -e "$BOLD_WHITE                                           By 125K  "
  48. echo " "
  49. }
  50.  
  51. title
  52. sleep 1
  53. echo -e "$BOLD_GREEN   Your interfaces: "
  54. echo -e -n "$BOLD_WHITE"
  55. ifconfig | grep -e ": " | sed -e 's/: .*//g' | sed -e 's/^/   /'
  56. echo " "
  57. echo -n -e "$BOLD_BLUE   Type your wireless interface > "
  58. echo -n -e "$BOLD_WHITE"
  59. read AD
  60. clear
  61. title
  62. echo -e "$BOLD_BLUE  Choose an option:"
  63. echo " "
  64. echo -e "$BOLD_BLUE  1.$BOLD_WHITE Use the default word list (1000 SSIDs)"
  65. echo -e "$BOLD_BLUE  2.$BOLD_WHITE Create a custom word list and use it"
  66. echo -e "$BOLD_BLUE  3.$BOLD_WHITE Use an existent word list"
  67. echo -e "$BOLD_BLUE  4.$BOLD_WHITE Use a random SSIDs word list"
  68. echo " "
  69. echo -n -e "$BOLD_BLUE  > "
  70. echo -n -e "$BOLD_WHITE"
  71. read DD
  72. clear
  73. if [ $DD == 1 ]; then
  74.     nmcli device disconnect $AD > /dev/null 2>&1
  75.     clear
  76.     title
  77.     echo -e "$BOLD_GREEN Starting process..."
  78.     echo " If you want to stop it, press CTRL+C."
  79.     echo " "
  80.     trap coolexit EXIT
  81.     sleep 1
  82.     ifconfig $AD down
  83.     macchanger -r $AD
  84.     iwconfig $AD mode monitor
  85.     ifconfig $AD up
  86.     trap coolexit EXIT
  87.     mdk3 $AD b -f ./SSID_List.txt -a -s 1000
  88. fi
  89. if [ $DD == 2 ]; then
  90.     nmcli device disconnect $AD > /dev/null 2>&1
  91.     clear
  92.     title
  93.     echo -n -e "$BOLD_BLUE Type a string (Max. length: 12) > "
  94.     echo -n -e "$BOLD_WHITE"
  95.     read WORD
  96.     echo -n -e "$BOLD_BLUE How many SSIDs do you want? > "
  97.     echo -n -e "$BOLD_WHITE"
  98.     read N
  99.     COUNT=1
  100.     while [ $COUNT -lt $N ] || [ $COUNT -eq $N ]; do
  101.         echo $WORD $COUNT >> $WORD"_wordlist.txt"
  102.         let COUNT=COUNT+1
  103.     done
  104.     clear
  105.     title
  106.     echo -e "$BOLD_GREEN Starting process..."
  107.     echo " If you want to stop it, press CTRL+C."
  108.     echo " "
  109.     trap coolexit EXIT
  110.     sleep 1
  111.     ifconfig $AD down
  112.     macchanger -r $AD
  113.     iwconfig $AD mode monitor
  114.     ifconfig $AD up
  115.     trap coolexit EXIT
  116.     mdk3 $AD b -f ./$WORD"_wordlist.txt" -a -s 1000
  117. fi
  118. if [ $DD == 3 ]; then
  119.     nmcli device disconnect $AD > /dev/null 2>&1
  120.     clear
  121.     title
  122.     echo -e "$BOLD_WHITE Note: your word list must have the same structure as"
  123.     echo -e " SSID_List.txt, otherwise the process won't work."
  124.     echo " "
  125.     echo -n -e "$BOLD_BLUE Type the name of your own word list > "
  126.     echo -n -e "$BOLD_WHITE"
  127.     read OWN
  128.     clear
  129.     title
  130.     echo -e "$BOLD_GREEN Starting process..."
  131.     echo " If you want to stop it, press CTRL+C."
  132.     echo -e "$BOLD_WHITE"
  133.     sleep 1
  134.     ifconfig $AD down
  135.     macchanger -r $AD
  136.     iwconfig $AD mode monitor
  137.     ifconfig $AD up
  138.     trap coolexit EXIT
  139.     mdk3 $AD b -f ./$OWN -a -s $(wc -l $OWN | cut -f1 -d ' ')
  140. fi
  141. if [ $DD == 4 ]; then
  142.     nmcli device disconnect $AD > /dev/null 2>&1
  143.     clear
  144.     title
  145.     echo -n -e "$BOLD_BLUE How many SSIDs do you want? > "
  146.     echo -n -e "$BOLD_WHITE"
  147.     read N
  148.     COUNT=1
  149.     while [ $COUNT -lt $N ] || [ $COUNT -eq $N ]; do
  150.         echo $(pwgen 14 1) >> "RANDOM_wordlist.txt"
  151.         let COUNT=COUNT+1
  152.     done
  153.     clear
  154.     title
  155.     echo -e "$BOLD_GREEN Starting process..."
  156.     echo " If you want to stop it, press CTRL+C."
  157.     echo " "
  158.     sleep 1
  159.     ifconfig $AD down
  160.     macchanger -r $AD
  161.     iwconfig $AD mode monitor
  162.     ifconfig $AD up
  163.     trap coolexit EXIT
  164.     mdk3 $AD b -f ./RANDOM_wordlist.txt -a -s $N
  165. fi
Tags: spam wifi ssid
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement