Skip to content

Commit

Permalink
Sync version 1.6 stage 3
Browse files Browse the repository at this point in the history
  • Loading branch information
samdenty committed Aug 8, 2017
1 parent fa6ce63 commit 8303378
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 22 deletions.
4 changes: 2 additions & 2 deletions arduino/Wi-PWN/APScan.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ void APScan::sendResults() {
json += "\"r\":" + (String)getAPRSSI(i) + ",";
json += "\"e\":" + (String)encryption[i] + ",";
//json += "\"v\":\""+getAPVendor(i)+"\",";
json += "\"se\":" + (String)getAPSelected(i);
json += "\"se\":" + (String)isSelected(i);
json += "}";
if ((i != results - 1) && (i != maxAPScanResults - 1)) json += ",";

Expand Down Expand Up @@ -215,7 +215,7 @@ String APScan::getResultsJSON() {
json += "\"r\":" + (String)getAPRSSI(i) + ",";
json += "\"e\":" + (String)encryption[i] + ",";
//json += "\"v\":\""+getAPVendor(i)+"\",";
json += "\"se\":" + (String)getAPSelected(i);
json += "\"se\":" + (String)isSelected(i);
json += "}";
if ((i != results - 1) && (i != maxAPScanResults - 1)) json += ",";
}
Expand Down
9 changes: 4 additions & 5 deletions arduino/Wi-PWN/Settings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,6 @@ void Settings::reset() {
attackTimeout = 0;
attackPacketRate = 10;
clientScanTime = 15;
attackEncrypted = true;
useLed = true;
channelHop = false;
multiAPs = true;
Expand All @@ -136,7 +135,7 @@ void Settings::reset() {
detectorScanTime = 200;
pins = "000000";
pinNames = "Pin 3;Pin 4;Pin 5;Pin 6;Pin 7;Pin 8";
if (debug) Serial.println("done");
if (debug) Serial.println("Reset complete!");

save();
}
Expand Down Expand Up @@ -188,7 +187,7 @@ void Settings::save() {
for (int i = 0; i < pinNamesLen; i++) EEPROM.write(pinNamesAdr + i, pinNames[i]);
EEPROM.commit();

int i=0;
/*int i=0;
int pinNumber = 3;
Serial.println("START");
while (i < 6)
Expand All @@ -200,7 +199,7 @@ void Settings::save() {
Serial.println((String)pinNumber + (String)": " + pinState);
pinNumber++;
}
Serial.println("END");
Serial.println("END");*/

if (debug) {
info();
Expand All @@ -218,7 +217,7 @@ void Settings::info() {
Serial.println(" Interface : dark-mode='" + (String)darkMode + "'\t\t| new-user='" + (String)newUser + "'\t\t\t| cache='" + (String)cache + "'");
Serial.println(" LED Indicator : enable='" + (String)useLed + "'\t\t\t| pin='" + (String)ledPin + "'\t\t\t|");
Serial.println(" MAC AP : default='" + defaultMacAP.toString()+"'\t| saved='" + macAP.toString()+"'\t| random='" + (String)isMacAPRand + "'");
Serial.println(" Beacons : mac-change-interval='" + (String)multiAttacks + "'\t| " + "WPA2='" + (String)attackEncrypted + "'\t\t\t| 1s-interval='" + (String)beaconInterval + "");
Serial.println(" Beacons : mac-change-interval='" + (String)multiAttacks + "'\t| " + "1s-interval='" + (String)beaconInterval + "");
Serial.println(" Deauth Detector : all-channels='" + (String)detectorAllChannels + "'\t\t| channel='" + (String)detectorChannel + "'\t\t\t| alert-pin='" + (String)alertPin + "'\t| invert-pin='" + (String)invertAlertPin + "'\t| scan-time='" + (String)detectorScanTime + "'");
Serial.println(" Other : channel-hopping='" + (String)channelHop + "'\t\t| multiple-aps='" + (String)multiAPs + "'\t\t| multiple-attacks='" + (String)multiAttacks + "'");
Serial.println(" PIN Control : state='" + (String)pins + "'\t\t| names='" + (String)pinNames + "'");
Expand Down
4 changes: 2 additions & 2 deletions arduino/Wi-PWN/Wi-PWN.ino
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* https://github.com/samdenty99/Wi-PWN *
* (c) 2017 Samuel Denty *
*----------------------------------------------*
* Wi-PWN based on spacehuhn/esp8266_deauther *
* Wi-PWN based on spacehuhn/esp8266_dseauther *
* (c) Stefan Kremser *
************************************************
*/
Expand Down Expand Up @@ -531,6 +531,7 @@ void getSettings() {
}

void saveSettings() {
server.send( 200, "text/json", "true" );
if (server.hasArg("ssid")) settings.ssid = server.arg("ssid");
if (server.hasArg("ssidHidden")) {
if (server.arg("ssidHidden") == "false") settings.ssidHidden = false;
Expand Down Expand Up @@ -652,7 +653,6 @@ void saveSettings() {
if (server.hasArg("pins")) settings.pins = server.arg("pins");

settings.save();
server.send( 200, "text/json", "true" );
}

void resetSettings() {
Expand Down
24 changes: 12 additions & 12 deletions arduino/Wi-PWN/data.h

Large diffs are not rendered by default.

Binary file modified pictures/secondary-banner.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion web_server/html/js/users.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ function getResults() {
if (res.clients[i].l >= 0) {
tr += '<td class="darken-on-hover" onclick="setName(' + res.clients[i].i + ')"><span class="a b">' + escapeHTML(res.clients[i].n) + '</span><br>' + escapeHTML(res.clients[i].v) +'</td>';
} else {
tr += '<td class="darken-on-hover" onclick="setName(' + res.clients[i].i + ')"><span class="a light-6">set name</span><br>' + escapeHTML(res.clients[i].v) + '</td>';
tr += '<td class="darken-on-hover" onclick="setName(' + res.clients[i].i + ')"><span class="a light-6">save</span><br>' + escapeHTML(res.clients[i].v) + '</td>';
}
tr += '<td onclick="select(' + res.clients[i].i + ')"><b>' + res.clients[i].m + '</b><br>' + escapeHTML(res.clients[i].a) + '</td>';
tr += '<td onclick="select(' + res.clients[i].i + ')">' + res.clients[i].p + '</td>';
Expand Down

0 comments on commit 8303378

Please sign in to comment.