With modem.access_code in config.json, the monitor logs in to the
BGW320 (md5 of code + nonce, as its own page does) for two read-only
checks, stored in monitor_state.modem_checks:
- NAT sessions in use every 30 minutes; Needs attention warns at 80%.
- While UniFi says the internet is slow, a ping from the modem itself
to 1.1.1.1 (at most every 10 minutes). Compared with UniFi's latency
through the modem, it says whether the delay is past the modem (the
provider), in the modem, or gone. The Internet line in Needs
attention and the WAN / Fiber panel show the result.
A refused code is reported and not retried for 30 minutes; other
failures pause the checks for 10. The unauthenticated status polling
is unchanged. Tested against the real gateway and a fake one.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>