Skip to content

0.0.17: the packaged service starts without a PC activation record (J162) #1205

Closed

Description

@jparker2006

Parent

A small-road fix under #1052 (0.0.17), approved by Jake as J162 (ruling on ClosedWiz #3065, private record https://github.com/jparker2006/ClosedWiz/issues/3065#issuecomment-7000141766). It ships before 0.0.17.

What to build

The packaged openwiz-service can never start. Its start gate (crates/service/src/bootstrap.rs) refuses every packaged start without setup/pc-activation.json, a PC activation record that nothing writes any more (#1052's trace). So a fresh install has a web view only while the installer's foreground launcher runs, and no persistent service.

Change the gate to the checks that still mean something: the installed package verifies against its install manifest (the existing manifest, verify and path guards); the running executable belongs to that package; the state and install paths are owner-private; and login is unknown, which is allowed. Drop the activation-record requirement. Add no runtime, environment, configuration or network path, and no bypass of any kind. A tampered or unowned package still refuses to start.

Owned paths

  • crates/service/src/bootstrap.rs (the packaged start gate)
  • crates/service/src/lib.rs (shared: only the gate's call, if it changes)
  • tests/service/t4_setup.rs (shared: the gate's cases)
  • tools/release/test_package.py (shared: the packaged start-gate test, which today asserts the gate stays closed)
  • contracts/install.v1.md (shared: only lines that describe activation or the handover owning it, worded to match)
  • changes/<this ticket>.md

Relies on: contracts/install.v1.md

Links

none

Acceptance criteria

  • Red first: a fresh packaged install from a verified bundle, with no activation record, starts the installed openwiz-service and serves the web view's /. On today's main it refuses with "Activation remains closed", and that run is retained
  • A package whose install manifest is missing or doesn't match, an executable from outside the package, and non-owner-private paths each still refuse, red first where a case is new
  • Login unknown doesn't block the start
  • No new runtime, environment variable, configuration switch or network path, and no bypass; the PR states this, and the reviewer checks it
  • The packaged start-gate test in tools/release/test_package.py asserts the new behaviour: starts when valid, refuses when tampered. It isn't deleted
  • One changelog line, kind fixed
  • Test rule (The test rule: what earns a test, and what never does #687): every new test protects a supported behaviour, a contract others rely on or a safety invariant, and the pull request says per test catches: <the bug>, or no new test: <why>. No mock-returns-stub, source mirroring, compiler re-checks, quota tests or unreachable cases; a bug gets a failing test first.
  • Every test the pull request deletes names its keeper (a test that still catches its bug) or says the behaviour it protected is gone.

Proof

The red run on today's main, then the fresh packaged install where the service starts and / is served, plus the refusal cases, in CI.

Builder Codex Sol 6.2 Medium, reviewer Claude Code Opus 5.5 Medium, no helper agents (J150, J162).

Activity

  1. added this to the 0.0.17 milestone on Nov 19, 2026
  2. added
    bug
    ready-for-agent
    on Nov 19, 2026
  3. jparker2006 commented on Nov 19, 2026

    @jparker2006
    MemberAuthor

    launch-fleet: started (the planner, as J162 directs: one Codex Sol 6.2 Medium builder, with one Claude Opus 5.5 Medium reviewer to follow at the green head; no helpers)

  4. jparker2006 commented on Nov 19, 2026

    @jparker2006
    MemberAuthor

    Builder question:

    I verified a fresh synthetic bundle with the real installer and ran the installed service on main. The untouched install exits 1 with Activation remains closed: the runtime state is not this installation's private state. Creating just the empty owner-private setup/ directory makes the same install reach Activation remains closed: no readable PC activation record. Both runs are retained.

    Two decisions affect how I can preserve the approved scope:

    1. Fresh-install proof. The installer writes neither setup/ nor service/config.json. The service's existing runtime and state inspection require the config after the gate. A (recommended) Use a fresh verified install with the existing private service config populated with synthetic values, without a PC activation record, and prove that the installed service serves /. B Require an untouched installer result to serve /. That needs a separate approval for a change outside the gate, starting with either tools/install/install.py (provision the existing required config) or crates/service/src/runtime.rs and crates/store/src/loops/paths.rs (support startup without it). Which is intended?
    2. Install ownership. The removed record is presently the only place the gate gets the install root. The installer accepts arbitrary --root with a separate --state-root, and the resolved executable exposes only the state-side build path. A (recommended) Verify the owner-private install root and its owner-managed current link using the existing standard install root or the installer's default <root>/state layout, and refuse an unidentifiable root. B Require starts for arbitrary split roots too. That needs an approved way to bind the install root to the build outside the gate. Which should the gate support?
  5. added
    needs-info
    on Nov 19, 2026
  6. jparker2006 commented on Nov 19, 2026

    @jparker2006
    MemberAuthor

    Planner answer to the builder question above (comment 7000212952), within J162's approved scope. If the orchestrator rules otherwise, that ruling replaces this.

    1. Fresh-install proof: A, with one condition. Don't hand-write service/config.json. A real user's service config is written by setup after install, not by the installer. So the proof runs the same code a user runs to write that config (the existing setup writer), fed synthetic, no-account values and fakes for anything networked. Then it starts the installed service and serves /. If no existing writer can produce the config offline, say so in Facts and fall back to a synthetic config that matches the schema exactly, naming that as the gap. B is out of scope: no installer or runtime changes in this ticket.
    2. Install ownership: A. Verify the owner-private install root and its owner-managed current link at the standard install root or the installer's default <root>/state layout, and refuse an install root it can't identify, with a clear message. That keeps the gate fail-closed. A split --root and --state-root install that can't be identified refuses; name that limit in the PR's Facts and in contracts/install.v1.md's owned lines.

    Take needs-info off and carry on.

  7. removed
    needs-info
    on Nov 19, 2026
  8. added 2 commits that reference this issue on Nov 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugready-for-agent

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions