mirror of
https://github.com/rstrouse/ESPSomfy-RTS.git
synced 2026-10-31 22:02:17 +01:00
fix: drop Secure Config Only permissions from protocol 2
The socket has two modes, None and Secured (ADR 0006), and ignores the ConfigOnly bit, so the security section no longer reads or saves it. The HTTP routes keep it until step 4 removes the mode. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
096eef0581
commit
72e99d14c5
5 changed files with 8 additions and 4 deletions
|
|
@ -91,7 +91,8 @@ static void writeSettings(ProtoWriter &w, settings_section_t section) {
|
|||
w.add(proto_field_t::username, settings.Security.username);
|
||||
w.add(proto_field_t::hasPassword, hasSecret(settings.Security.password));
|
||||
w.add(proto_field_t::hasPin, hasSecret(settings.Security.pin));
|
||||
w.add(proto_field_t::permissions, settings.Security.permissions);
|
||||
// Not "Secure Config Only"'s permissions: the socket has two modes, None
|
||||
// and Secured (docs/adr/0006-two-security-modes-eleven-http-routes.md).
|
||||
break;
|
||||
case settings_section_t::radio: {
|
||||
const transceiver_config_t &cfg = somfy.transceiver.config;
|
||||
|
|
|
|||
|
|
@ -238,7 +238,6 @@
|
|||
FIELD(securityType, "sy", 'i', 0) \
|
||||
FIELD(pin, "pn", 's', 0) \
|
||||
FIELD(hasPin, "hi", 'b', 0) \
|
||||
FIELD(permissions, "pm", 'i', 0) \
|
||||
/* the radio: bitLength, proto, frequency and enabled as above */ \
|
||||
FIELD(TXPin, "tx", 'i', 0) \
|
||||
FIELD(RXPin, "rx", 'i', 0) \
|
||||
|
|
|
|||
|
|
@ -70,7 +70,6 @@ static const settings_field_t FIELDS[] = {
|
|||
{settings_part_t::security, proto_field_t::username, nullptr, 0, 32},
|
||||
{settings_part_t::security, proto_field_t::password, nullptr, 0, 32},
|
||||
{settings_part_t::security, proto_field_t::pin, nullptr, 0, 4},
|
||||
{settings_part_t::security, proto_field_t::permissions, nullptr, 0, 1},
|
||||
// 56 or 80, checked on its own.
|
||||
{settings_part_t::radio, proto_field_t::bitLength, "type", 56, 80},
|
||||
// RTS, RTW, RTV, GP Relay or GP Remote (radio_proto), checked on its own.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue