149 Commits
Author SHA1 Message Date
MrAlders0n f93983cea0 feat(mcp): add an optional read-only MCP endpoint
Serves the public read API to AI assistants at /mcp. Off by default;
private when mcp.keys are set, public otherwise. Tools call the REST
handlers in-process, so validation, guards and errors match REST.
2026-12-02 12:24:54 -05:00
MrAlders0n 8a194e337e chore: bump version to 2.3.4 2026-11-29 22:50:43 -05:00
MrAlders0n 455532288d chore: bump version to 2.3.3 2026-11-29 18:03:05 -05:00
MrAlders0n d9158125fb chore: bump version to 2.3.2 2026-11-29 13:28:21 -05:00
MrAlders0n c0ad27d7aa feat(mail): add mail.tls_skip_verify for servers with untrusted certificates 2026-11-29 10:41:23 -05:00
MrAlders0n 93e884f7eb chore: bump version to 2.3.1 2026-11-28 22:42:02 -05:00
MrAlders0n c7cc6bc45a feat(ingest): name a broker connection with MQTT_BROKER_n_NAME
The name is stored and shown wherever mqtt1 and mqtt2 were: packet
brokers, observer brokers, the broker filter and /brokers. Unset keeps
the old names.
2026-11-28 22:28:55 -05:00
MrAlders0n f9a204e35e fix(polling): close the gaps review found in foreign claims
Whether a claim may replace what an observer has stored, own or
foreign, is now decided in one place under the observer's seat lock: an
older claim never undoes a newer one, the claim spacing holds across
both kinds, and an unsigned claim is refused while a signed one is
live. An observer that turns foreign loses every assignment in the same
transaction, requested ones its claim does not name included.

A server that starts checking drops the claims that were not placed
under its current host and broker list. A foreign reading never counts
as a repeater's newest; one from an observer this server assigned the
target stays its own; with authority approved it needs approval to be
trusted. A null sig or poll_url is refused. A packet's broker set only
grows. The foreign reading lookups get a partial index (093), the
MQTT 5 connected flag follows the current connection only, and queued
messages are charged for their source.
2026-11-28 20:49:32 -05:00
MrAlders0n ff8637b4ab feat(polling): tell this server's observers from foreign ones
polling.foreign_claims: check takes a claim as this server's own only
when its signed poll_url names DOMAIN, or, for firmware that sends
none, when a rebroadcaster says it arrived on one of polling.mqtt_hosts.
Any other claim is foreign, and one that can be placed neither way is
dropped. The default, off, treats every claim as its own, as before.

A foreign observer is kept out of polling_claims, so it is never a
poller or standby, gets no owners answer and takes no request. Its
readings are stored, marked foreign and trusted on the same advert
evidence. A reading with no claim behind it is kept as foreign too.

Claims that carry a signature are verified with the observer's key in
every mode; a wrong one is dropped. Asking for telemetry on a repeater
a foreign observer already checks needs acknowledgeForeign.
2026-11-28 20:32:20 -05:00
MrAlders0n f360fbe8db feat(ingest): read source brokers from a rebroadcaster over MQTT 5
MQTT_BROKER_n_REBROADCAST=true marks a broker that forwards from other
brokers and names each message's source in the source-broker and
source-host user properties. The worker then connects with MQTT 5 and
records packets, observations and observer brokers under the source
name. Without it the connection is 3.1.1 as before.

Each packet keeps the set of brokers it arrived through (brokers on
packet detail). Observer broker lists and the broker filter cover the
last 30 days, and GET /brokers/sources lists the names for the filter.
2026-11-28 20:15:44 -05:00
MrAlders0n 69ed88b6f5 feat(config)!: take the public address from DOMAIN, drop accounts.public_url
The server now reads DOMAIN, and WEB_DOMAIN when the web app is on
another host, for mailed links and the portal callback. A leftover
accounts.public_url is ignored with a startup warning.

Release note for the next production release: accounts.public_url is
removed and no longer needed. Accounts need DOMAIN in the server's
environment; the Docker stacks already set it. Docs need the same
update.
2026-11-28 20:01:21 -05:00
MrAlders0n 2ae10ca1a5 revert: foreign polling claims, until the design is settled 2026-11-28 16:54:58 -05:00
MrAlders0n 306128a4bd feat(polling): rank observers that follow another server behind our own
A claim can reach a server its observer does not ask for policy. Tell
them apart by the claim's poll_url, or by whether the observer asked
this server lately, and keep such observers out of requests.
2026-11-28 16:26:43 -05:00
MrAlders0n 47e6783ce7 feat(polling): trust self-configured readings without adverts, evidence_window setting
Readings of a repeater an observer polls on its own were hidden unless it heard a zero-hop advert in the last 24h. They are now trusted while no assignee of that repeater has advert evidence. The window is polling.evidence_window, default 7d.
2026-11-27 08:02:29 -05:00
MrAlders0n 09ef3f60e6 fix(ingest): store observer reboots at once, default telemetry resolution to 15m
One snapshot an hour held a reboot alert back by up to an hour and could hide
a reboot whose uptime had grown past the last stored one.
2026-11-27 07:20:35 -05:00
MrAlders0n d376cb84a7 fix(polling): expire old claims and readings with polling off
The cleanup only ran with polling on, so Poller tags from an earlier run never cleared.
2026-11-26 21:46:06 -05:00
MrAlders0n 8e01a3049a fix(alerts): name the configured push server at startup and flag the retired credentials variable 2026-11-18 06:28:08 -05:00
MrAlders0n 90c2ece473 feat(alerts): email and push channels through the push server
Alerts go out by email, by push or both, as each user chooses. Push is
sent through the push server with the operator's Push ID and secret and
sealed per device, so this server no longer holds a Firebase key. The
outbox tracks each channel, so a retry of one never repeats the other.
2026-11-17 20:22:51 -05:00
MrAlders0n cf14a67c04 chore: bump version to 2.3.0 2026-11-17 03:01:50 -05:00
MrAlders0n cdb581e9da feat(config): make the Atlas cap configurable, default 20, and raise requests per user to 6 2026-11-16 21:23:30 -05:00
MrAlders0n 94360381d9 Write alert temperatures in the instance unit 2026-11-15 20:18:04 -05:00
MrAlders0n 31d2cf5dc2 Add display unit config and serve it in info 2026-11-15 20:13:00 -05:00
MrAlders0n ac9c82a331 Name the instance in account and alert mail 2026-11-15 16:23:55 -05:00
MrAlders0n 39c10bb406 Stop repeater telemetry alerts when polling is off 2026-11-15 08:09:29 -05:00
MrAlders0n 5e8376581d Mark alert mail delivered after it is sent 2026-11-15 03:07:23 -05:00
MrAlders0n df23af3e33 Test portal sign-in end to end 2026-11-15 02:08:27 -05:00
MrAlders0n 2a21b1401f Refuse alert delivery settings that cannot send 2026-11-15 02:07:57 -05:00
MrAlders0n 22b10d18d5 Deliver alerts by email or push 2026-11-15 02:02:21 -05:00
MrAlders0n 6fa5e2c13e Evaluate alert rules 2026-11-15 01:56:20 -05:00
MrAlders0n 26ccf6d4db Add alert rules and device registration 2026-11-15 01:48:15 -05:00
MrAlders0n 35468cc7cc Add sign-in through the MeshMapper portal 2026-11-15 01:40:24 -05:00
MrAlders0n c34a20f2a5 Assign requested repeaters to observers 2026-11-15 00:56:28 -05:00
MrAlders0n 1c51a6b77d Add telemetry request storage and routes 2026-11-15 00:41:16 -05:00
MrAlders0n 49ea5e04e8 Add account Atlas storage and routes 2026-11-14 23:52:28 -05:00
MrAlders0n 81e7950705 Wire accounts into startup and add operator user management 2026-11-14 23:41:56 -05:00
MrAlders0n 2af2c5bad1 Add sign-in, account and session routes 2026-11-14 23:36:29 -05:00
MrAlders0n b58634d791 Add accounts config, mail sender and feature flags 2026-11-14 22:41:23 -05:00
MrAlders0n 87009f395a Add node polling endpoint and feature flags to info 2026-11-14 21:56:23 -05:00
MrAlders0n 7ab2c3ffba Allow single IATA codes in the ingest filter 2026-11-14 21:04:39 -05:00
MrAlders0n 630f63cfb5 Refuse polling exclusions that do not fit with config and show config in admin 2026-11-14 14:55:38 -05:00
MrAlders0n 9ee27f29be Validate polling min_client_version and tidy polling tests and comments 2026-11-14 14:26:27 -05:00
MrAlders0n 4495e1c648 Add admin view of polling targets and show the effective pause 2026-11-14 14:21:45 -05:00
MrAlders0n 7fd896c507 Add polling end to end test 2026-11-14 13:42:39 -05:00
MrAlders0n 7ada6b8c5c Wire polling into startup, jobs and admin 2026-11-14 13:35:49 -05:00
MrAlders0n 088850c9d6 chore: bump version to v2.2.0 2026-11-10 19:37:53 -05:00
MrAlders0n 19f0b20a20 chore: bump version to v2.1.1 2026-10-31 15:27:14 -04:00
MrAlders0n 2021d2c306 feat(ws): optionally require an Origin or a server-issued ticket on /ws 2026-10-31 14:43:18 -04:00
MrAlders0n a39a830955 feat(ws): add a per-connection send budget and cap IPv6 per /64 2026-10-31 14:27:54 -04:00
MrAlders0n 80255119c1 perf(observers): serve the 24-hour activity chart from memory
The 24-hour observer chart (15-minute buckets) read every raw observation
of the day twice, once for the buckets and once for the type mix: 4.5 s
for a busy observer on prod, and the apps poll it every minute. It now
reads them in one pass, and the process that ingests keeps per-observer
15-minute sums of what it stores (25 hours), so the chart only reads raw
rows before counting began and for the slot still filling. Results match
the raw read exactly (integration test), including after retention
deletes.
2026-10-28 22:30:52 -04:00
MrAlders0n bbc964fd2f perf(observers): count unrolled hours in memory for the directory
The directory re-read every raw observation of the hours not yet
rolled up: on prod about 293k rows for the open hour, a heap page each
(new rows land wherever cleanup freed space), 7 of the 8 s an
all-regions request took. The ingesting process now also counts each
stored observation per minute, observer and IATA, and the directory
adds those up for hours wholly counted, reading raw rows only for the
last partial minute. Partial or cleanup-thinned hours and processes
that don't ingest read raw rows as before; results are identical (an
integration test compares both paths).
2026-10-27 15:18:13 -04:00