davidbombal / red-python-scripts

MIT License
2.04k stars 1.59k forks source link

wifi_dos_#.py cant detect second usb wifi adapter #22

Closed voklav closed 3 years ago

voklav commented 3 years ago

The script does not detect my second USB card. This is the output:

The following WiFi interfaces are available:
0 - wlan0
Please select the interface you want to use for the attack: ^CTraceback (most recent call last):
  File "/home/name/Desktop/wifi_dos_type1.py", line 101, in <module>
    wifi_interface_choice = input("Please select the interface you want to use for the attack: ")
KeyboardInterrupt

┌──(name㉿kali)-[~/Desktop]
└─$ iwconfig                                                                                                                                                                                  130 ⨯
lo        no wireless extensions.

eth0      no wireless extensions.

wlan0     IEEE 802.11  ESSID:off/any  
          Mode:Managed  Access Point: Not-Associated   Tx-Power=22 dBm   
          Retry short limit:7   RTS thr:off   Fragment thr:off
          Power Management:on

wlan1     IEEE 802.11  ESSID:off/any  
          Mode:Managed  Access Point: Not-Associated   Tx-Power=20 dBm   
          Retry short  long limit:2   RTS thr:off   Fragment thr:off
          Power Management:off
voklav commented 3 years ago

hi again. the solutions for me was to edit line 80: from: wlan_pattern = re.compile("^wlan[0-9]+") to: wlan_pattern = re.compile("wlan[0-9]")

this topic helped me:

The following WiFi interfaces are available:
0 - wlan0
1 - wlan1
Please select the interface you want to use for the attack: ^CTraceback 

I will personally try to add this command at the end of the script in the future: service NetworkManager restart