founding: the rented path still pairs with a placeholder identity — 18-byte key, invented hardware probe, literal SSH host key #282

Closed
opened 2026-08-05 23:09:58 +00:00 by ben · 1 comment
Owner

internal/founding/standuprented.go — three placeholders survive on the rented path (the private path's were fixed after the 2026-08-05 live drive, b501208):

  1. Line 54: rentedGatewayKey is 18 bytes of ASCII, not a 32-byte ed25519 key. Traced end-to-end: Mint and Redeem succeed (the ledger stores BoundPub unvalidated), and the in-line approval dies at the real CA (internal/enroll/community_ca.go:193) with want 32-byte ed25519 public key, got 18 bytes — loud, but late and misleading (reads as a device fault, not "never wired"), and each retry strands a fresh code + request in the ledger. The fix pattern exists next door: internal/founding/privatepath.go:164 mintPrivateVMKey, whose comment records exactly this lesson.
  2. Line 131: rentedGatewayProbe() returns hardcoded 2 vCPU / 4 GB / 40 GB — tuned to pass the gateway floor exactly. Even after the key fix, the spec gate (internal/enroll/ledger.go:344) rubber-stamps any rented server against invented hardware.
  3. Line 122: SSHHostKey: []byte("rented-gateway-ssh-host-key") — same landmine class as the agent's literal.

The rented path is alpha-parked (ADR 0114 — brokerclient Offer/Rent refuse honestly), so nothing is live-broken today; this must land before the path opens.

Acceptance

  • The rented pair uses a freshly minted ed25519 keypair (mirror mintPrivateVMKey).
  • The probe never fabricates: either real provisioned-server facts from the carrier, or the pair refuses loudly that the carrier's hardware report is not wired yet — no invented numbers through the spec gate.
  • The SSH host key placeholder is removed (real value or explicit empty-with-comment, not fake data).
  • A failed pair must not strand ledger state on retry (re-entry reuses or expires the minted code/request).

Filed from the 2026-08-05 fail-loud audit (three-agent pre-production sweep; findings verified against code).

`internal/founding/standuprented.go` — three placeholders survive on the rented path (the private path's were fixed after the 2026-08-05 live drive, `b501208`): 1. **Line 54**: `rentedGatewayKey` is 18 bytes of ASCII, not a 32-byte ed25519 key. Traced end-to-end: Mint and Redeem succeed (the ledger stores `BoundPub` unvalidated), and the in-line approval dies at the real CA (`internal/enroll/community_ca.go:193`) with `want 32-byte ed25519 public key, got 18 bytes` — loud, but late and misleading (reads as a device fault, not "never wired"), and each retry strands a fresh code + request in the ledger. The fix pattern exists next door: `internal/founding/privatepath.go:164` `mintPrivateVMKey`, whose comment records exactly this lesson. 2. **Line 131**: `rentedGatewayProbe()` returns hardcoded 2 vCPU / 4 GB / 40 GB — tuned to pass the gateway floor exactly. Even after the key fix, the spec gate (`internal/enroll/ledger.go:344`) rubber-stamps **any** rented server against invented hardware. 3. **Line 122**: `SSHHostKey: []byte("rented-gateway-ssh-host-key")` — same landmine class as the agent's literal. The rented path is alpha-parked (ADR 0114 — `brokerclient` `Offer`/`Rent` refuse honestly), so nothing is live-broken today; this must land before the path opens. **Acceptance** - The rented pair uses a freshly minted ed25519 keypair (mirror `mintPrivateVMKey`). - The probe never fabricates: either real provisioned-server facts from the carrier, or the pair refuses loudly that the carrier's hardware report is not wired yet — no invented numbers through the spec gate. - The SSH host key placeholder is removed (real value or explicit empty-with-comment, not fake data). - A failed pair must not strand ledger state on retry (re-entry reuses or expires the minted code/request). --- _Filed from the 2026-08-05 fail-loud audit (three-agent pre-production sweep; findings verified against code)._
Author
Owner

Fixed on main (commit 7886beb). All three rented-path placeholders in internal/founding/standuprented.go are gone:

  1. 18-byte key → real ed25519 keypair. New mintRentedGatewayKey mints a fresh ed25519 keypair the community CA accepts, mirroring the private path's minted VM key. Guarded by a red-first test wiring the real enroll.CommunityCA as the granter: the pair now reaches an approved node whose NodeCert verifies against the community root; the old placeholder key dies exactly where the issue said (want 32-byte ed25519 public key, got 18 bytes).
  2. Fabricated 2/4/40 probe → carrier seam + loud refusal. rentedGatewayProbe() is replaced by a RentedProbe interface (WithRentedProbe) reporting the carrier's real hardware. The rented path being alpha-parked (ADR 0114, no carrier report wired), production wires nothing and StandUpRented refuses loudly with the new ErrRentedProbeUnavailable before minting anything — no invented numbers through the spec gate, no stranded ledger state (mirrors the private path's ErrHostProbeUnavailable).
  3. Literal SSH host key → explicit nil-with-comment. The real gateway mints its own host key at first run; no fake data.
  4. Failed pair no longer strands ledger state. A failed pair (or redeem) revokes the minted code — closing its bound request — via a new EnrollFace.RevokeCode, so a retry starts clean rather than accumulating a dead code + request. Red-first test drives a granter outage: code revoked, no live request stranded, retry accumulates nothing.

All four acceptance clauses covered by red-first seam tests in standuprented_test.go (both new failure modes verified red before the fix). go test/go vet green (founding, enroll); the pre-push CI gate passed. STATUS.md header updated.

Fixed on `main` (commit `7886beb`). All three rented-path placeholders in `internal/founding/standuprented.go` are gone: 1. **18-byte key → real ed25519 keypair.** New `mintRentedGatewayKey` mints a fresh ed25519 keypair the community CA accepts, mirroring the private path's minted VM key. Guarded by a red-first test wiring the **real** `enroll.CommunityCA` as the granter: the pair now reaches an approved node whose NodeCert verifies against the community root; the old placeholder key dies exactly where the issue said (`want 32-byte ed25519 public key, got 18 bytes`). 2. **Fabricated 2/4/40 probe → carrier seam + loud refusal.** `rentedGatewayProbe()` is replaced by a `RentedProbe` interface (`WithRentedProbe`) reporting the carrier's real hardware. The rented path being alpha-parked (ADR 0114, no carrier report wired), production wires nothing and `StandUpRented` refuses loudly with the new `ErrRentedProbeUnavailable` **before** minting anything — no invented numbers through the spec gate, no stranded ledger state (mirrors the private path's `ErrHostProbeUnavailable`). 3. **Literal SSH host key → explicit nil-with-comment.** The real gateway mints its own host key at first run; no fake data. 4. **Failed pair no longer strands ledger state.** A failed pair (or redeem) revokes the minted code — closing its bound request — via a new `EnrollFace.RevokeCode`, so a retry starts clean rather than accumulating a dead code + request. Red-first test drives a granter outage: code revoked, no live request stranded, retry accumulates nothing. All four acceptance clauses covered by red-first seam tests in `standuprented_test.go` (both new failure modes verified red before the fix). `go test`/`go vet` green (founding, enroll); the pre-push CI gate passed. STATUS.md header updated.
ben closed this issue 2026-08-06 02:53:20 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Matou/idss#282
No description provided.