Skip to content

harden(pitot): fail-closed boundaries, bounded state, adapter guards + public README - #260

Merged
bigboateng merged 2 commits into
mainfrom
codex/pitot-hardening
Jul 31, 2026
Merged

harden(pitot): fail-closed boundaries, bounded state, adapter guards + public README#260
bigboateng merged 2 commits into
mainfrom
codex/pitot-hardening

Conversation

@bigboateng

Copy link
Copy Markdown
Contributor

Feature-preserving hardening of the Pitot adapter surface, guided by a full Locus analysis, landing on top of the merged Devin ACP adapter (#259). No adapter, transport, or observe-only mode was removed.

What changed

Runtime / boundary (fail-closed):

  • transport: an event-delivery fault now returns 409, not a 204 that a host reads as allow.
  • runtime: additive strict moderequire_controller: true config key and pitot run --strict flag — faults instead of silently allowing when a declared action kind has no controller. Default behavior unchanged; otherwise a once-per-kind observation-only notice is emitted.
  • hook: one-line stderr notice when no runtime is selected (still exit 0); allow path now requires the response ActionID to match the request.
  • sensor/adapters: decode-time tool-name guards per host; ActionKind no longer silently defaults to "shell" for unknown boundary events.
  • bridge: the router's resolved-action set is now bounded (4096-entry window).
  • devinacp: one-shot diagnostic when a tool_call update lacks cognition.ai/inferenceToolName (stays fail-closed).
  • doctor: PITOT_RUNTIME-unset note and a binary-hash drift check for non-repo-wired hosts.

Tests: new Go guards (adapters, sensor, bridge window, runtime strict + transport fault, devinacp meta, hook notice); new Python coverage for the devin control-proxy HTTP behavior, validate_receipts negative branches, the two E2E apparatus binaries, and npm/kimi/cursor installers. Fixed a real devin-proxy save() race surfaced by the 64-connection burst test (shared tmp filename → collision → killed connection; the plausible origin of the intermittent Windows ConnectionFailed).

Public README: Devin added to the supported-hosts table with a platforms column; new Host admission criteria (deny-continuation) section; a Threat model section that names Kimi's fail-open host semantics plainly; a contributing guide covering both adapter transport classes.

Locus analysis (all verdicts advisory / model-scoped; evidence-root = worktree)

16 models fidelity-certified against labs/15-pitot sources.

  • Protocol refinement (verification.trace-refinement): 9/10 adapters refines=true. kimi refines=FALSE, witness verbatim: intercept → host_hook_crash → execute.
  • Host-class supervisability (control.supervisory-rw): repo-wired and ACP classes controllable; user-level fail-open class not controllable, violation verbatim: uncontrollable event "host_fail_open_execute" fires from reachable state "PENDING" into forbidden state "EXECUTED_UNSUPERVISED".
  • Router lifecycle (control.nonblockingness): nonblocking=true — exactly one terminal resolution per action.
  • Root cause (practice.root-cause, both transforms accepted): failure class = silent-mode-degradation; instances (a) hook without PITOT_RUNTIME, (b) devinacp missing vendor _meta key. Class-eliminating change: every guarantee downgrade must announce itself + additive strict opt-in.
  • Interpretation folds (safety-reachability, feature-vs-defect): wp1/wp2/wp3/wp6/wp8 all under-assumption — keep the feature, harden the assumption (none refuted). drv-910d01f7, drv-a358fc34, drv-6d39be01, drv-6e4cec53, drv-5fedcc4a.
  • Strict-mode candidates (forbidden-unreachable): strict-config-v1 and strict-flag-v1 both satisfy; strict-none-v1 rejected via [declared_kind_without_controller, silent_allow]drv-7b62b16c.

Undischarged obligations: refinement verdicts discharge against the 30-cell E2E matrix (real CLI behavior = modeled lifecycle); the kimi fail-open and copilot/qwen crash behaviors are host-semantics facts only vendors can change.

Gates

go test ./..., go vet, gofmt (clean except pre-existing sdk/runner.go), python3 -m unittest discover (99 tests), supervisor check, check_import_boundary.sh, and manifest regen (build_pitot.py --write) all green locally.

…+ public README

Feature-preserving hardening across the Pitot adapter surface, guided by a
full Locus analysis (trace-refinement per adapter, supervisory-rw by host
class, nonblockingness of the router, root-cause of the two silent
degradations, ranked frontier). No adapter, transport, or observe-only mode
was removed.

Runtime / boundary:
- transport: an event-delivery fault now returns 409, not a 204 that read as
  allow (fail-open closed).
- runtime: additive strict mode — require_controller config key and
  `pitot run --strict` flag — faults instead of silently allowing when a
  declared kind has no controller; default behavior unchanged, with a
  once-per-kind observation-only notice otherwise.
- hook: one-line stderr notice when no runtime is selected (still exit 0);
  allow path now requires the response ActionID to match.
- sensor/adapters: decode-time tool-name guards per host; ActionKind no
  longer silently defaults to "shell" for unknown boundary events.
- bridge: the router's resolved-action set is now bounded (4096-entry window).
- devinacp: one-shot diagnostic when a tool_call update lacks the
  cognition.ai/inferenceToolName meta (stays fail-closed).
- doctor: PITOT_RUNTIME-unset note and a binary-hash drift check for
  non-repo-wired hosts.

Tests:
- new Go guards (adapters, sensor, bridge window, runtime strict + transport
  fault, devinacp meta, hook notice).
- new Python coverage: devin control-proxy HTTP behavior, validate_receipts
  negative branches, the two E2E apparatus binaries, and npm/kimi/cursor
  installers. Fixed a real devin-proxy save() race surfaced by the burst test.

Public README: Devin added to the supported-hosts table with a platforms
column, host admission criteria (deny-continuation) section, a threat model
that names Kimi's fail-open host semantics plainly, and a contributing guide
covering both adapter transport classes.

Disclosure-Reviewed: reviewed — public-safe only, private facet kept out of this commit
@bigboateng
bigboateng force-pushed the codex/pitot-hardening branch from bc5d813 to 1eb1450 Compare July 31, 2026 14:25
Required by the Generated distribution gate: any labs/15-pitot change ships a
release note under pitot-distribution/release-notes.

Disclosure-Reviewed: reviewed — public-safe only, private facet kept out of this commit
@github-actions

github-actions Bot commented Jul 31, 2026

Copy link
Copy Markdown

Pitot coding-agent E2E

Intelligence Flow is the verification source; Pitot's public README carries the latest main status.

Agent Ubuntu macOS Windows Result Evidence
Claude ✅ Pass · real CLI 2.1.217 · native · binary-observed anthropic messages ✅ Pass · real CLI 2.1.217 · native · binary-observed anthropic messages ✅ Pass · real CLI 2.1.217 · native · binary-observed anthropic messages ✅ Passing All platforms are required
Cursor ✅ Pass · real CLI 2026.07.20-8cc9c0b · native · binary-observed cursor connect proto ✅ Pass · real CLI 2026.07.20-8cc9c0b · native · binary-observed cursor connect proto ✅ Pass · real CLI 2026.07.20-8cc9c0b · WSL · binary-observed cursor connect proto ✅ Passing All platforms are required
Codex ✅ Pass · real CLI 0.145.0 · native · binary-observed openai responses ✅ Pass · real CLI 0.145.0 · native · binary-observed openai responses ✅ Pass · real CLI 0.145.0 · native · binary-observed openai responses ✅ Passing All platforms are required
Devin ✅ Pass · real CLI 3000.3.22 · native · binary-observed devin connect proto ✅ Pass · real CLI 3000.3.22 · native · binary-observed devin connect proto ✅ Pass · real CLI 3000.3.22 · native · binary-observed devin connect proto ✅ Passing All platforms are required
GitHub Copilot CLI ✅ Pass · real CLI 1.0.73 · native · binary-observed openai chat ✅ Pass · real CLI 1.0.73 · native · binary-observed openai chat ✅ Pass · real CLI 1.0.73 · native · binary-observed openai chat ✅ Passing All platforms are required
Gemini ✅ Pass · real CLI 0.51.0 · native · binary-observed gemini generate content ✅ Pass · real CLI 0.51.0 · native · binary-observed gemini generate content ✅ Pass · real CLI 0.51.0 · native · binary-observed gemini generate content ✅ Passing All platforms are required
Kimi Code ✅ Pass · real CLI 0.29.0 · native · binary-observed openai chat ✅ Pass · real CLI 0.29.0 · native · binary-observed openai chat ✅ Pass · real CLI 0.29.0 · native · binary-observed openai chat ✅ Passing All platforms are required
OpenCode ✅ Pass · real CLI 1.18.4 · native · binary-observed openai responses ✅ Pass · real CLI 1.18.4 · native · binary-observed openai responses ✅ Pass · real CLI 1.18.4 · native · binary-observed openai responses ✅ Passing All platforms are required
Pi ✅ Pass · real CLI 0.81.1 · native · binary-observed openai chat ✅ Pass · real CLI 0.81.1 · native · binary-observed openai chat ✅ Pass · real CLI 0.81.1 · native · binary-observed openai chat ✅ Passing All platforms are required
Qwen Code ✅ Pass · real CLI 0.20.1 · native · binary-observed openai chat ✅ Pass · real CLI 0.20.1 · native · binary-observed openai chat ✅ Pass · real CLI 0.20.1 · native · binary-observed openai chat ✅ Passing All platforms are required

Runtime capabilities

Capability Ubuntu macOS Windows Result
pitot request ✅ Pass · real runtime allow/deny ✅ Pass · real runtime allow/deny ✅ Pass · real runtime allow/deny ✅ Passing

Source commit: 005d8088c38b

@bigboateng
bigboateng merged commit b6b7e44 into main Jul 31, 2026
44 checks passed
@bigboateng
bigboateng deleted the codex/pitot-hardening branch July 31, 2026 14:36
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.

1 participant