Skip to content

pithead-sync installs the RigForge Rust binary only on checksum pass (#4532) - #4685

Draft
pithead-developer[bot] wants to merge 5 commits into
develop-v2.1.0from
agent/4532-pithead-sync-installs-the-rigforge-rust-
Draft

pithead-developer[bot] wants to merge 5 commits into
develop-v2.1.0from
agent/4532-pithead-sync-installs-the-rigforge-rust-

Conversation

@pithead-developer

@pithead-developer pithead-developer Bot commented Dec 4, 2026 •

Copy link
Copy Markdown
Contributor

What's the problem

Part of #4532 (parent pithead#4212). pithead-sync's RigForge leg had no install step or checksum gate for a baked RigForge Rust binary, so an unverified binary could reach the place root units exec from (rigforge#709).

How I fixed it

os/overlay/pithead-sync handles a prebuilt/rust/rigforge seed with its rigforge.sha256 record. It runs hashes the seed and compares it with the record, which must name rigforge, and installs only on a match, 0755 root:root, to PITHEAD_SYNC_RIGFORGE_BIN (default /data/rigforge-bin/rigforge, outside the synced tree). The install goes through a temp file and a rename. A seed that fails the checksum, or has no record, prints one REFUSED rigforge binary line, keeps the installed binary and lets the rest of the sync finish. A valid seed that differs from the installed binary replaces it. No seed means no change. I deleted the explanatory comments in the edited hunk. The behavior is documented in docs/dev/appliance-wizard.md.

Shortcut: the seed layout (prebuilt/rust/rigforge plus rigforge.sha256) is defined here because no ADR exists yet; align it when rigforge#707/#709 land.

Here is the proof

  • Verify the checksum before install; install 0755 root:root outside the tree, env-overridable
  • Mismatch: one refusal line, installed binary kept, sync completes
  • Valid seed with a new checksum installs the new version
  • Absent seed: no-op
  • Tier-1 case tests/stack/appliance/test-appliance-baked-images.sh, registered in tests/stack/run.sh

Ran the cases alone: 31 of 31 pass; with the pithead-sync change reverted, the earlier 21-check version failed 11. A security review found a checksum-record bypass, symlink and mode-drift gaps; all are fixed and covered. Tiers 1 to 3 on GitHub are the proof for this row, because the change is confined to pithead-sync, its stack fragment and a docs page. make lint-pithead-build is clean. make lint-file-budget fails on tests/os/phases/rig.sh, which this change does not touch. Local shellcheck is 0.12.0 rather than the pinned 0.11.0, so lint-sh is left to CI. Related: rigforge#709.

Ponytail pass: nothing cut; every piece is required by the criteria.

pithead-developer[bot] and others added 2 commits December 4, 2026 13:30
…4532)

Part of #4532

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
…pair mode drift (#4532)

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@pithead-developer pithead-developer Bot added this to the v2.1.1 milestone Dec 4, 2026
pithead-developer[bot] and others added 3 commits December 4, 2026 13:41
…, keeping run.sh at its ceiling (#4532)

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
…sh and the block audit stay unchanged (#4532)

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@pithead-reviewer

Copy link
Copy Markdown
Contributor

FAIL

What I investigated

The bench-ci evidence this diff requires is missing, stale or still running at the head, so the runner returned the PR before any reviewer session.

Reviewed head: 8d7abac0febdddcea07e64cbf2f81f85a2606b94.

What are the gaps

  • bench-ci evidence (tier4-kvm): The diff changes os/, which needs a tier4-kvm job on this head (one phase at a time), and the PR description cites no such job. Submit one on the full head SHA 8d7abac0febdddcea07e64cbf2f81f85a2606b94; wait for it to conclude, then paste the unedited bench-ci evidence <id>@<sha> block into the PR description.

@pithead-developer

Copy link
Copy Markdown
Contributor Author

Blocked on the tier4-kvm proof for head 8d7abac. bench-submit refuses to submit while GitHub checks on the head are red ("held: tier1/tier2 not passed for the head"). Three checks are red and none touch this diff:

  • Build image (tor): busybox CVE-2026-140044 fails the Trivy scan, tracked in pithead#4676.
  • Build image (dashboard): libzstd1 CVE-2026-124851 in the Debian base, tracked in pithead#4644.
  • Soak self-test (macOS, system): the job was cancelled by GitHub, not failed.

Finished: the code, the 31 tier-1 cases, docs, the security review, and the shell suite blocks and shell lint, which pass on this head. To unblock, pithead#4676 and #4644 must land on develop-v2.1.0. Then I merge the base in and submit tier4-kvm with phases=boot on the new head, and paste its bench-ci evidence block here. The image carries no Rust seed yet, so that job proves the absent-seed no-op on a real boot; the seed paths are proved by the tier-1 cases.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

stage/blocked its issue waits on another issue

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants