Thanks to visit codestin.com
Credit goes to github.com

Skip to content

feat(capsule): integrate Station consumer lifecycle - #1659

Open
joshuajbouw wants to merge 8 commits into
mainfrom
codex/capsule-station-certified-main
Open

feat(capsule): integrate Station consumer lifecycle#1659
joshuajbouw wants to merge 8 commits into
mainfrom
codex/capsule-station-certified-main

Conversation

@joshuajbouw

@joshuajbouw joshuajbouw commented Aug 26, 2026

Copy link
Copy Markdown
Member

Linked Issue

Tracking #1682
Depends on #1719
Refs #1563

Summary

Integrates authenticated Capsule Station v1 install, update, show, removal, and durable provenance into the current Astrid mainline. Station-bound installs now carry a typed artifact and lock binding into the daemon so verified bytes, package mutation, and owner-scoped Station lock state cannot diverge under concurrent installs.

Internal identifiers such as station-lock-v2 name wire or format revisions; they are not a Station product version.

Changes

  • resolves and privately hands off authenticated Station coordinates
  • validates exact archive size, SHA-256, BLAKE3, manifest name, and version before install
  • stages daemon-owned bytes rather than reopening caller-replaceable content
  • serializes package mutation and Station lock compare-and-swap under one owner/capsule guard
  • preserves GitHub, distro, local, and Station provenance boundaries
  • clears stale Station provenance on production remove and local replacement
  • keeps ordinary local, GitHub, distro, and auto-build installs free of Station lock writes
  • adds deterministic concurrency, substitution, create-only, lifecycle, and cross-platform regressions

Verification

  • current signed integration head: a32d25d1384ebd7207f664df9c1ea807c5deb8ff
  • current-main merge tree: 25a099d2384b9cf9ae8b1b0d73ccdfe70845c561
  • reviewed feature head: 3477e0195f67af572f5c8155cc22a0ef716bcdd2
  • kernel Station regressions: 7/7
  • focused CLI Station lifecycle: 26/26 in independent review; 30/30 in the implementation run
  • workspace all-targets check and strict all-features/all-targets Clippy on Rust 1.95
  • formatting, whitespace, GPG, DCO, ancestry, commit-message, and file-cap checks
  • fresh exact-head review and GitHub CI are required for the current integration head

Claim boundary

This PR lands the Astrid consumer lifecycle. It does not host or activate a Station, move the public Station pin, publish production TUF metadata, or grant runtime capabilities from Station acceptance.

Residuals

  • crash recovery between package durability and final lock commit remains a separate recovery-tail concern; concurrent successful installs are serialized and cannot leave mismatched package/lock state
  • production Pages, official content publication, public pin movement, and activation remain separate authority gates

AI / Tool Assistance

An AI coding assistant helped implement, test, integrate, and review the change. Joshua J. Bouw reviewed the resulting design, security invariants, and verification evidence and remains accountable for the submission.

Checklist

  • Linked to an issue
  • Changelog fragment added under changes/{issue}.{kind}.md
  • I understand every change in this PR and can explain its design, risks, and validation.
  • I reviewed and tested meaningful tool-generated output included in this PR.
  • Every non-bot, non-merge commit has a matching Signed-off-by trailer.

Add authenticated Station install, update, show, and typed lock lifecycle support on the current mainline runtime and storage layout.

AI-Disclosure: Codex | implemented the Capsule Station consumer and current-main regression integration; human reviewed and verified the independently tested lifecycle evidence
Signed-off-by: Joshua J. Bouw <[email protected]>
Copilot AI balanced review requested due to automatic review settings August 26, 2026 10:18

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

Keep platform-neutral Station tests compiled everywhere while limiting shell-script fixtures and Unix permission APIs to supported targets.

AI-Disclosure: Codex | implemented the Windows test compilation fix; human reviewed and verified formatting, test compilation, and strict clippy

Signed-off-by: Joshua J. Bouw <[email protected]>
Describe Station as the v1 product while retaining internal wire and format identifiers such as station-lock-v2.

AI-Disclosure: Codex | implemented the terminology correction; human reviewed and verified formatting, all-target compilation, and diff checks
Signed-off-by: Joshua J. Bouw <[email protected]>
@joshuajbouw
joshuajbouw marked this pull request as ready for review August 26, 2026 12:37
Add paired lock path and hidden raw-byte digest arguments.

Validate untrusted sidecars before parsing, bind staged capsule bytes to typed Station commitments, persist owner-scoped provenance before daemon installation, and restore prior state on failure.

Assisted development disclosure: implementation was prepared with an AI coding assistant and reviewed by the committing author.

Signed-off-by: Joshua J. Bouw <[email protected]>
Validate archive bytes independently before owner-scoped lock writes and preserve lock ownership with conditional rollback when daemon installation fails.

Assisted development disclosure: implementation was prepared with an AI coding assistant and reviewed by the committing author.

Signed-off-by: Joshua J. Bouw <[email protected]>
Closes #1677

Same host session replaces the previous gateway attach. Silent readers
idle-EOF after two minutes. At the 16-attach cap, idle LRU eviction
admits a new slot and busy slots fail fast. mcp gc SIGTERMs orphaned
astrid/aos mcp attach processes and never signals Python aos-mcp-frame.
Replacement teardown is serialized and fail-closed before a new permit
is acquired. Slot cancellation is passed into RMCP initialization.

Signed-off-by: Joshua J. Bouw <[email protected]>
Stage and bind verified capsule bytes before persisting owner-scoped Station locks, then roll back with compare-and-swap so concurrent provenance survives.

Closes #1682

Assisted development disclosure: implementation was prepared with an AI coding assistant and reviewed by the committing author.

Signed-off-by: Joshua J. Bouw <[email protected]>
Bring the reviewed Station consumer lifecycle and atomic install transaction onto current main without changing the accepted feature blobs.

Assisted development disclosure: integration was prepared with an AI coding assistant and reviewed by the committing author.

Signed-off-by: Joshua J. Bouw <[email protected]>
@joshuajbouw

Copy link
Copy Markdown
Member Author

Architecture hold: this PR remains useful, reviewed evidence for atomic package/provenance installation, but it is not the final landing vehicle. #1719 must first remove Station-specific types and state from the kernel boundary while preserving the proven exact-byte, CAS, ownership, and lifecycle invariants. The successor will require fresh review, CI, and the full production lifecycle test.

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.

2 participants