Skip to content

Commit

Permalink
Check if MQTT remote IP is private (#5627)
Browse files Browse the repository at this point in the history
  • Loading branch information
esev authored Dec 21, 2024
1 parent 5fed679 commit 9a10907
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/mqtt/MQTT.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -438,6 +438,9 @@ void MQTT::reconnect()
enabled = true; // Start running background process again
runASAP = true;
reconnectCount = 0;
#if !defined(ARCH_PORTDUINO)
isMqttServerAddressPrivate = isPrivateIpAddress(mqttClient.remoteIP());
#endif

publishNodeInfo();
sendSubscriptions();
Expand Down

0 comments on commit 9a10907

Please sign in to comment.