mirror of
https://github.com/agessaman/MeshCore.git
synced 2026-09-09 01:05:12 +00:00
A provision file is a plain-text list of CLI commands under a '#meshcore-provision v1' header, stored as /provision. Each line runs through CommonCLI::handleCommand() with the invoker's privileges, so validation and persistence match typing the commands; no persisted struct layout is touched. - provision / show / apply / remove on all builds - provision begin/end: serial-only paste capture (the file-creation path for non-WiFi builds) - provision fetch <url> [insecure]: HTTPS download on WITH_MQTT_BRIDGE builds, validated against the bundled CA roots; stores only, never auto-applies, and never clobbers /provision with an invalid file - boot auto-apply at the end of begin() in simple_repeater and simple_room_server, with serial privileges, then reboot; the /provision_done marker is written before the run so a bad file can never cause a reboot loop - blocklist (erase, start ota, ota, password, set prv.key, reboot/ clkreboot/poweroff/shutdown, region load, provision) enforced on every apply path; _mqtt_prefs_hold refuses the whole file - 4KB file cap, 159-char line cap, unknown/invalid lines counted and skipped (forward-compatible)