Merge pull request #4700 from wled/secure-ota

Securing OTA update
This commit is contained in:
Blaž Kristan
2025-06-20 20:05:11 +02:00
committed by GitHub
7 changed files with 71 additions and 7 deletions

View File

@@ -740,6 +740,7 @@ bool deserializeConfig(JsonObject doc, bool fromFS) {
CJSON(aOtaEnabled, ota[F("aota")]);
#endif
getStringFromJson(otaPass, pwd, 33); //normally not present due to security
CJSON(otaSameSubnet, ota[F("same-subnet")]);
}
#ifdef WLED_ENABLE_DMX
@@ -1218,6 +1219,7 @@ void serializeConfig(JsonObject root) {
#ifndef WLED_DISABLE_OTA
ota[F("aota")] = aOtaEnabled;
#endif
ota[F("same-subnet")] = otaSameSubnet;
#ifdef WLED_ENABLE_DMX
JsonObject dmx = root.createNestedObject("dmx");