From cb665dc6362027a06d46c3fc856c8740f4ab50ce Mon Sep 17 00:00:00 2001 From: Meta Vens Date: Sun, 19 Jul 2026 07:11:10 +0100 Subject: [PATCH] Authenticate terminal sight against historical launch --- .../workspace_coverage_process_documents.rs | 41 +++++++++++++++--- notes/fresh-workspace-handoff.md | 24 ++++++++++ state/ledgers.msgpack | Bin 532605 -> 533063 bytes state/map.yaml | 4 +- 4 files changed, 60 insertions(+), 9 deletions(-) diff --git a/epiphany-core/src/workspace_coverage_process_documents.rs b/epiphany-core/src/workspace_coverage_process_documents.rs index 4c9a35e6..e4dbf1be 100644 --- a/epiphany-core/src/workspace_coverage_process_documents.rs +++ b/epiphany-core/src/workspace_coverage_process_documents.rs @@ -3043,6 +3043,7 @@ fn authenticate_advancement_sight( bail!("workspace coverage advancement sight identity disagrees"); } authenticate_sight_common( + WorkspaceCoverageSightLaunchAuthority::Current, runtime_store, local_verse_store, runtime_id, @@ -3083,6 +3084,7 @@ fn authenticate_terminal_sight( bail!("workspace coverage terminal sight identity disagrees"); } authenticate_sight_common( + WorkspaceCoverageSightLaunchAuthority::HistoricalTerminal, runtime_store, local_verse_store, runtime_id, @@ -3111,8 +3113,15 @@ fn authenticate_terminal_sight( ) } +#[derive(Clone, Copy)] +enum WorkspaceCoverageSightLaunchAuthority { + Current, + HistoricalTerminal, +} + #[allow(clippy::too_many_arguments)] fn authenticate_sight_common( + launch_authority: WorkspaceCoverageSightLaunchAuthority, runtime_store: &Path, local_verse_store: &Path, runtime_id: &str, @@ -3131,13 +3140,24 @@ fn authenticate_sight_common( body_generation: u64, manifest_root_sha256: &str, ) -> Result<()> { - let (launch, exact_launch_digest) = - authenticate_workspace_coverage_managed_process_launch_with_envelope_digest( - local_verse_store, - runtime_id, - launch_id, - host, - )?; + let (launch, exact_launch_digest) = match launch_authority { + WorkspaceCoverageSightLaunchAuthority::Current => { + authenticate_workspace_coverage_managed_process_launch_with_envelope_digest( + local_verse_store, + runtime_id, + launch_id, + host, + )? + } + WorkspaceCoverageSightLaunchAuthority::HistoricalTerminal => { + authenticate_historical_workspace_coverage_managed_process_launch_with_envelope_digest( + local_verse_store, + runtime_id, + launch_id, + host, + )? + } + }; if exact_launch_digest != launch_digest || launch.provider_incarnation_id != provider_incarnation_id || launch.provider_public_key != provider_public_key @@ -3909,6 +3929,13 @@ mod tests { &provider, chrono::Utc::now(), )?; + let mut rotated_policy = policy.clone(); + rotated_policy.updated_at_utc = "2026-07-17T00:00:01Z".into(); + write_epiphany_cultmesh_workspace_coverage_projector_service_policy( + &verse, + "local", + rotated_policy, + )?; let historical_sight = publish_workspace_coverage_terminal_sight( &verse, &runtime, diff --git a/notes/fresh-workspace-handoff.md b/notes/fresh-workspace-handoff.md index c0f17a4a..73cc5f8a 100644 --- a/notes/fresh-workspace-handoff.md +++ b/notes/fresh-workspace-handoff.md @@ -2997,3 +2997,27 @@ and deployment under the all-scope brake. Next action: monitor Idunn's exact successor transaction. Require historical terminal-sight reuse, three stable services, typed resident readiness, signed aggregate health, and `deployment.env` before beginning the ordinary organizational product loop. + +Candidate `519574ce0d63ffa8fa813885c6629c664a3ae2e0` sealed release +`sha256-3bfbd4640f7259613ea6146fe80d6a68c9be55edb1ad100fb3c39a4f0e040e3e` +and started all three braked services with zero restarts. The installed +pre-witness check was healthy, proving terminal coverage and resident readiness +were present, but the workspace projector still refused every pulse with +`workspace coverage launch disagrees with current managed policy`; the +supervisor then issued recovery directive `9084c09e-1da9-4187-acd4-6b214edd7fb2` +for the already-succeeded claim. Idunn correctly withheld signed admission and +`deployment.env`. + +The surviving obsolete owner was inside terminal-sight authentication itself. +Both advancing and terminal sights shared current-policy launch authentication. +That is correct for a live advancing lease and wrong for immutable terminal +proof. Sight authentication now has an explicit authority split: advancement +requires a current-policy launch; terminal requires its exact historical +host-signed launch and envelope. Policy rotation cannot invalidate or re-sign +the succeeded claim's sight. The real checkpoint-to-terminal fixture now +rotates managed policy before a later daemon reuses the original sight +byte-for-byte. + +Next action: commit/push this correction, revoke `519574ce`, terminate exact +Idunn transaction PGID `1534830`, verify signal-safe rollback, then cross the +exact successor through Bifrost and Idunn under brake. diff --git a/state/ledgers.msgpack b/state/ledgers.msgpack index a4094cb197c18634e9814a916e4d9b3607cf4715..c78e967643d757e8dd9f64ece1d9f4161f9773f3 100644 GIT binary patch delta 508 zcmZWlyH3ME5X9k?h7Qpn&_+<=5Jx0YBBkOJNJV!!FZjT@Gk0r)s}vOc01*;jfkc7m zC=mP#4WEF-8V3uBVzkoE&hE~9y}<<8DHZG)N-}oer3uBuE(zW0WFw2tPx autonomous bounded Imagination proposal, with organization feedback through Persona as additional attributed pressure; explicit Mind adoption -> Hands consequence -> Bifrost release -> Idunn deployment remain separate gates. Prove replay/tamper refusal and that conversation alone grants no Mind, Hands, Persona-speech, release, or deployment authority. No host reboot is authorized." + next_action: "Candidate 519574ce is braked and Idunn-owned at PGID 1534830 but unadmitted: all services and pre-witness readiness are healthy, while terminal-sight authentication still treated the historical succeeded launch as current-policy authority, causing projector refusal and a bogus recovery directive. Commit/push the explicit sight-authority split (advancement=current launch; terminal=historical signed launch), revoke 519574ce, terminate only PGID 1534830, and verify signal-safe rollback. Then Bifrost-authorize and Idunn-deploy the exact successor under brake. Require immutable historical terminal-sight reuse, three stable services, typed resident readiness, signed aggregate health, and final deployment.env before the Starfire-offline ordinary-product rehearsal: persistent Modeling map -> autonomous bounded Imagination proposal, with organization feedback through Persona as additional attributed pressure; explicit Mind adoption -> Hands consequence -> Bifrost release -> Idunn deployment remain separate gates. Prove replay/tamper refusal and that conversation alone grants no Mind, Hands, Persona-speech, release, or deployment authority. No host reboot is authorized."