diff --git a/apps/web/messages/en.json b/apps/web/messages/en.json index 8bad25171..d716518f0 100644 --- a/apps/web/messages/en.json +++ b/apps/web/messages/en.json @@ -2246,6 +2246,54 @@ "guard": "action buttons=false" } } + }, + "hostOwnerDecisionRecordFormalRecordQueueReviewOutcomes": { + "title": "Host Owner Decision Record Formal Record Queue Review Outcome Lanes", + "subtitle": "Formal record queue review outcome lanes only show the next-step routing after checklist review. They do not mark review passed, enqueue, create decision records, accept owner decisions, create approval records, or open runtime gates.", + "laneLabel": "Queue review outcome", + "nextLabel": "Next step", + "items": { + "readyForHumanRecordOwnerHandoff": { + "title": "Ready for human record owner handoff", + "body": "When all queue review conditions are readable, this can only display a future candidate handoff state for a human record owner.", + "next": "display handoff candidate; review passed=0, queue enqueued=0" + }, + "identityNeedsTraceRefresh": { + "title": "Identity needs trace refresh", + "body": "When candidate record id, version, owner, review scope, or trace source is unclear, route back to the identity packet for evidence refresh.", + "next": "refresh identity trace; record created=false" + }, + "decisionSummaryNeedsClarification": { + "title": "Decision summary needs clarification", + "body": "When the decision summary or no-execution statement is not readable, route back to the summary packet for clarification.", + "next": "clarify decision summary; accepted=0" + }, + "scopeExpiryNeedsRefresh": { + "title": "Scope and expiry need refresh", + "body": "When host, network, service, exclusion, observation intent, or expiry is stale or outside original scope, route back to the scope packet.", + "next": "refresh scope / expiry; finalized=0" + }, + "scanLimitsRemainAmbiguous": { + "title": "Scan limits remain ambiguous", + "body": "If observe-only, future active scan, or credentialed scan limits can still be mistaken for authorization, route back to the scan limits packet.", + "next": "clarify scan limits; scan authorized=false" + }, + "credentialBoundaryFailed": { + "title": "Credential boundary failed", + "body": "If the credential boundary cannot stay metadata-only or the responsibility boundary is unreadable, quarantine and request evidence refresh.", + "next": "refresh metadata-only boundary; secret collection=false" + }, + "maintenanceRollbackIncomplete": { + "title": "Maintenance and rollback incomplete", + "body": "If maintenance window, constraints, rollback owner, recovery path, or human contact is missing, it cannot enter formal record semantics.", + "next": "refresh maintenance / rollback; host change=false" + }, + "runtimeGateStillRequired": { + "title": "Runtime gate still required", + "body": "Validation evidence or runtime gate pointer still requires a separate follow-up gate and cannot open from queue review outcome.", + "next": "active runtime gates=0; action buttons=false" + } + } } }, "tickets": { diff --git a/apps/web/messages/zh-TW.json b/apps/web/messages/zh-TW.json index cb591531a..d0166be9c 100644 --- a/apps/web/messages/zh-TW.json +++ b/apps/web/messages/zh-TW.json @@ -2247,6 +2247,54 @@ "guard": "action buttons=false" } } + }, + "hostOwnerDecisionRecordFormalRecordQueueReviewOutcomes": { + "title": "主機 Owner Decision Record Formal Record Queue Review Outcome Lanes", + "subtitle": "Formal record queue review outcome lanes 只顯示 checklist 後的下一步分流。不代表 review passed、不 enqueue、不建立 decision record、不接受 owner decision、不建立 approval record、不開 runtime gate。", + "laneLabel": "Queue review outcome", + "nextLabel": "下一步", + "items": { + "readyForHumanRecordOwnerHandoff": { + "title": "Ready for human record owner handoff", + "body": "所有 queue review 條件都可讀時,只能顯示未來交給人工 record owner 的候選狀態。", + "next": "顯示 handoff 候選;review passed=0、queue enqueued=0" + }, + "identityNeedsTraceRefresh": { + "title": "Identity needs trace refresh", + "body": "candidate record id、版本、owner、review scope 或 trace source 不清楚時,回到 identity packet 補證。", + "next": "補 identity trace;record created=false" + }, + "decisionSummaryNeedsClarification": { + "title": "Decision summary needs clarification", + "body": "decision summary 或 no-execution statement 不可讀時,回到 summary packet 補文字。", + "next": "補 decision summary;accepted=0" + }, + "scopeExpiryNeedsRefresh": { + "title": "Scope and expiry need refresh", + "body": "host、network、service、exclusion、觀察目的或 expiry 過期或超出原始 scope 時,回到 scope packet。", + "next": "補 scope / expiry;finalized=0" + }, + "scanLimitsRemainAmbiguous": { + "title": "Scan limits remain ambiguous", + "body": "observe-only、future active scan 或 credentialed scan limits 若仍可能被誤讀成授權,必須回到 scan limits packet。", + "next": "補 scan limits;scan authorized=false" + }, + "credentialBoundaryFailed": { + "title": "Credential boundary failed", + "body": "credential boundary 若無法保持 metadata-only 或責任邊界不可讀,必須隔離補證。", + "next": "補 metadata-only boundary;secret collection=false" + }, + "maintenanceRollbackIncomplete": { + "title": "Maintenance and rollback incomplete", + "body": "維護窗口、限制條件、rollback owner、復原路徑或人工聯絡點缺漏時,不能進入正式紀錄語義。", + "next": "補 maintenance / rollback;host change=false" + }, + "runtimeGateStillRequired": { + "title": "Runtime gate still required", + "body": "validation evidence 或 runtime gate pointer 仍需要獨立 follow-up gate,不能由 queue review outcome 開 gate。", + "next": "active runtime gates=0;action buttons=false" + } + } } }, "tickets": { diff --git a/apps/web/src/app/[locale]/iwooos/page.tsx b/apps/web/src/app/[locale]/iwooos/page.tsx index 9d14b51c7..9fb08ec57 100644 --- a/apps/web/src/app/[locale]/iwooos/page.tsx +++ b/apps/web/src/app/[locale]/iwooos/page.tsx @@ -236,6 +236,13 @@ type HostOwnerDecisionRecordFormalRecordQueueReviewItem = { tone: 'steady' | 'warn' | 'locked' } +type HostOwnerDecisionRecordFormalRecordQueueReviewOutcomeLane = { + key: string + lane: string + icon: typeof ShieldCheck + tone: 'steady' | 'warn' | 'locked' +} + const postureMetrics: PostureMetric[] = [ { key: 'overall', value: '58%', tone: 'warn' }, { key: 'framework', value: '80-85%', tone: 'steady' }, @@ -560,6 +567,17 @@ const hostOwnerDecisionRecordFormalRecordQueueReviewItems: HostOwnerDecisionReco { key: 'queueNoExecutionAttestationPresent', check: 'FQC8', icon: FileWarning, tone: 'locked' }, ] +const hostOwnerDecisionRecordFormalRecordQueueReviewOutcomeLanes: HostOwnerDecisionRecordFormalRecordQueueReviewOutcomeLane[] = [ + { key: 'readyForHumanRecordOwnerHandoff', lane: 'FQV1', icon: CheckCircle2, tone: 'steady' }, + { key: 'identityNeedsTraceRefresh', lane: 'FQV2', icon: FileText, tone: 'warn' }, + { key: 'decisionSummaryNeedsClarification', lane: 'FQV3', icon: ClipboardCheck, tone: 'warn' }, + { key: 'scopeExpiryNeedsRefresh', lane: 'FQV4', icon: Radar, tone: 'warn' }, + { key: 'scanLimitsRemainAmbiguous', lane: 'FQV5', icon: Activity, tone: 'locked' }, + { key: 'credentialBoundaryFailed', lane: 'FQV6', icon: Lock, tone: 'locked' }, + { key: 'maintenanceRollbackIncomplete', lane: 'FQV7', icon: Clock3, tone: 'warn' }, + { key: 'runtimeGateStillRequired', lane: 'FQV8', icon: ShieldCheck, tone: 'locked' }, +] + const evidenceItems = [ 'iwooos-posture-projection.snapshot.json', 'security-rollout-policy.snapshot.json', @@ -1478,6 +1496,38 @@ function HostOwnerDecisionRecordFormalRecordQueueReviewCard({ ) } +function HostOwnerDecisionRecordFormalRecordQueueReviewOutcomeCard({ + item, +}: { + item: HostOwnerDecisionRecordFormalRecordQueueReviewOutcomeLane +}) { + const t = useTranslations('iwooos.hostOwnerDecisionRecordFormalRecordQueueReviewOutcomes') + const Icon = item.icon + return ( +
+
+
+ + {t('laneLabel')} +
+ {item.lane} +
+

+ {t(`items.${item.key}.title` as never)} +

+

+ {t(`items.${item.key}.body` as never)} +

+
+
{t('nextLabel')}
+
+ {t(`items.${item.key}.next` as never)} +
+
+
+ ) +} + export default function IwoooSPage({ params }: { params: { locale: string } }) { const t = useTranslations('iwooos') @@ -2010,6 +2060,26 @@ export default function IwoooSPage({ params }: { params: { locale: string } }) { +
+
+

{t('hostOwnerDecisionRecordFormalRecordQueueReviewOutcomes.title')}

+

+ {t('hostOwnerDecisionRecordFormalRecordQueueReviewOutcomes.subtitle')} +

+
+
+ {hostOwnerDecisionRecordFormalRecordQueueReviewOutcomeLanes.map(item => ( + + ))} +
+
+
None: "s2_34_iwooos_host_owner_decision_record_formal_candidate_review_outcome_lanes", "s2_35_iwooos_host_owner_decision_record_formal_record_queue_packets", "s2_36_iwooos_host_owner_decision_record_formal_record_queue_review_checklist", + "s2_37_iwooos_host_owner_decision_record_formal_record_queue_review_outcome_lanes", ] assert_equal( "progress_delta_ledger.delta_ids", @@ -561,6 +562,16 @@ def validate(root: Path) -> None: "host_decision_record_formal_record_queue_review_validation_runtime_gate_separate_check", "host_decision_record_formal_record_queue_review_no_execution_attestation_present_check", ] + expected_iwooos_host_owner_decision_record_formal_record_queue_review_outcome_lane_ids = [ + "host_decision_record_formal_record_queue_review_ready_for_human_record_owner_handoff_outcome_lane", + "host_decision_record_formal_record_queue_review_identity_needs_trace_refresh_outcome_lane", + "host_decision_record_formal_record_queue_review_summary_needs_clarification_outcome_lane", + "host_decision_record_formal_record_queue_review_scope_expiry_needs_refresh_outcome_lane", + "host_decision_record_formal_record_queue_review_scan_limits_ambiguous_outcome_lane", + "host_decision_record_formal_record_queue_review_credential_boundary_failed_outcome_lane", + "host_decision_record_formal_record_queue_review_maintenance_rollback_incomplete_outcome_lane", + "host_decision_record_formal_record_queue_review_runtime_gate_required_outcome_lane", + ] assert_equal( "iwooos_projection.summary.frontend_surface_coverage_group_count", iwooos_projection["summary"]["frontend_surface_coverage_group_count"], @@ -696,6 +707,11 @@ def validate(root: Path) -> None: iwooos_projection["summary"]["host_owner_decision_record_formal_record_queue_review_checklist_item_count"], len(expected_iwooos_host_owner_decision_record_formal_record_queue_review_checklist_item_ids), ) + assert_equal( + "iwooos_projection.summary.host_owner_decision_record_formal_record_queue_review_outcome_lane_count", + iwooos_projection["summary"]["host_owner_decision_record_formal_record_queue_review_outcome_lane_count"], + len(expected_iwooos_host_owner_decision_record_formal_record_queue_review_outcome_lane_ids), + ) iwooos_progress = iwooos_projection["progress"] assert_equal("iwooos_projection.progress.overall_percent", iwooos_progress["overall_percent"], progress["overall_percent"]) assert_equal( @@ -2561,6 +2577,92 @@ def validate(root: Path) -> None: f"iwooos_projection.host_owner_decision_record_formal_record_queue_review_checklist_items.{item['item_id']}.not_authorization", item["not_authorization"], ) + iwooos_host_owner_decision_record_formal_record_queue_review_outcome_lanes = iwooos_projection[ + "host_owner_decision_record_formal_record_queue_review_outcome_lanes" + ] + assert_equal( + "iwooos_projection.host_owner_decision_record_formal_record_queue_review_outcome_lanes.ids", + [item["lane_id"] for item in iwooos_host_owner_decision_record_formal_record_queue_review_outcome_lanes], + expected_iwooos_host_owner_decision_record_formal_record_queue_review_outcome_lane_ids, + ) + assert_equal( + "iwooos_projection.host_owner_decision_record_formal_record_queue_review_outcome_lanes.display_order", + [item["display_order"] for item in iwooos_host_owner_decision_record_formal_record_queue_review_outcome_lanes], + list(range(1, len(expected_iwooos_host_owner_decision_record_formal_record_queue_review_outcome_lane_ids) + 1)), + ) + expected_iwooos_host_owner_decision_record_formal_record_queue_review_outcome_states = [ + "ready_for_human_record_owner_handoff", + "identity_needs_trace_refresh", + "decision_summary_needs_clarification", + "scope_expiry_needs_refresh", + "scan_limits_remain_ambiguous", + "credential_boundary_failed", + "maintenance_rollback_incomplete", + "runtime_gate_still_required", + ] + assert_equal( + "iwooos_projection.host_owner_decision_record_formal_record_queue_review_outcome_lanes.outcome_states", + [item["outcome_state"] for item in iwooos_host_owner_decision_record_formal_record_queue_review_outcome_lanes], + expected_iwooos_host_owner_decision_record_formal_record_queue_review_outcome_states, + ) + for item in iwooos_host_owner_decision_record_formal_record_queue_review_outcome_lanes: + assert_equal( + f"iwooos_projection.host_owner_decision_record_formal_record_queue_review_outcome_lanes.{item['lane_id']}.display_mode", + item["display_mode"], + "owner_decision_record_formal_record_queue_review_outcome_only", + ) + assert_equal( + f"iwooos_projection.host_owner_decision_record_formal_record_queue_review_outcome_lanes.{item['lane_id']}.formal_record_queue_review_passed_count", + item["formal_record_queue_review_passed_count"], + 0, + ) + assert_equal( + f"iwooos_projection.host_owner_decision_record_formal_record_queue_review_outcome_lanes.{item['lane_id']}.formal_record_queue_enqueued_count", + item["formal_record_queue_enqueued_count"], + 0, + ) + assert_false( + f"iwooos_projection.host_owner_decision_record_formal_record_queue_review_outcome_lanes.{item['lane_id']}.decision_record_created", + item["decision_record_created"], + ) + assert_equal( + f"iwooos_projection.host_owner_decision_record_formal_record_queue_review_outcome_lanes.{item['lane_id']}.owner_decision_received_count", + item["owner_decision_received_count"], + 0, + ) + assert_equal( + f"iwooos_projection.host_owner_decision_record_formal_record_queue_review_outcome_lanes.{item['lane_id']}.owner_decision_accepted_count", + item["owner_decision_accepted_count"], + 0, + ) + assert_false( + f"iwooos_projection.host_owner_decision_record_formal_record_queue_review_outcome_lanes.{item['lane_id']}.owner_approval_record_created", + item["owner_approval_record_created"], + ) + assert_false( + f"iwooos_projection.host_owner_decision_record_formal_record_queue_review_outcome_lanes.{item['lane_id']}.runtime_gate_opened", + item["runtime_gate_opened"], + ) + assert_false( + f"iwooos_projection.host_owner_decision_record_formal_record_queue_review_outcome_lanes.{item['lane_id']}.raw_payload_allowed", + item["raw_payload_allowed"], + ) + assert_false( + f"iwooos_projection.host_owner_decision_record_formal_record_queue_review_outcome_lanes.{item['lane_id']}.secret_value_collection_allowed", + item["secret_value_collection_allowed"], + ) + assert_false( + f"iwooos_projection.host_owner_decision_record_formal_record_queue_review_outcome_lanes.{item['lane_id']}.runtime_execution_authorized", + item["runtime_execution_authorized"], + ) + assert_false( + f"iwooos_projection.host_owner_decision_record_formal_record_queue_review_outcome_lanes.{item['lane_id']}.action_buttons_allowed", + item["action_buttons_allowed"], + ) + assert_true( + f"iwooos_projection.host_owner_decision_record_formal_record_queue_review_outcome_lanes.{item['lane_id']}.not_authorization", + item["not_authorization"], + ) assert_equal( "iwooos_projection.non_blocking_lane_ids", iwooos_projection["non_blocking_lane_ids"], @@ -2606,6 +2708,7 @@ def validate(root: Path) -> None: "display_host_owner_decision_record_formal_candidate_review_outcome_lanes", "display_host_owner_decision_record_formal_record_queue_packets", "display_host_owner_decision_record_formal_record_queue_review_checklist", + "display_host_owner_decision_record_formal_record_queue_review_outcome_lanes", "display_evidence_refs", "display_forbidden_actions", ]: @@ -2706,6 +2809,11 @@ def validate(root: Path) -> None: "enqueue_host_owner_decision_record_from_formal_record_queue_review", "create_host_owner_decision_record_from_formal_record_queue_review", "open_runtime_gate_from_formal_record_queue_review", + "treat_host_owner_decision_record_formal_record_queue_review_outcome_as_approval", + "mark_host_owner_decision_record_formal_record_queue_review_outcome_passed", + "enqueue_host_owner_decision_record_from_formal_record_queue_review_outcome", + "create_host_owner_decision_record_from_formal_record_queue_review_outcome", + "open_runtime_gate_from_formal_record_queue_review_outcome", "apply_runtime_blocking_control", "switch_github_primary", "production_deploy",