Removed remnants of forcePackets setting
The setting was already removed in 2019 with the rewrite of the settings module. In my tests, it didn't make the performance better, but added complexity and made the web interface unstable.
This commit is contained in:
parent
abf56ca866
commit
333e3ebd86
|
@ -303,7 +303,7 @@ bool Attack::deauthDevice(uint8_t* apMac, uint8_t* stMac, uint8_t reason, uint8_
|
||||||
// send deauth frame
|
// send deauth frame
|
||||||
deauthpkt[0] = 0xc0;
|
deauthpkt[0] = 0xc0;
|
||||||
|
|
||||||
if (sendPacket(deauthpkt, packetSize, ch, 1, true)) {
|
if (sendPacket(deauthpkt, packetSize, ch, true)) {
|
||||||
success = true;
|
success = true;
|
||||||
deauth.packetCounter++;
|
deauth.packetCounter++;
|
||||||
}
|
}
|
||||||
|
@ -315,7 +315,7 @@ bool Attack::deauthDevice(uint8_t* apMac, uint8_t* stMac, uint8_t reason, uint8_
|
||||||
|
|
||||||
disassocpkt[0] = 0xa0;
|
disassocpkt[0] = 0xa0;
|
||||||
|
|
||||||
if (sendPacket(disassocpkt, packetSize, ch, 1, false)) {
|
if (sendPacket(disassocpkt, packetSize, ch, false)) {
|
||||||
success = true;
|
success = true;
|
||||||
deauth.packetCounter++;
|
deauth.packetCounter++;
|
||||||
}
|
}
|
||||||
|
@ -330,7 +330,7 @@ bool Attack::deauthDevice(uint8_t* apMac, uint8_t* stMac, uint8_t reason, uint8_
|
||||||
// send deauth frame
|
// send deauth frame
|
||||||
disassocpkt[0] = 0xc0;
|
disassocpkt[0] = 0xc0;
|
||||||
|
|
||||||
if (sendPacket(disassocpkt, packetSize, ch, 1, false)) {
|
if (sendPacket(disassocpkt, packetSize, ch, false)) {
|
||||||
success = true;
|
success = true;
|
||||||
deauth.packetCounter++;
|
deauth.packetCounter++;
|
||||||
}
|
}
|
||||||
|
@ -338,7 +338,7 @@ bool Attack::deauthDevice(uint8_t* apMac, uint8_t* stMac, uint8_t reason, uint8_
|
||||||
// send disassociate frame
|
// send disassociate frame
|
||||||
disassocpkt[0] = 0xa0;
|
disassocpkt[0] = 0xa0;
|
||||||
|
|
||||||
if (sendPacket(disassocpkt, packetSize, ch, 1, false)) {
|
if (sendPacket(disassocpkt, packetSize, ch, false)) {
|
||||||
success = true;
|
success = true;
|
||||||
deauth.packetCounter++;
|
deauth.packetCounter++;
|
||||||
}
|
}
|
||||||
|
@ -383,7 +383,7 @@ bool Attack::sendBeacon(uint8_t* mac, const char* ssid, uint8_t ch, bool wpa2) {
|
||||||
tmpPacket[37] = ssidLen; // update SSID length byte
|
tmpPacket[37] = ssidLen; // update SSID length byte
|
||||||
memcpy(&tmpPacket[38 + ssidLen], &beaconPacket[70], wpa2 ? 39 : 13); // copy second half of packet into buffer
|
memcpy(&tmpPacket[38 + ssidLen], &beaconPacket[70], wpa2 ? 39 : 13); // copy second half of packet into buffer
|
||||||
|
|
||||||
bool success = sendPacket(tmpPacket, tmpPacketSize, ch, 1, false);
|
bool success = sendPacket(tmpPacket, tmpPacketSize, ch, false);
|
||||||
|
|
||||||
if (success) {
|
if (success) {
|
||||||
beacon.time = currentTime;
|
beacon.time = currentTime;
|
||||||
|
@ -411,7 +411,7 @@ bool Attack::sendProbe(uint8_t* mac, const char* ssid, uint8_t ch) {
|
||||||
memcpy(&probePacket[10], mac, 6);
|
memcpy(&probePacket[10], mac, 6);
|
||||||
memcpy(&probePacket[26], ssid, ssidLen);
|
memcpy(&probePacket[26], ssid, ssidLen);
|
||||||
|
|
||||||
if (sendPacket(probePacket, packetSize, ch, 1, false)) {
|
if (sendPacket(probePacket, packetSize, ch, false)) {
|
||||||
probe.time = currentTime;
|
probe.time = currentTime;
|
||||||
probe.packetCounter++;
|
probe.packetCounter++;
|
||||||
return true;
|
return true;
|
||||||
|
@ -420,7 +420,7 @@ bool Attack::sendProbe(uint8_t* mac, const char* ssid, uint8_t ch) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool Attack::sendPacket(uint8_t* packet, uint16_t packetSize, uint8_t ch, uint16_t tries, bool force_ch) {
|
bool Attack::sendPacket(uint8_t* packet, uint16_t packetSize, uint8_t ch, bool force_ch) {
|
||||||
// Serial.println(bytesToStr(packet, packetSize));
|
// Serial.println(bytesToStr(packet, packetSize));
|
||||||
|
|
||||||
// set channel
|
// set channel
|
||||||
|
@ -429,10 +429,7 @@ bool Attack::sendPacket(uint8_t* packet, uint16_t packetSize, uint8_t ch, uint16
|
||||||
// sent out packet
|
// sent out packet
|
||||||
bool sent = wifi_send_pkt_freedom(packet, packetSize, 0) == 0;
|
bool sent = wifi_send_pkt_freedom(packet, packetSize, 0) == 0;
|
||||||
|
|
||||||
// try again until it's sent out
|
if (sent) ++tmpPacketRate;
|
||||||
for (int i = 0; i < tries && !sent; i++) sent = wifi_send_pkt_freedom(packet, packetSize, 0) == 0;
|
|
||||||
|
|
||||||
if (sent) tmpPacketRate++;
|
|
||||||
|
|
||||||
return sent;
|
return sent;
|
||||||
}
|
}
|
||||||
|
|
|
@ -56,7 +56,7 @@ class Attack {
|
||||||
bool sendProbe(uint8_t tc);
|
bool sendProbe(uint8_t tc);
|
||||||
bool sendProbe(uint8_t* mac, const char* ssid, uint8_t ch);
|
bool sendProbe(uint8_t* mac, const char* ssid, uint8_t ch);
|
||||||
|
|
||||||
bool sendPacket(uint8_t* packet, uint16_t packetSize, uint8_t ch, uint16_t tries, bool force_ch);
|
bool sendPacket(uint8_t* packet, uint16_t packetSize, uint8_t ch, bool force_ch);
|
||||||
|
|
||||||
bool isRunning();
|
bool isRunning();
|
||||||
|
|
||||||
|
|
|
@ -1079,7 +1079,7 @@ void CLI::runCommand(String input) {
|
||||||
for (int i = 0; i < packetSize; i++) packet[i] = strtoul((packetStr.substring(i * 2,
|
for (int i = 0; i < packetSize; i++) packet[i] = strtoul((packetStr.substring(i * 2,
|
||||||
i * 2 + 2)).c_str(), NULL, 16);
|
i * 2 + 2)).c_str(), NULL, 16);
|
||||||
|
|
||||||
if (attack.sendPacket(packet, packetSize, wifi_channel, 10, true)) {
|
if (attack.sendPacket(packet, packetSize, wifi_channel, true)) {
|
||||||
prntln(CLI_CUSTOM_SENT);
|
prntln(CLI_CUSTOM_SENT);
|
||||||
counter++;
|
counter++;
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -23,7 +23,6 @@
|
||||||
- [`chTime`](#ch-time)
|
- [`chTime`](#ch-time)
|
||||||
- [`minDeauths`](#mindeauths)
|
- [`minDeauths`](#mindeauths)
|
||||||
- [`attackTimeout`](#attacktimeout)
|
- [`attackTimeout`](#attacktimeout)
|
||||||
- [`forcePackets`](#force-packets)
|
|
||||||
- [`deauthsPerTarget`](#deauths-per-target)
|
- [`deauthsPerTarget`](#deauths-per-target)
|
||||||
- [`deauthReason`](#deauth-reason)
|
- [`deauthReason`](#deauth-reason)
|
||||||
- [`beaconChannel`](#beacon-channel)
|
- [`beaconChannel`](#beacon-channel)
|
||||||
|
@ -132,13 +131,6 @@ Minimum number of deauthentication frames when scanning to change the LED to dea
|
||||||
After what amount of time (in seconds) the attack will stop automatically.
|
After what amount of time (in seconds) the attack will stop automatically.
|
||||||
Set it to 0 to disable it.
|
Set it to 0 to disable it.
|
||||||
|
|
||||||
## FORCE-PACKETS
|
|
||||||
`uint8_t forcePackets = 1;`
|
|
||||||
How many attempts to send out a packet.
|
|
||||||
Set this value higher if you want to achieve a better packet rate in a busy area.
|
|
||||||
Be careful this setting could make the device slower or more unstable.
|
|
||||||
**Max value is 255**.
|
|
||||||
|
|
||||||
## DEAUTHS-PER-TARGET
|
## DEAUTHS-PER-TARGET
|
||||||
`uint16_t deauthsPerTarget = 10;`
|
`uint16_t deauthsPerTarget = 10;`
|
||||||
How many deauthentication and disassociation frames are sent out for each target.
|
How many deauthentication and disassociation frames are sent out for each target.
|
||||||
|
|
|
@ -1,30 +1,29 @@
|
||||||
{
|
{
|
||||||
"version":"over9000",
|
"version": "over9000",
|
||||||
"ssid":"pwned",
|
"ssid": "pwned",
|
||||||
"password":"deauther",
|
"password": "deauther",
|
||||||
"channel":1,
|
"channel": 1,
|
||||||
"hidden":false,
|
"hidden": false,
|
||||||
"captivePortal":true,
|
"captivePortal": true,
|
||||||
"lang": "en",
|
"lang": "en",
|
||||||
"autosave":true,
|
"autosave": true,
|
||||||
"autosavetime":30000,
|
"autosavetime": 30000,
|
||||||
"display":false,
|
"display": false,
|
||||||
"displayTimeout":600,
|
"displayTimeout": 600,
|
||||||
"serial":true,
|
"serial": true,
|
||||||
"serialEcho":true,
|
"serialEcho": true,
|
||||||
"web":true,
|
"web": true,
|
||||||
"led":true,
|
"led": true,
|
||||||
"maxch":14,
|
"maxch": 14,
|
||||||
"macSt":"aa:bb:cc:dd:ee:ff",
|
"macSt": "aa:bb:cc:dd:ee:ff",
|
||||||
"macAP":"00:11:22:33:44:55",
|
"macAP": "00:11:22:33:44:55",
|
||||||
"chtime":384,
|
"chtime": 384,
|
||||||
"minDeauths":3,
|
"minDeauths": 3,
|
||||||
"attacktimeout":600,
|
"attacktimeout": 600,
|
||||||
"forcepackets":3,
|
"deauthspertarget": 20,
|
||||||
"deauthspertarget":20,
|
"deauthReason": 1,
|
||||||
"deauthReason":1,
|
"beaconchannel": false,
|
||||||
"beaconchannel":false,
|
"beaconInterval": false,
|
||||||
"beaconInterval":false,
|
"randomTX": false,
|
||||||
"randomTX":false,
|
"probesPerSSID": 1
|
||||||
"probesPerSSID":1
|
|
||||||
}
|
}
|
Loading…
Reference in New Issue