Skip to content

Commit

Permalink
GoldHEN_v2.4b16.2 & PSFree Update
Browse files Browse the repository at this point in the history
  • Loading branch information
kmeps4 committed Feb 7, 2024
1 parent e85c01d commit 5bd14ec
Show file tree
Hide file tree
Showing 17 changed files with 47,044 additions and 16,417 deletions.
37 changes: 25 additions & 12 deletions ESP32_Server_900u/ESP32_Server_900u.ino
Original file line number Diff line number Diff line change
Expand Up @@ -17,43 +17,45 @@
#error "Selected board not supported"
#endif

// use PsFree [ true / false ]
#define PSFREE false // use the newer psfree webkit exploit.
// this is fairly stable but may fail which will require you to try and load the payload again.

// use SD Card [ true / false ]
// use SD Card [ true / false ]
#define USESD false // a FAT32 formatted SD Card will be used instead of the onboard flash for the storage. \
// this requires a board with a sd card slot or a sd card connected.

// use FatFS not SPIFFS [ true / false ]
#define USEFAT true // FatFS will be used instead of SPIFFS for the storage filesystem or for larger partitons on boards with more than 4mb flash. \
// use FatFS not SPIFFS [ true / false ]
#define USEFAT false // FatFS will be used instead of SPIFFS for the storage filesystem or for larger partitons on boards with more than 4mb flash. \
// you must select a partition scheme labeled with "FAT" or "FATFS" with this enabled.

// use LITTLEFS not SPIFFS [ true / false ]
#define USELFS false // LITTLEFS will be used instead of SPIFFS for the storage filesystem. \
// use LITTLEFS not SPIFFS [ true / false ]
#define USELFS true // LITTLEFS will be used instead of SPIFFS for the storage filesystem. \
// you must select a partition scheme labeled with "SPIFFS" with this enabled and USEFAT must be false.

// enable internal goldhen.h [ true / false ]
// enable internal goldhen.h [ true / false ]
#define INTHEN false // goldhen is placed in the app partition to free up space on the storage for other payloads. \
// with this enabled you do not upload goldhen to the board, set this to false if you wish to upload goldhen.

// enable autohen [ true / false ]
// enable autohen [ true / false ]
#define AUTOHEN false // this will load goldhen instead of the normal index/payload selection page, use this if you only want hen and no other payloads. \
// you can update goldhen by uploading the goldhen payload to the board storage with the filename "goldhen.bin".

// enable fan threshold [ true / false ]
// enable fan threshold [ true / false ]
#define FANMOD false // this will include a function to set the consoles fan ramp up temperature in °C \
// this will not work if the board is a esp32 and the usb control is disabled.




//-------------------DEFAULT SETTINGS------------------//

// use config.ini [ true / false ]
// use config.ini [ true / false ]
#define USECONFIG true // this will allow you to change these settings below via the admin webpage. \
// if you want to permanently use the values below then set this to false.

//create access point
boolean startAP = true;
String AP_SSID = "Kme900_Auto_ESP32S2";
String AP_SSID = "Kme_Auto_PSFree";
String AP_PASS = "123456789";
IPAddress Server_IP(10, 1, 1, 1);
IPAddress Subnet_Mask(255, 255, 255, 0);
Expand All @@ -74,7 +76,7 @@ int USB_WAIT = 5000;
String firmwareVer = "1.00";

//ESP sleep after x minutes
boolean espSleep = true;
boolean espSleep = false;
int TIME2SLEEP = 30; // minutes


Expand Down Expand Up @@ -514,6 +516,9 @@ void handleCacheManifest(AsyncWebServerRequest *request) {
if (!instr(output, "payloads.html\r\n")) {
output += "payloads.html\r\n";
}
if (!instr(output, "exploit.js\r\n")) {
output += "exploit.js\r\n";
}
if (!instr(output, "style.css\r\n")) {
output += "style.css\r\n";
}
Expand Down Expand Up @@ -934,6 +939,14 @@ void setup() {
request->send(response);
return;
}
#endif
#if PSFREE
if (path.endsWith("exploit.js")) {
AsyncWebServerResponse *response = request->beginResponse_P(200, "text/javascript", psf_gz, sizeof(psf_gz));
response->addHeader("Content-Encoding", "gzip");
request->send(response);
return;
}
#endif
if (path.endsWith("payloads.html")) {
#if AUTOHEN
Expand Down
2,415 changes: 1,644 additions & 771 deletions ESP32_Server_900u/Loader.h

Large diffs are not rendered by default.

20 changes: 20 additions & 0 deletions ESP32_Server_900u/data/constants.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/* Copyright (C) 2023 anonymous
This file is part of PSFree.
PSFree is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as
published by the Free Software Foundation, either version 3 of the
License, or (at your option) any later version.
PSFree is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <https://www.gnu.org/licenses/>. */

const KB = 1024;
const MB = KB * KB;
const GB = KB * KB * KB;

0 comments on commit 5bd14ec

Please sign in to comment.