Skip to content

0.9.0: session-start attestation — the hook proves what's running#7

Open
davidcrowe wants to merge 1 commit into
mainfrom
feat/session-attestation
Open

0.9.0: session-start attestation — the hook proves what's running#7
davidcrowe wants to merge 1 commit into
mainfrom
feat/session-attestation

Conversation

@davidcrowe

Copy link
Copy Markdown
Collaborator

Refs gatewaystack-connect#403 (layer 5: paired-arrival attestation) and #375 (capability-without-authority lesson).

Server side (gateway /govern/attest endpoint, TOFU hash registry, founder alert on mismatch, console integrity badge) ships in gatewaystack-connect PR #410 — merge that chain first so the endpoint exists; until then this attestation call 404s harmlessly (fire-and-forget, fail-open).

  • SessionStart hook added (same govern.mjs, dispatches on hook_event_name)
  • Hashes its own file as loaded from disk + reports grants-file presence/hash — the #375 pairing invariant made observable
  • Never blocks a session: dead endpoint → silent exit 0 (black-box verified); PreToolUse #385 posture regression-tested
  • Version drift fixed: manifests said 0.8.2, wire said 0.6.5 → all 0.9.0

Publish is the marketplace update (yours) — existing installs pick it up on next update; older hooks simply render as "unattested" in the console, which is the honest default.

Refs gatewaystack-connect#403 (paired-arrival), #375 (the lesson)

The #375 incident was capability arriving without authority: grants
active, hook silently detached. Attestation makes the pairing
observable. On SessionStart the hook POSTs /govern/attest with the
sha256 of its own file as loaded from disk, the plugin version, and
whether ~/.acp/harness-grants.json is present (and its hash). The
gateway compares against the first-seen hash for this version — a
changed file with an unchanged version string is the edited-hook
signature and pages the founder; sessions render an integrity badge
in the console either way, with absence shown as "unattested".

Fail-open in every branch: attestation is observability and never
delays or blocks a session — an absent attestation IS the signal.
Black-box verified: SessionStart against a dead endpoint exits 0
silently; PreToolUse keeps the #385 posture (interactive fails OPEN
loudly). 16 tests pass (4 new pin the wire contract).

Also unifies the version drift: plugin.json/marketplace.json said
0.8.2 while govern.mjs reported 0.6.5 on the wire — all now 0.9.0.
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