Skip to content

0.24.0: treat the manager as untrusted (security release) - #72

Merged
kaboomAE merged 5 commits into
mainfrom
security/0.24.0
Sep 28, 2026
Merged

kaboomAE merged 5 commits into
mainfrom
security/0.24.0

Conversation

@kaboomAE

Copy link
Copy Markdown
Owner

The fix for GHSA-vj2g-mxcr-wx5r, GHSA-4m4w-x5r5-hmvh, GHSA-rwhg-fxhq-m6pg, GHSA-v9pc-vw88-p798, GHSA-qj62-wg85-79cv, GHSA-mqpf-x42g-g28w, GHSA-88r5-5vxg-53px, GHSA-cvj4-75mr-7858, GHSA-qx58-m2pf-8388 and GHSA-hrm5-cvxj-cc7w, developed and reviewed in the advisories' private fork and released now on the owner's go. The rules it enforces are in docs/trust-boundary.md; the regression tests in tests/test_untrusted_manager.py. Also retires tunnel_setup (Dartec Link replaces it).

Tested: 1036 unit tests; live Home Assistant 2026.9.2 and 2026.8.3 (main, household, panels) run locally.

🤖 Generated with Claude Code

The agent must hold even if the manager, or anything impersonating it, is
hostile. Fixes the ten draft advisories from the 2026-09-27 review, and the
two further instances of the same class found while fixing them.

- URLs: backup uploads and media downloads only to manager.dartec.ae over
  https; redirects refused on the streamed upload and re-checked hop by hop
  on downloads; Dartec Link only joins https://headscale.dartec.ae, rebuilt
  from the allowlist (GHSA-v9pc-vw88-p798, GHSA-mqpf-x42g-g28w,
  GHSA-hrm5-cvxj-cc7w).
- Sizes: media capped at 20 MB and backups at 4096 MB whatever the command
  asks, enforced on the bytes read or sent (GHSA-88r5-5vxg-53px).
- Ids: automation ids, add-on slugs, backup ids and backup agents match
  strict patterns before they reach a path (GHSA-qj62-wg85-79cv, plus
  addon_slug and backup_id).
- Targets: entity_id is split the way Home Assistant splits it, every entry
  checked, and the call made with the checked list (GHSA-vj2g-mxcr-wx5r).
- Consent: scene.turn_on and automation.turn_on/turn_off are sensitive
  (GHSA-4m4w-x5r5-hmvh, GHSA-rwhg-fxhq-m6pg); only an administrator can
  grant consent, anyone can withdraw it (GHSA-qx58-m2pf-8388); Link and
  tunnel setup ask again after installing.
- Household: create, update and remove are serialised, so two
  administrators cannot remove each other (GHSA-cvj4-75mr-7858).

trust.py holds the allowlists and patterns; docs/trust-boundary.md the rules
for new commands; tests/test_untrusted_manager.py one regression per
advisory, each failing on 0.23.0.
A refused URL, id, size or ended consent inside a handler now gets the same
'Refused remote command' logbook line as a dispatcher refusal, instead of
the 'Dartec ran ...' line sensitive actions get.
The owner's decision, 2026-09-27. The tunnel published a home's login page
on the internet through whichever Cloudflare account the token in the
command belonged to, and nothing on the home could check that. tunnel_setup
is removed and refused by name (service_policy.RETIRED_ACTIONS, code
'retired') before consent is read, so no window brings it back.
tunnel_status and tunnel_stop remain, to find and take down an existing
tunnel.
@kaboomAE
kaboomAE merged commit 5089d79 into main Sep 28, 2026
29 of 30 checks passed
@kaboomAE
kaboomAE deleted the security/0.24.0 branch September 28, 2026 02:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant