Skip to content

feat: add inert P01 authorization and provenance contracts - #987

Draft
Pigbibi wants to merge 1 commit into
mainfrom
feat/p01-c1-offline-gates-provenance-r1
Draft

Pigbibi wants to merge 1 commit into
mainfrom
feat/p01-c1-offline-gates-provenance-r1

Conversation

@Pigbibi

@Pigbibi Pigbibi commented Nov 6, 2026

Copy link
Copy Markdown
Collaborator

What changed

Add an inert TEST_ONLY P01 authorization/provenance validator and fake once-only
state model. Missing C0 proof, wrong producer, changed bindings, replay, expiry,
unknown results and latest-owner disable states deny. A consistent local result
is SIMULATION_ONLY and never authorizes execution or authentic private delivery.

Only the new module, its fake-only tests and the existing runtime rollout document
change. No workflow or runtime caller is added. Preserve strict operator==runSHA,
main trust, traffic/health/resourceVersion and single-compensation contracts.

How verified

  • Full offline suite: 6856 passed, 6 skipped, 368 subtests passed.
  • Focused reader/bootstrap/recovery and new contracts: 187 passed (78 new cases).
  • Tests-first unavailable-module RED; two behavioral RED cases (nonce replay and
    fake clock integrity loss) recorded before fixes; focused/full GREEN afterward.
  • Full Ruff, documentation (0 blocking, 1 existing advisory), deployment workflow
    offline contract, startup validation, CI-pinned dependency consistency,
    uv lock --offline --check and diff checks passed.
  • Complete diff: three files, 477 additions; all added lines unchanged by the
    shared identifier checker; zero production callers and zero workflow changes.

Risk and remaining prerequisites

FakeTrust is explicitly unauthenticated. FakeStore is in-memory and models
one-process atomicity only; no distributed persistence or real journal adapter.
Opaque TEST_ONLY ciphertext is not a CMS validity claim. No real keys, credentials,
private channels, cloud transport, Secret/IAM/dispatch/deploy or paid service.
C0 appointments, authentic policy/identity/ownership and recipient/custody proof,
supported private channel/control store, separately approved version selection,
fresh runtime/budget evidence and new exact action authorities remain unresolved.
Historical recovery authority/deadlines remain disabled; no C0/C2 acceptance claim.
Keep Draft. No merge, labels, operational execution or deployment requested.

AI assistance

Authored and locally self-reviewed with Codex (gpt-6.1-sol). Independent exact-head
review remains pending through the repository's established Codex review route.

Publication check

Central checker publication-check/2.0-advisory, build 83d9d1130377, advisory: 2594 findings and 2469 matching lines. Complete tracked candidate tree and candidate artifacts checked. The 477 added lines separately have zero shared-identifier matches. Existing full-tree findings remain advisory; no credential is introduced. First 20 masked entries:

repo/.env.example:11: IB_GATEWAY_HOST=<PROJECT_ID>
repo/.env.example:19: TELEGRAM_TOKEN=<<HOST>>
repo/.github/CODEOWNERS:9: /.env.example @<PROJECT_ID>
repo/.github/CODEOWNERS:10: /.github/CODEOWNERS @<PROJECT_ID>
repo/.github/CODEOWNERS:11: /application/account_new_risk_gate_support.py @<PROJECT_ID>
repo/.github/CODEOWNERS:12: /application/execution_kernel_adapter.py @<PROJECT_ID>
repo/.github/CODEOWNERS:13: /application/execution_receipt_adapter.py @<PROJECT_ID>
repo/.github/CODEOWNERS:14: /application/execution_service.py @<PROJECT_ID>
repo/.github/CODEOWNERS:15: /application/ibkr_order_execution.py @<PROJECT_ID>
repo/.github/CODEOWNERS:16: /application/paper_execution_admission.py @<PROJECT_ID>
repo/.github/CODEOWNERS:17: /application/paper_execution_command_consumer.py @<PROJECT_ID>
repo/.github/CODEOWNERS:18: /application/portfolio_risk_diagnostics.py @<PROJECT_ID>
repo/.github/CODEOWNERS:19: /application/relative_risk_preview.py @<PROJECT_ID>
repo/.github/CODEOWNERS:20: /application/tqqq_offline_risk.py @<PROJECT_ID>
repo/.github/CODEOWNERS:21: /runtime_execution_policy.py @<PROJECT_ID>
repo/.github/CODEOWNERS:22: /scripts/deploy_notification_only.py @<PROJECT_ID>
repo/.github/CODEOWNERS:23: /scripts/deploy_pilot_no_traffic.py @<PROJECT_ID>
repo/.github/CODEOWNERS:24: /scripts/execution_report_heartbeat.py @<PROJECT_ID>
repo/.github/CODEOWNERS:25: /scripts/ibkr_deployment_audit.py @<PROJECT_ID>
repo/.github/CODEOWNERS:26: /scripts/summarize_execution_ledger_cloud.py @<PROJECT_ID>

@Pigbibi

Pigbibi commented Nov 6, 2026

Copy link
Copy Markdown
Collaborator Author

@codex review

Please review exact head 890f371 of this inert,
fake-only candidate through the established repository review route. Focus on
fail-closed C0 gaps, source/envelope/recipient bindings, replay/deadlines and the
explicit lack of authentic authority or production wiring. Local full offline
results: 6856 passed, 6 skipped, 368 subtests passed; focused results: 187 passed.
Keep Draft. No operational approval, merge, label, dispatch or deployment requested.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-06T23:10:41.211147Z 890f371 Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Bravo.

Reviewed commit: 890f371102

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

This branch has not been deployed

No deployments
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