@sentropic/h2a-cli 0.75.0 → 0.78.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +1 -37
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -41
- package/dist/index.js.map +1 -1
- package/package.json +4 -15
- package/dist/bin.d.ts +0 -3
- package/dist/bin.d.ts.map +0 -1
- package/dist/bin.js +0 -83
- package/dist/bin.js.map +0 -1
- package/dist/cli-contract.d.ts +0 -62
- package/dist/cli-contract.d.ts.map +0 -1
- package/dist/cli-contract.js +0 -794
- package/dist/cli-contract.js.map +0 -1
- package/dist/cli.d.ts +0 -254
- package/dist/cli.d.ts.map +0 -1
- package/dist/cli.js +0 -4672
- package/dist/cli.js.map +0 -1
- package/dist/hosts/agy.d.ts +0 -14
- package/dist/hosts/agy.d.ts.map +0 -1
- package/dist/hosts/agy.js +0 -47
- package/dist/hosts/agy.js.map +0 -1
- package/dist/hosts/claude.d.ts +0 -12
- package/dist/hosts/claude.d.ts.map +0 -1
- package/dist/hosts/claude.js +0 -46
- package/dist/hosts/claude.js.map +0 -1
- package/dist/hosts/codex.d.ts +0 -65
- package/dist/hosts/codex.d.ts.map +0 -1
- package/dist/hosts/codex.js +0 -45
- package/dist/hosts/codex.js.map +0 -1
- package/dist/hosts/gemini.d.ts +0 -12
- package/dist/hosts/gemini.d.ts.map +0 -1
- package/dist/hosts/gemini.js +0 -46
- package/dist/hosts/gemini.js.map +0 -1
- package/dist/hosts/plugin.d.ts +0 -151
- package/dist/hosts/plugin.d.ts.map +0 -1
- package/dist/hosts/plugin.js +0 -188
- package/dist/hosts/plugin.js.map +0 -1
- package/dist/mcp.d.ts +0 -2
- package/dist/mcp.d.ts.map +0 -1
- package/dist/mcp.js +0 -32
- package/dist/mcp.js.map +0 -1
- package/dist/runtime/blockage/index.d.ts +0 -3
- package/dist/runtime/blockage/index.d.ts.map +0 -1
- package/dist/runtime/blockage/index.js +0 -3
- package/dist/runtime/blockage/index.js.map +0 -1
- package/dist/runtime/blockage/notifiers.d.ts +0 -52
- package/dist/runtime/blockage/notifiers.d.ts.map +0 -1
- package/dist/runtime/blockage/notifiers.js +0 -74
- package/dist/runtime/blockage/notifiers.js.map +0 -1
- package/dist/runtime/blockage/registry.d.ts +0 -30
- package/dist/runtime/blockage/registry.d.ts.map +0 -1
- package/dist/runtime/blockage/registry.js +0 -86
- package/dist/runtime/blockage/registry.js.map +0 -1
- package/dist/runtime/deploy/k8s-sidecar.d.ts +0 -92
- package/dist/runtime/deploy/k8s-sidecar.d.ts.map +0 -1
- package/dist/runtime/deploy/k8s-sidecar.js +0 -166
- package/dist/runtime/deploy/k8s-sidecar.js.map +0 -1
- package/dist/runtime/deploy/k8s-tenant.d.ts +0 -86
- package/dist/runtime/deploy/k8s-tenant.d.ts.map +0 -1
- package/dist/runtime/deploy/k8s-tenant.js +0 -255
- package/dist/runtime/deploy/k8s-tenant.js.map +0 -1
- package/dist/runtime/drive/inbox-wake.d.ts +0 -36
- package/dist/runtime/drive/inbox-wake.d.ts.map +0 -1
- package/dist/runtime/drive/inbox-wake.js +0 -50
- package/dist/runtime/drive/inbox-wake.js.map +0 -1
- package/dist/runtime/drive/index.d.ts +0 -173
- package/dist/runtime/drive/index.d.ts.map +0 -1
- package/dist/runtime/drive/index.js +0 -503
- package/dist/runtime/drive/index.js.map +0 -1
- package/dist/runtime/drumbeat/deciders.d.ts +0 -32
- package/dist/runtime/drumbeat/deciders.d.ts.map +0 -1
- package/dist/runtime/drumbeat/deciders.js +0 -65
- package/dist/runtime/drumbeat/deciders.js.map +0 -1
- package/dist/runtime/drumbeat/decisions.d.ts +0 -19
- package/dist/runtime/drumbeat/decisions.d.ts.map +0 -1
- package/dist/runtime/drumbeat/decisions.js +0 -34
- package/dist/runtime/drumbeat/decisions.js.map +0 -1
- package/dist/runtime/drumbeat/inbox-relance.d.ts +0 -29
- package/dist/runtime/drumbeat/inbox-relance.d.ts.map +0 -1
- package/dist/runtime/drumbeat/inbox-relance.js +0 -101
- package/dist/runtime/drumbeat/inbox-relance.js.map +0 -1
- package/dist/runtime/drumbeat/index.d.ts +0 -8
- package/dist/runtime/drumbeat/index.d.ts.map +0 -1
- package/dist/runtime/drumbeat/index.js +0 -8
- package/dist/runtime/drumbeat/index.js.map +0 -1
- package/dist/runtime/drumbeat/registry.d.ts +0 -60
- package/dist/runtime/drumbeat/registry.d.ts.map +0 -1
- package/dist/runtime/drumbeat/registry.js +0 -115
- package/dist/runtime/drumbeat/registry.js.map +0 -1
- package/dist/runtime/drumbeat/relaunchers.d.ts +0 -111
- package/dist/runtime/drumbeat/relaunchers.d.ts.map +0 -1
- package/dist/runtime/drumbeat/relaunchers.js +0 -260
- package/dist/runtime/drumbeat/relaunchers.js.map +0 -1
- package/dist/runtime/drumbeat/scan.d.ts +0 -36
- package/dist/runtime/drumbeat/scan.d.ts.map +0 -1
- package/dist/runtime/drumbeat/scan.js +0 -41
- package/dist/runtime/drumbeat/scan.js.map +0 -1
- package/dist/runtime/drumbeat/watch.d.ts +0 -74
- package/dist/runtime/drumbeat/watch.d.ts.map +0 -1
- package/dist/runtime/drumbeat/watch.js +0 -216
- package/dist/runtime/drumbeat/watch.js.map +0 -1
- package/dist/runtime/escalation/index.d.ts +0 -2
- package/dist/runtime/escalation/index.d.ts.map +0 -1
- package/dist/runtime/escalation/index.js +0 -2
- package/dist/runtime/escalation/index.js.map +0 -1
- package/dist/runtime/escalation/registry.d.ts +0 -44
- package/dist/runtime/escalation/registry.d.ts.map +0 -1
- package/dist/runtime/escalation/registry.js +0 -79
- package/dist/runtime/escalation/registry.js.map +0 -1
- package/dist/runtime/governance/claims.d.ts +0 -43
- package/dist/runtime/governance/claims.d.ts.map +0 -1
- package/dist/runtime/governance/claims.js +0 -93
- package/dist/runtime/governance/claims.js.map +0 -1
- package/dist/runtime/governance/conductor.d.ts +0 -79
- package/dist/runtime/governance/conductor.d.ts.map +0 -1
- package/dist/runtime/governance/conductor.js +0 -106
- package/dist/runtime/governance/conductor.js.map +0 -1
- package/dist/runtime/governance/index.d.ts +0 -5
- package/dist/runtime/governance/index.d.ts.map +0 -1
- package/dist/runtime/governance/index.js +0 -5
- package/dist/runtime/governance/index.js.map +0 -1
- package/dist/runtime/governance/launch-check.d.ts +0 -93
- package/dist/runtime/governance/launch-check.d.ts.map +0 -1
- package/dist/runtime/governance/launch-check.js +0 -113
- package/dist/runtime/governance/launch-check.js.map +0 -1
- package/dist/runtime/governance/spawns.d.ts +0 -50
- package/dist/runtime/governance/spawns.d.ts.map +0 -1
- package/dist/runtime/governance/spawns.js +0 -91
- package/dist/runtime/governance/spawns.js.map +0 -1
- package/dist/runtime/identity/bindings.d.ts +0 -84
- package/dist/runtime/identity/bindings.d.ts.map +0 -1
- package/dist/runtime/identity/bindings.js +0 -112
- package/dist/runtime/identity/bindings.js.map +0 -1
- package/dist/runtime/identity/index.d.ts +0 -11
- package/dist/runtime/identity/index.d.ts.map +0 -1
- package/dist/runtime/identity/index.js +0 -6
- package/dist/runtime/identity/index.js.map +0 -1
- package/dist/runtime/identity/live.d.ts +0 -26
- package/dist/runtime/identity/live.d.ts.map +0 -1
- package/dist/runtime/identity/live.js +0 -232
- package/dist/runtime/identity/live.js.map +0 -1
- package/dist/runtime/identity/migration.d.ts +0 -55
- package/dist/runtime/identity/migration.d.ts.map +0 -1
- package/dist/runtime/identity/migration.js +0 -100
- package/dist/runtime/identity/migration.js.map +0 -1
- package/dist/runtime/identity/readers.d.ts +0 -42
- package/dist/runtime/identity/readers.d.ts.map +0 -1
- package/dist/runtime/identity/readers.js +0 -248
- package/dist/runtime/identity/readers.js.map +0 -1
- package/dist/runtime/identity/resolver.d.ts +0 -50
- package/dist/runtime/identity/resolver.d.ts.map +0 -1
- package/dist/runtime/identity/resolver.js +0 -61
- package/dist/runtime/identity/resolver.js.map +0 -1
- package/dist/runtime/identity/workspace-id.d.ts +0 -43
- package/dist/runtime/identity/workspace-id.d.ts.map +0 -1
- package/dist/runtime/identity/workspace-id.js +0 -138
- package/dist/runtime/identity/workspace-id.js.map +0 -1
- package/dist/runtime/local-files/index.d.ts +0 -8
- package/dist/runtime/local-files/index.d.ts.map +0 -1
- package/dist/runtime/local-files/index.js +0 -8
- package/dist/runtime/local-files/index.js.map +0 -1
- package/dist/runtime/local-files/lease.d.ts +0 -62
- package/dist/runtime/local-files/lease.d.ts.map +0 -1
- package/dist/runtime/local-files/lease.js +0 -249
- package/dist/runtime/local-files/lease.js.map +0 -1
- package/dist/runtime/local-files/locks.d.ts +0 -43
- package/dist/runtime/local-files/locks.d.ts.map +0 -1
- package/dist/runtime/local-files/locks.js +0 -197
- package/dist/runtime/local-files/locks.js.map +0 -1
- package/dist/runtime/local-files/migrate.d.ts +0 -31
- package/dist/runtime/local-files/migrate.d.ts.map +0 -1
- package/dist/runtime/local-files/migrate.js +0 -104
- package/dist/runtime/local-files/migrate.js.map +0 -1
- package/dist/runtime/local-files/paths.d.ts +0 -146
- package/dist/runtime/local-files/paths.d.ts.map +0 -1
- package/dist/runtime/local-files/paths.js +0 -233
- package/dist/runtime/local-files/paths.js.map +0 -1
- package/dist/runtime/local-files/presence.d.ts +0 -80
- package/dist/runtime/local-files/presence.d.ts.map +0 -1
- package/dist/runtime/local-files/presence.js +0 -250
- package/dist/runtime/local-files/presence.js.map +0 -1
- package/dist/runtime/local-files/schema.d.ts +0 -47
- package/dist/runtime/local-files/schema.d.ts.map +0 -1
- package/dist/runtime/local-files/schema.js +0 -77
- package/dist/runtime/local-files/schema.js.map +0 -1
- package/dist/runtime/local-files/store.d.ts +0 -132
- package/dist/runtime/local-files/store.d.ts.map +0 -1
- package/dist/runtime/local-files/store.js +0 -997
- package/dist/runtime/local-files/store.js.map +0 -1
- package/dist/runtime/loop/index.d.ts +0 -73
- package/dist/runtime/loop/index.d.ts.map +0 -1
- package/dist/runtime/loop/index.js +0 -107
- package/dist/runtime/loop/index.js.map +0 -1
- package/dist/runtime/mcp/handlers.d.ts +0 -196
- package/dist/runtime/mcp/handlers.d.ts.map +0 -1
- package/dist/runtime/mcp/handlers.js +0 -1025
- package/dist/runtime/mcp/handlers.js.map +0 -1
- package/dist/runtime/mcp/index.d.ts +0 -7
- package/dist/runtime/mcp/index.d.ts.map +0 -1
- package/dist/runtime/mcp/index.js +0 -7
- package/dist/runtime/mcp/index.js.map +0 -1
- package/dist/runtime/mcp/notifications.d.ts +0 -47
- package/dist/runtime/mcp/notifications.d.ts.map +0 -1
- package/dist/runtime/mcp/notifications.js +0 -204
- package/dist/runtime/mcp/notifications.js.map +0 -1
- package/dist/runtime/mcp/server.d.ts +0 -45
- package/dist/runtime/mcp/server.d.ts.map +0 -1
- package/dist/runtime/mcp/server.js +0 -94
- package/dist/runtime/mcp/server.js.map +0 -1
- package/dist/runtime/mcp/sessions.d.ts +0 -68
- package/dist/runtime/mcp/sessions.d.ts.map +0 -1
- package/dist/runtime/mcp/sessions.js +0 -152
- package/dist/runtime/mcp/sessions.js.map +0 -1
- package/dist/runtime/mcp/stdio.d.ts +0 -72
- package/dist/runtime/mcp/stdio.d.ts.map +0 -1
- package/dist/runtime/mcp/stdio.js +0 -274
- package/dist/runtime/mcp/stdio.js.map +0 -1
- package/dist/runtime/mcp/tools.d.ts +0 -19
- package/dist/runtime/mcp/tools.d.ts.map +0 -1
- package/dist/runtime/mcp/tools.js +0 -525
- package/dist/runtime/mcp/tools.js.map +0 -1
- package/dist/runtime/mcp-http/app.d.ts +0 -33
- package/dist/runtime/mcp-http/app.d.ts.map +0 -1
- package/dist/runtime/mcp-http/app.js +0 -162
- package/dist/runtime/mcp-http/app.js.map +0 -1
- package/dist/runtime/mcp-http/hosted-mcp-server.d.ts +0 -14
- package/dist/runtime/mcp-http/hosted-mcp-server.d.ts.map +0 -1
- package/dist/runtime/mcp-http/hosted-mcp-server.js +0 -38
- package/dist/runtime/mcp-http/hosted-mcp-server.js.map +0 -1
- package/dist/runtime/mcp-http/index.d.ts +0 -18
- package/dist/runtime/mcp-http/index.d.ts.map +0 -1
- package/dist/runtime/mcp-http/index.js +0 -18
- package/dist/runtime/mcp-http/index.js.map +0 -1
- package/dist/runtime/mcp-http/main.d.ts +0 -2
- package/dist/runtime/mcp-http/main.d.ts.map +0 -1
- package/dist/runtime/mcp-http/main.js +0 -14
- package/dist/runtime/mcp-http/main.js.map +0 -1
- package/dist/runtime/mcp-http/oauth/broker-login.d.ts +0 -50
- package/dist/runtime/mcp-http/oauth/broker-login.d.ts.map +0 -1
- package/dist/runtime/mcp-http/oauth/broker-login.js +0 -41
- package/dist/runtime/mcp-http/oauth/broker-login.js.map +0 -1
- package/dist/runtime/mcp-http/oauth/broker-routes.d.ts +0 -45
- package/dist/runtime/mcp-http/oauth/broker-routes.d.ts.map +0 -1
- package/dist/runtime/mcp-http/oauth/broker-routes.js +0 -54
- package/dist/runtime/mcp-http/oauth/broker-routes.js.map +0 -1
- package/dist/runtime/mcp-http/oauth/config.d.ts +0 -49
- package/dist/runtime/mcp-http/oauth/config.d.ts.map +0 -1
- package/dist/runtime/mcp-http/oauth/config.js +0 -69
- package/dist/runtime/mcp-http/oauth/config.js.map +0 -1
- package/dist/runtime/mcp-http/oauth/crypto.d.ts +0 -14
- package/dist/runtime/mcp-http/oauth/crypto.d.ts.map +0 -1
- package/dist/runtime/mcp-http/oauth/crypto.js +0 -29
- package/dist/runtime/mcp-http/oauth/crypto.js.map +0 -1
- package/dist/runtime/mcp-http/oauth/file-store.d.ts +0 -48
- package/dist/runtime/mcp-http/oauth/file-store.d.ts.map +0 -1
- package/dist/runtime/mcp-http/oauth/file-store.js +0 -101
- package/dist/runtime/mcp-http/oauth/file-store.js.map +0 -1
- package/dist/runtime/mcp-http/oauth/hono-oauth-router.d.ts +0 -5
- package/dist/runtime/mcp-http/oauth/hono-oauth-router.d.ts.map +0 -1
- package/dist/runtime/mcp-http/oauth/hono-oauth-router.js +0 -92
- package/dist/runtime/mcp-http/oauth/hono-oauth-router.js.map +0 -1
- package/dist/runtime/mcp-http/oauth/oidc-rp.d.ts +0 -56
- package/dist/runtime/mcp-http/oauth/oidc-rp.d.ts.map +0 -1
- package/dist/runtime/mcp-http/oauth/oidc-rp.js +0 -63
- package/dist/runtime/mcp-http/oauth/oidc-rp.js.map +0 -1
- package/dist/runtime/mcp-http/oauth/redirect-uri.d.ts +0 -11
- package/dist/runtime/mcp-http/oauth/redirect-uri.d.ts.map +0 -1
- package/dist/runtime/mcp-http/oauth/redirect-uri.js +0 -29
- package/dist/runtime/mcp-http/oauth/redirect-uri.js.map +0 -1
- package/dist/runtime/mcp-http/oauth/single-tenant-provider.d.ts +0 -70
- package/dist/runtime/mcp-http/oauth/single-tenant-provider.d.ts.map +0 -1
- package/dist/runtime/mcp-http/oauth/single-tenant-provider.js +0 -247
- package/dist/runtime/mcp-http/oauth/single-tenant-provider.js.map +0 -1
- package/dist/runtime/mcp-http/oauth/tenancy.d.ts +0 -3
- package/dist/runtime/mcp-http/oauth/tenancy.d.ts.map +0 -1
- package/dist/runtime/mcp-http/oauth/tenancy.js +0 -18
- package/dist/runtime/mcp-http/oauth/tenancy.js.map +0 -1
- package/dist/runtime/mcp-http/readonly-allowlist.d.ts +0 -24
- package/dist/runtime/mcp-http/readonly-allowlist.d.ts.map +0 -1
- package/dist/runtime/mcp-http/readonly-allowlist.js +0 -43
- package/dist/runtime/mcp-http/readonly-allowlist.js.map +0 -1
- package/dist/runtime/mcp-http/serve.d.ts +0 -39
- package/dist/runtime/mcp-http/serve.d.ts.map +0 -1
- package/dist/runtime/mcp-http/serve.js +0 -100
- package/dist/runtime/mcp-http/serve.js.map +0 -1
- package/dist/runtime/mirror/accept.d.ts +0 -57
- package/dist/runtime/mirror/accept.d.ts.map +0 -1
- package/dist/runtime/mirror/accept.js +0 -70
- package/dist/runtime/mirror/accept.js.map +0 -1
- package/dist/runtime/mirror/build.d.ts +0 -44
- package/dist/runtime/mirror/build.d.ts.map +0 -1
- package/dist/runtime/mirror/build.js +0 -37
- package/dist/runtime/mirror/build.js.map +0 -1
- package/dist/runtime/mirror/index.d.ts +0 -9
- package/dist/runtime/mirror/index.d.ts.map +0 -1
- package/dist/runtime/mirror/index.js +0 -9
- package/dist/runtime/mirror/index.js.map +0 -1
- package/dist/runtime/mirror/serve.d.ts +0 -21
- package/dist/runtime/mirror/serve.d.ts.map +0 -1
- package/dist/runtime/mirror/serve.js +0 -141
- package/dist/runtime/mirror/serve.js.map +0 -1
- package/dist/runtime/nhi.d.ts +0 -15
- package/dist/runtime/nhi.d.ts.map +0 -1
- package/dist/runtime/nhi.js +0 -26
- package/dist/runtime/nhi.js.map +0 -1
- package/dist/runtime/remote/accept.d.ts +0 -50
- package/dist/runtime/remote/accept.d.ts.map +0 -1
- package/dist/runtime/remote/accept.js +0 -54
- package/dist/runtime/remote/accept.js.map +0 -1
- package/dist/runtime/remote/client.d.ts +0 -27
- package/dist/runtime/remote/client.d.ts.map +0 -1
- package/dist/runtime/remote/client.js +0 -34
- package/dist/runtime/remote/client.js.map +0 -1
- package/dist/runtime/remote/index.d.ts +0 -5
- package/dist/runtime/remote/index.d.ts.map +0 -1
- package/dist/runtime/remote/index.js +0 -5
- package/dist/runtime/remote/index.js.map +0 -1
- package/dist/runtime/remote/serve.d.ts +0 -27
- package/dist/runtime/remote/serve.d.ts.map +0 -1
- package/dist/runtime/remote/serve.js +0 -26
- package/dist/runtime/remote/serve.js.map +0 -1
- package/dist/runtime/remote/server.d.ts +0 -36
- package/dist/runtime/remote/server.d.ts.map +0 -1
- package/dist/runtime/remote/server.js +0 -100
- package/dist/runtime/remote/server.js.map +0 -1
- package/dist/runtime/sysml/client.d.ts +0 -44
- package/dist/runtime/sysml/client.d.ts.map +0 -1
- package/dist/runtime/sysml/client.js +0 -52
- package/dist/runtime/sysml/client.js.map +0 -1
- package/dist/runtime/sysml/disclosure.d.ts +0 -23
- package/dist/runtime/sysml/disclosure.d.ts.map +0 -1
- package/dist/runtime/sysml/disclosure.js +0 -53
- package/dist/runtime/sysml/disclosure.js.map +0 -1
- package/dist/runtime/sysml/index.d.ts +0 -4
- package/dist/runtime/sysml/index.d.ts.map +0 -1
- package/dist/runtime/sysml/index.js +0 -4
- package/dist/runtime/sysml/index.js.map +0 -1
- package/dist/runtime/sysml/verify.d.ts +0 -32
- package/dist/runtime/sysml/verify.d.ts.map +0 -1
- package/dist/runtime/sysml/verify.js +0 -67
- package/dist/runtime/sysml/verify.js.map +0 -1
- package/dist/runtime/upgrade/index.d.ts +0 -96
- package/dist/runtime/upgrade/index.d.ts.map +0 -1
- package/dist/runtime/upgrade/index.js +0 -185
- package/dist/runtime/upgrade/index.js.map +0 -1
- package/dist/runtime/version/agent-version.d.ts +0 -15
- package/dist/runtime/version/agent-version.d.ts.map +0 -1
- package/dist/runtime/version/agent-version.js +0 -53
- package/dist/runtime/version/agent-version.js.map +0 -1
- package/skills/h2a/SKILL.md +0 -345
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* EVO-13 P1 — ingestion trust boundary for an instance mirror (DEC-125).
|
|
3
|
-
*
|
|
4
|
-
* Reuses the EVO-11 verification primitives (`verifyEnvelopeSignature` +
|
|
5
|
-
* `H2AReplayGuard`). Authority is **possession of a key the operator enrolled**,
|
|
6
|
-
* never a self-declared instance id and never a shared bearer token (the Opus
|
|
7
|
-
* review rejected both). Two safeguards, both keyed on the VERIFIED signing key:
|
|
8
|
-
* 1. the envelope must verify against a registry key for the signer OR an
|
|
9
|
-
* operator-enrolled key (`enrolledKeys`) — an unknown key is refused (no
|
|
10
|
-
* trust-on-first-use across the remote boundary);
|
|
11
|
-
* 2. a registration is applied only if its `publicKeys` contains the verified
|
|
12
|
-
* key — an agent can mirror ONLY its own identity (no namespace squatting).
|
|
13
|
-
*
|
|
14
|
-
* Never throws on rejection; only the caller-supplied `applyRegistration` may.
|
|
15
|
-
*/
|
|
16
|
-
import { type H2AActorRegistration, type H2AReplayGuard, type H2ASession, type H2ASubagentBinding } from "@sentropic/h2a";
|
|
17
|
-
export type H2AMirrorRejection = "malformed" | "not-mirror" | "no-signature" | "unauthorized-key" | "bad-signature" | "invalid-timestamp" | "expired" | "future" | "replayed" | "stale-sequence" | "instance-key-mismatch";
|
|
18
|
-
export type H2AMirrorResult = {
|
|
19
|
-
ok: true;
|
|
20
|
-
applied: string[];
|
|
21
|
-
signer: string;
|
|
22
|
-
} | {
|
|
23
|
-
ok: false;
|
|
24
|
-
reason: H2AMirrorRejection;
|
|
25
|
-
};
|
|
26
|
-
export interface AcceptMirrorOptions {
|
|
27
|
-
/** Active public-key PEMs already registered for the signer (registry + keyring, minus revoked). */
|
|
28
|
-
resolvePublicKeys: (signerInstance: string) => string[];
|
|
29
|
-
/** Operator-enrolled key PEMs allowed to mirror/bootstrap (out-of-band trust, not a wire token). */
|
|
30
|
-
enrolledKeys: readonly string[];
|
|
31
|
-
/** Replay guard (DEC-074) — its freshness window also enforces timestamp checks. */
|
|
32
|
-
guard: H2AReplayGuard;
|
|
33
|
-
/** Apply an authorized registration to the local (remote-side) store. */
|
|
34
|
-
applyRegistration: (registration: H2AActorRegistration) => void;
|
|
35
|
-
/**
|
|
36
|
-
* P2: apply a presence session (the impl RE-STAMPS heartbeatAt with the remote
|
|
37
|
-
* clock so freshness derives from the beat). Only called for sessions whose
|
|
38
|
-
* instance is owned by the verified key. Omit to ignore presence (P1 behavior).
|
|
39
|
-
*/
|
|
40
|
-
applyPresence?: (session: H2ASession) => void;
|
|
41
|
-
/**
|
|
42
|
-
* P2 fencing: return true iff `seq` is strictly newer than the last applied
|
|
43
|
-
* for `signerInstance` (and record it). Return false to reject a stale/replayed
|
|
44
|
-
* beat. Omit to skip fencing (P1 behavior).
|
|
45
|
-
*/
|
|
46
|
-
fenceSequence?: (signerInstance: string, seq: number) => boolean;
|
|
47
|
-
/**
|
|
48
|
-
* P3: apply a subagent binding (the impl is idempotent — a known binding is a
|
|
49
|
-
* no-op). Only called for bindings whose `parentInstance` is owned by the
|
|
50
|
-
* verified key. Omit to ignore subagents (P1/P2 behavior).
|
|
51
|
-
*/
|
|
52
|
-
applySubagent?: (binding: H2ASubagentBinding) => void;
|
|
53
|
-
/** Reference time (ms epoch) for the guard. Defaults to `Date.now()`. */
|
|
54
|
-
now?: number;
|
|
55
|
-
}
|
|
56
|
-
export declare function acceptMirrorEnvelope(payload: unknown, options: AcceptMirrorOptions): H2AMirrorResult;
|
|
57
|
-
//# sourceMappingURL=accept.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"accept.d.ts","sourceRoot":"","sources":["../../../src/runtime/mirror/accept.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AACH,OAAO,EAGL,KAAK,oBAAoB,EAGzB,KAAK,cAAc,EACnB,KAAK,UAAU,EACf,KAAK,kBAAkB,EACxB,MAAM,gBAAgB,CAAC;AAIxB,MAAM,MAAM,kBAAkB,GAC1B,WAAW,GACX,YAAY,GACZ,cAAc,GACd,kBAAkB,GAClB,eAAe,GACf,mBAAmB,GACnB,SAAS,GACT,QAAQ,GACR,UAAU,GACV,gBAAgB,GAChB,uBAAuB,CAAC;AAE5B,MAAM,MAAM,eAAe,GACvB;IAAE,EAAE,EAAE,IAAI,CAAC;IAAC,OAAO,EAAE,MAAM,EAAE,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,GAC/C;IAAE,EAAE,EAAE,KAAK,CAAC;IAAC,MAAM,EAAE,kBAAkB,CAAA;CAAE,CAAC;AAE9C,MAAM,WAAW,mBAAmB;IAClC,oGAAoG;IACpG,iBAAiB,EAAE,CAAC,cAAc,EAAE,MAAM,KAAK,MAAM,EAAE,CAAC;IACxD,oGAAoG;IACpG,YAAY,EAAE,SAAS,MAAM,EAAE,CAAC;IAChC,oFAAoF;IACpF,KAAK,EAAE,cAAc,CAAC;IACtB,yEAAyE;IACzE,iBAAiB,EAAE,CAAC,YAAY,EAAE,oBAAoB,KAAK,IAAI,CAAC;IAChE;;;;OAIG;IACH,aAAa,CAAC,EAAE,CAAC,OAAO,EAAE,UAAU,KAAK,IAAI,CAAC;IAC9C;;;;OAIG;IACH,aAAa,CAAC,EAAE,CAAC,cAAc,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,KAAK,OAAO,CAAC;IACjE;;;;OAIG;IACH,aAAa,CAAC,EAAE,CAAC,OAAO,EAAE,kBAAkB,KAAK,IAAI,CAAC;IACtD,yEAAyE;IACzE,GAAG,CAAC,EAAE,MAAM,CAAC;CACd;AAED,wBAAgB,oBAAoB,CAAC,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,mBAAmB,GAAG,eAAe,CAsDpG"}
|
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* EVO-13 P1 — ingestion trust boundary for an instance mirror (DEC-125).
|
|
3
|
-
*
|
|
4
|
-
* Reuses the EVO-11 verification primitives (`verifyEnvelopeSignature` +
|
|
5
|
-
* `H2AReplayGuard`). Authority is **possession of a key the operator enrolled**,
|
|
6
|
-
* never a self-declared instance id and never a shared bearer token (the Opus
|
|
7
|
-
* review rejected both). Two safeguards, both keyed on the VERIFIED signing key:
|
|
8
|
-
* 1. the envelope must verify against a registry key for the signer OR an
|
|
9
|
-
* operator-enrolled key (`enrolledKeys`) — an unknown key is refused (no
|
|
10
|
-
* trust-on-first-use across the remote boundary);
|
|
11
|
-
* 2. a registration is applied only if its `publicKeys` contains the verified
|
|
12
|
-
* key — an agent can mirror ONLY its own identity (no namespace squatting).
|
|
13
|
-
*
|
|
14
|
-
* Never throws on rejection; only the caller-supplied `applyRegistration` may.
|
|
15
|
-
*/
|
|
16
|
-
import { isH2AEnvelope, verifyEnvelopeSignature } from "@sentropic/h2a";
|
|
17
|
-
import { H2A_MIRROR_BODY_KIND } from "./build.js";
|
|
18
|
-
export function acceptMirrorEnvelope(payload, options) {
|
|
19
|
-
if (!isH2AEnvelope(payload))
|
|
20
|
-
return { ok: false, reason: "malformed" };
|
|
21
|
-
const envelope = payload;
|
|
22
|
-
const body = envelope.body;
|
|
23
|
-
if (!body || body.kind !== H2A_MIRROR_BODY_KIND || !Array.isArray(body.registrations)) {
|
|
24
|
-
return { ok: false, reason: "not-mirror" };
|
|
25
|
-
}
|
|
26
|
-
const signer = envelope.actor.instance;
|
|
27
|
-
if (!(envelope.signatures ?? []).some((s) => s.by === signer)) {
|
|
28
|
-
return { ok: false, reason: "no-signature" };
|
|
29
|
-
}
|
|
30
|
-
const candidates = Array.from(new Set([...options.resolvePublicKeys(signer), ...options.enrolledKeys]));
|
|
31
|
-
if (candidates.length === 0)
|
|
32
|
-
return { ok: false, reason: "unauthorized-key" };
|
|
33
|
-
const verifiedPem = candidates.find((pem) => verifyEnvelopeSignature(envelope, pem, { by: signer }));
|
|
34
|
-
if (!verifiedPem)
|
|
35
|
-
return { ok: false, reason: "bad-signature" };
|
|
36
|
-
// Namespacing: only registrations whose publicKeys include the verified key —
|
|
37
|
-
// an agent can publish ONLY its own identity. Checked BEFORE the guard so a
|
|
38
|
-
// wholly-unauthorized payload does not consume the envelope id.
|
|
39
|
-
const authorized = body.registrations.filter((reg) => Array.isArray(reg.publicKeys) && reg.publicKeys.includes(verifiedPem));
|
|
40
|
-
if (authorized.length === 0)
|
|
41
|
-
return { ok: false, reason: "instance-key-mismatch" };
|
|
42
|
-
const replay = options.guard.accept(envelope, options.now);
|
|
43
|
-
if (!replay.ok)
|
|
44
|
-
return { ok: false, reason: replay.reason };
|
|
45
|
-
// P2 monotonic fencing — after replay/freshness so a stale beat (new id, fresh
|
|
46
|
-
// window) still can't regress/resurrect state across a guard reset/restart.
|
|
47
|
-
if (typeof body.seq === "number" && options.fenceSequence) {
|
|
48
|
-
if (!options.fenceSequence(signer, body.seq))
|
|
49
|
-
return { ok: false, reason: "stale-sequence" };
|
|
50
|
-
}
|
|
51
|
-
for (const reg of authorized)
|
|
52
|
-
options.applyRegistration(reg);
|
|
53
|
-
const owned = new Set(authorized.map((r) => r.instance ?? r.id));
|
|
54
|
-
// P2 presence — only sessions whose instance the verified key owns.
|
|
55
|
-
if (options.applyPresence && Array.isArray(body.presence)) {
|
|
56
|
-
for (const session of body.presence) {
|
|
57
|
-
if (owned.has(session.instance))
|
|
58
|
-
options.applyPresence(session);
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
// P3 subagents — only bindings whose parent the verified key owns.
|
|
62
|
-
if (options.applySubagent && Array.isArray(body.subagents)) {
|
|
63
|
-
for (const binding of body.subagents) {
|
|
64
|
-
if (owned.has(binding.parentInstance))
|
|
65
|
-
options.applySubagent(binding);
|
|
66
|
-
}
|
|
67
|
-
}
|
|
68
|
-
return { ok: true, applied: authorized.map((r) => r.instance ?? r.id), signer };
|
|
69
|
-
}
|
|
70
|
-
//# sourceMappingURL=accept.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"accept.js","sourceRoot":"","sources":["../../../src/runtime/mirror/accept.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AACH,OAAO,EACL,aAAa,EACb,uBAAuB,EAOxB,MAAM,gBAAgB,CAAC;AAExB,OAAO,EAAE,oBAAoB,EAA8B,MAAM,YAAY,CAAC;AAkD9E,MAAM,UAAU,oBAAoB,CAAC,OAAgB,EAAE,OAA4B;IACjF,IAAI,CAAC,aAAa,CAAC,OAAO,CAAC;QAAE,OAAO,EAAE,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,WAAW,EAAE,CAAC;IACvE,MAAM,QAAQ,GAAG,OAA6C,CAAC;IAC/D,MAAM,IAAI,GAAG,QAAQ,CAAC,IAAI,CAAC;IAC3B,IAAI,CAAC,IAAI,IAAI,IAAI,CAAC,IAAI,KAAK,oBAAoB,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC,aAAa,CAAC,EAAE,CAAC;QACtF,OAAO,EAAE,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,YAAY,EAAE,CAAC;IAC7C,CAAC;IAED,MAAM,MAAM,GAAG,QAAQ,CAAC,KAAK,CAAC,QAAQ,CAAC;IACvC,IAAI,CAAC,CAAC,QAA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,OAAO,CAAC,CAAC;QACxE,CAAC;IACH,CAAC;IAED,OAAO,EAAE,EAAE,EAAE,IAAI,EAAE,OAAO,EAAE,UAAU,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,QAAQ,IAAI,CAAC,CAAC,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC;AAClF,CAAC"}
|
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* EVO-13 P1 — build an "instance mirror": the local instance's OWN registration,
|
|
3
|
-
* wrapped in an h2a envelope ready to be signed and pushed to a remote h2a so
|
|
4
|
-
* its read-only surface (`h2a_discover_instances`) reflects this live agent.
|
|
5
|
-
*
|
|
6
|
-
* P1 replicates instances only (registry). Presence (P2) and NHI (P3) extend the
|
|
7
|
-
* same envelope with more event kinds. The private key never leaves the agent;
|
|
8
|
-
* `buildInstanceMirror` returns an UNSIGNED envelope — the caller signs it with
|
|
9
|
-
* `signEnvelope` (DEC-116: possession of the key is the sole authority anchor).
|
|
10
|
-
*/
|
|
11
|
-
import { type H2AActorRegistration, type H2AEnvelope, type H2ASession, type H2ASubagentBinding } from "@sentropic/h2a";
|
|
12
|
-
import { type LocalStore } from "../local-files/index.js";
|
|
13
|
-
export declare const H2A_MIRROR_BODY_KIND: "mirror.instances";
|
|
14
|
-
export interface H2AInstanceMirrorBody {
|
|
15
|
-
readonly kind: typeof H2A_MIRROR_BODY_KIND;
|
|
16
|
-
/** Append-only registration events. P1: the sender's own registration only. */
|
|
17
|
-
readonly registrations: H2AActorRegistration[];
|
|
18
|
-
/**
|
|
19
|
-
* P2: the sender's live sessions. The remote RE-STAMPS `heartbeatAt` with its
|
|
20
|
-
* own clock on arrival (freshness is derived from the mirror beat, not the
|
|
21
|
-
* local clock — no ghost/skew/resurrection). Omitted in P1-only callers.
|
|
22
|
-
*/
|
|
23
|
-
readonly presence?: H2ASession[];
|
|
24
|
-
/**
|
|
25
|
-
* P2: monotonic per-instance sequence (the CLI uses epoch ms — increases
|
|
26
|
-
* across restarts). The remote rejects a mirror with `seq <= last applied`
|
|
27
|
-
* (fencing), so a replayed older beat cannot resurrect stale presence.
|
|
28
|
-
*/
|
|
29
|
-
readonly seq?: number;
|
|
30
|
-
/**
|
|
31
|
-
* P3: the sender's subagent bindings (NHI inventory). Append-only on the
|
|
32
|
-
* remote (idempotent — re-mirroring a known binding is a no-op). Only bindings
|
|
33
|
-
* whose `parentInstance` the verified key owns are applied. Omitted in P1/P2.
|
|
34
|
-
*/
|
|
35
|
-
readonly subagents?: H2ASubagentBinding[];
|
|
36
|
-
}
|
|
37
|
-
/**
|
|
38
|
-
* Build the unsigned mirror envelope for `instance` from the local store.
|
|
39
|
-
* `nowMs` is injected (epoch ms) so the id + createdAt + seq are deterministic
|
|
40
|
-
* in tests; the CLI verb passes `Date.now()`. Includes the instance's own live
|
|
41
|
-
* sessions (P2) so the remote can derive its presence.
|
|
42
|
-
*/
|
|
43
|
-
export declare function buildInstanceMirror(store: LocalStore, instance: string, nowMs: number): H2AEnvelope<H2AInstanceMirrorBody>;
|
|
44
|
-
//# sourceMappingURL=build.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"build.d.ts","sourceRoot":"","sources":["../../../src/runtime/mirror/build.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,OAAO,EAGL,KAAK,oBAAoB,EACzB,KAAK,WAAW,EAChB,KAAK,UAAU,EACf,KAAK,kBAAkB,EACxB,MAAM,gBAAgB,CAAC;AAExB,OAAO,EAAgB,KAAK,UAAU,EAAE,MAAM,yBAAyB,CAAC;AAExE,eAAO,MAAM,oBAAoB,EAAG,kBAA2B,CAAC;AAEhE,MAAM,WAAW,qBAAqB;IACpC,QAAQ,CAAC,IAAI,EAAE,OAAO,oBAAoB,CAAC;IAC3C,+EAA+E;IAC/E,QAAQ,CAAC,aAAa,EAAE,oBAAoB,EAAE,CAAC;IAC/C;;;;OAIG;IACH,QAAQ,CAAC,QAAQ,CAAC,EAAE,UAAU,EAAE,CAAC;IACjC;;;;OAIG;IACH,QAAQ,CAAC,GAAG,CAAC,EAAE,MAAM,CAAC;IACtB;;;;OAIG;IACH,QAAQ,CAAC,SAAS,CAAC,EAAE,kBAAkB,EAAE,CAAC;CAC3C;AAED;;;;;GAKG;AACH,wBAAgB,mBAAmB,CACjC,KAAK,EAAE,UAAU,EACjB,QAAQ,EAAE,MAAM,EAChB,KAAK,EAAE,MAAM,GACZ,WAAW,CAAC,qBAAqB,CAAC,CAiBpC"}
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* EVO-13 P1 — build an "instance mirror": the local instance's OWN registration,
|
|
3
|
-
* wrapped in an h2a envelope ready to be signed and pushed to a remote h2a so
|
|
4
|
-
* its read-only surface (`h2a_discover_instances`) reflects this live agent.
|
|
5
|
-
*
|
|
6
|
-
* P1 replicates instances only (registry). Presence (P2) and NHI (P3) extend the
|
|
7
|
-
* same envelope with more event kinds. The private key never leaves the agent;
|
|
8
|
-
* `buildInstanceMirror` returns an UNSIGNED envelope — the caller signs it with
|
|
9
|
-
* `signEnvelope` (DEC-116: possession of the key is the sole authority anchor).
|
|
10
|
-
*/
|
|
11
|
-
import { H2A_PROTOCOL, H2A_VERSION } from "@sentropic/h2a";
|
|
12
|
-
import { listPresence } from "../local-files/index.js";
|
|
13
|
-
export const H2A_MIRROR_BODY_KIND = "mirror.instances";
|
|
14
|
-
/**
|
|
15
|
-
* Build the unsigned mirror envelope for `instance` from the local store.
|
|
16
|
-
* `nowMs` is injected (epoch ms) so the id + createdAt + seq are deterministic
|
|
17
|
-
* in tests; the CLI verb passes `Date.now()`. Includes the instance's own live
|
|
18
|
-
* sessions (P2) so the remote can derive its presence.
|
|
19
|
-
*/
|
|
20
|
-
export function buildInstanceMirror(store, instance, nowMs) {
|
|
21
|
-
const reg = store.findInstance(instance);
|
|
22
|
-
if (!reg)
|
|
23
|
-
throw new Error(`mirror: unknown local instance ${instance}`);
|
|
24
|
-
const presence = listPresence(store.paths.root, { now: nowMs }).filter((s) => s.instance === instance);
|
|
25
|
-
const subagents = store.listSubagentsOf(instance);
|
|
26
|
-
return {
|
|
27
|
-
protocol: H2A_PROTOCOL,
|
|
28
|
-
version: H2A_VERSION,
|
|
29
|
-
id: `mirror:${instance}:${nowMs}`,
|
|
30
|
-
type: "event",
|
|
31
|
-
actor: { instance, role: reg.roles?.[0] ?? "AGENTS", scope: "scope:default" },
|
|
32
|
-
target: { instance },
|
|
33
|
-
body: { kind: H2A_MIRROR_BODY_KIND, registrations: [reg], presence, seq: nowMs, subagents },
|
|
34
|
-
createdAt: new Date(nowMs).toISOString()
|
|
35
|
-
};
|
|
36
|
-
}
|
|
37
|
-
//# sourceMappingURL=build.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"build.js","sourceRoot":"","sources":["../../../src/runtime/mirror/build.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,OAAO,EACL,YAAY,EACZ,WAAW,EAKZ,MAAM,gBAAgB,CAAC;AAExB,OAAO,EAAE,YAAY,EAAmB,MAAM,yBAAyB,CAAC;AAExE,MAAM,CAAC,MAAM,oBAAoB,GAAG,kBAA2B,CAAC;AA0BhE;;;;;GAKG;AACH,MAAM,UAAU,mBAAmB,CACjC,KAAiB,EACjB,QAAgB,EAChB,KAAa;IAEb,MAAM,GAAG,GAAG,KAAK,CAAC,YAAY,CAAC,QAAQ,CAAC,CAAC;IACzC,IAAI,CAAC,GAAG;QAAE,MAAM,IAAI,KAAK,CAAC,kCAAkC,QAAQ,EAAE,CAAC,CAAC;IACxE,MAAM,QAAQ,GAAG,YAAY,CAAC,KAAK,CAAC,KAAK,CAAC,IAAI,EAAE,EAAE,GAAG,EAAE,KAAK,EAAE,CAAC,CAAC,MAAM,CACpE,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,QAAQ,KAAK,QAAQ,CAC/B,CAAC;IACF,MAAM,SAAS,GAAG,KAAK,CAAC,eAAe,CAAC,QAAQ,CAAC,CAAC;IAClD,OAAO;QACL,QAAQ,EAAE,YAAY;QACtB,OAAO,EAAE,WAAW;QACpB,EAAE,EAAE,UAAU,QAAQ,IAAI,KAAK,EAAE;QACjC,IAAI,EAAE,OAAO;QACb,KAAK,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,GAAG,CAAC,KAAK,EAAE,CAAC,CAAC,CAAC,IAAI,QAAQ,EAAE,KAAK,EAAE,eAAe,EAAE;QAC7E,MAAM,EAAE,EAAE,QAAQ,EAAE;QACpB,IAAI,EAAE,EAAE,IAAI,EAAE,oBAAoB,EAAE,aAAa,EAAE,CAAC,GAAG,CAAC,EAAE,QAAQ,EAAE,GAAG,EAAE,KAAK,EAAE,SAAS,EAAE;QAC3F,SAAS,EAAE,IAAI,IAAI,CAAC,KAAK,CAAC,CAAC,WAAW,EAAE;KACzC,CAAC;AACJ,CAAC"}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* EVO-13 — remote presence mirror (DEC-125). Local agents push signed snapshots
|
|
3
|
-
* of their state to a remote h2a so its read-only surface reflects reality.
|
|
4
|
-
* P1: instances only. Core stays dep-free; this lives in @sentropic/h2a-cli.
|
|
5
|
-
*/
|
|
6
|
-
export { buildInstanceMirror, H2A_MIRROR_BODY_KIND, type H2AInstanceMirrorBody } from "./build.js";
|
|
7
|
-
export { acceptMirrorEnvelope, type AcceptMirrorOptions, type H2AMirrorRejection, type H2AMirrorResult } from "./accept.js";
|
|
8
|
-
export { mirrorServerForStore, mirrorRejectionStatus, type MirrorServerForStoreOptions } from "./serve.js";
|
|
9
|
-
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/runtime/mirror/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EACL,mBAAmB,EACnB,oBAAoB,EACpB,KAAK,qBAAqB,EAC3B,MAAM,YAAY,CAAC;AACpB,OAAO,EACL,oBAAoB,EACpB,KAAK,mBAAmB,EACxB,KAAK,kBAAkB,EACvB,KAAK,eAAe,EACrB,MAAM,aAAa,CAAC;AACrB,OAAO,EACL,oBAAoB,EACpB,qBAAqB,EACrB,KAAK,2BAA2B,EACjC,MAAM,YAAY,CAAC"}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* EVO-13 — remote presence mirror (DEC-125). Local agents push signed snapshots
|
|
3
|
-
* of their state to a remote h2a so its read-only surface reflects reality.
|
|
4
|
-
* P1: instances only. Core stays dep-free; this lives in @sentropic/h2a-cli.
|
|
5
|
-
*/
|
|
6
|
-
export { buildInstanceMirror, H2A_MIRROR_BODY_KIND } from "./build.js";
|
|
7
|
-
export { acceptMirrorEnvelope } from "./accept.js";
|
|
8
|
-
export { mirrorServerForStore, mirrorRejectionStatus } from "./serve.js";
|
|
9
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/runtime/mirror/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EACL,mBAAmB,EACnB,oBAAoB,EAErB,MAAM,YAAY,CAAC;AACpB,OAAO,EACL,oBAAoB,EAIrB,MAAM,aAAa,CAAC;AACrB,OAAO,EACL,oBAAoB,EACpB,qBAAqB,EAEtB,MAAM,YAAY,CAAC"}
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { type Server } from "node:http";
|
|
2
|
-
import { type H2AReplayGuard } from "@sentropic/h2a";
|
|
3
|
-
import { type LocalStore } from "../local-files/index.js";
|
|
4
|
-
import { type H2AMirrorRejection } from "./accept.js";
|
|
5
|
-
export interface MirrorServerForStoreOptions {
|
|
6
|
-
/** Operator-enrolled key PEMs allowed to mirror/bootstrap (out-of-band trust). */
|
|
7
|
-
enrolledKeys?: readonly string[];
|
|
8
|
-
/** POST endpoint path. Default `/h2a/mirror`. */
|
|
9
|
-
path?: string;
|
|
10
|
-
/** Shared replay guard. Defaults to a fresh in-memory guard. */
|
|
11
|
-
guard?: H2AReplayGuard;
|
|
12
|
-
/** Body-size cap (bytes). Default 256 KiB. */
|
|
13
|
-
maxBodyBytes?: number;
|
|
14
|
-
/** Clock source handed to the guard. Defaults to `Date.now`. */
|
|
15
|
-
now?: () => number;
|
|
16
|
-
}
|
|
17
|
-
/** Map a mirror-pipeline rejection to an HTTP status code. */
|
|
18
|
-
export declare function mirrorRejectionStatus(reason: H2AMirrorRejection): number;
|
|
19
|
-
/** Build (unstarted) the mirror ingester bound to `store`. */
|
|
20
|
-
export declare function mirrorServerForStore(store: LocalStore, options?: MirrorServerForStoreOptions): Server;
|
|
21
|
-
//# sourceMappingURL=serve.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"serve.d.ts","sourceRoot":"","sources":["../../../src/runtime/mirror/serve.ts"],"names":[],"mappings":"AAUA,OAAO,EAAgB,KAAK,MAAM,EAAE,MAAM,WAAW,CAAC;AAGtD,OAAO,EAAqB,KAAK,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAExE,OAAO,EAAgD,KAAK,UAAU,EAAE,MAAM,yBAAyB,CAAC;AACxG,OAAO,EAAwB,KAAK,kBAAkB,EAAE,MAAM,aAAa,CAAC;AA+B5E,MAAM,WAAW,2BAA2B;IAC1C,kFAAkF;IAClF,YAAY,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IACjC,iDAAiD;IACjD,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,gEAAgE;IAChE,KAAK,CAAC,EAAE,cAAc,CAAC;IACvB,8CAA8C;IAC9C,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,gEAAgE;IAChE,GAAG,CAAC,EAAE,MAAM,MAAM,CAAC;CACpB;AAED,8DAA8D;AAC9D,wBAAgB,qBAAqB,CAAC,MAAM,EAAE,kBAAkB,GAAG,MAAM,CAmBxE;AAED,8DAA8D;AAC9D,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,UAAU,EAAE,OAAO,GAAE,2BAAgC,GAAG,MAAM,CAoEzG"}
|
|
@@ -1,141 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* EVO-13 P1 — HTTP ingester for instance mirrors. A thin, channel-untrusting
|
|
3
|
-
* front-end over `acceptMirrorEnvelope`: it reads a POSTed signed mirror and,
|
|
4
|
-
* on success, applies the registration to the store via `registerInstance`.
|
|
5
|
-
*
|
|
6
|
-
* Runs as a SEPARATE deployment from the read-only MCP pod (it writes the store;
|
|
7
|
-
* the MCP surface only reads it), co-mounting the RWX PVC. Store-agnostic +
|
|
8
|
-
* unit-testable; the k8s wiring is the deploy kit.
|
|
9
|
-
*/
|
|
10
|
-
import { mkdirSync, readFileSync, writeFileSync } from "node:fs";
|
|
11
|
-
import { createServer } from "node:http";
|
|
12
|
-
import { join } from "node:path";
|
|
13
|
-
import { createReplayGuard } from "@sentropic/h2a";
|
|
14
|
-
import { localStorePaths, withLockSync, writePresence } from "../local-files/index.js";
|
|
15
|
-
import { acceptMirrorEnvelope } from "./accept.js";
|
|
16
|
-
/**
|
|
17
|
-
* Durable, per-instance monotonic fence (P2). Returns a predicate that accepts
|
|
18
|
-
* `seq` iff it is strictly greater than the last recorded for `instance`, under
|
|
19
|
-
* a lock so concurrent beats from one agent can't race. Survives restarts (the
|
|
20
|
-
* in-memory replay guard does not), so a replayed older beat cannot resurrect
|
|
21
|
-
* stale presence after the ingester restarts.
|
|
22
|
-
*/
|
|
23
|
-
function makeSequenceFence(root) {
|
|
24
|
-
const dir = join(localStorePaths(root).root, "identity");
|
|
25
|
-
const file = join(dir, "mirror-seq.json");
|
|
26
|
-
const lock = join(dir, ".mirror-seq.lock");
|
|
27
|
-
return (instance, seq) => {
|
|
28
|
-
mkdirSync(dir, { recursive: true });
|
|
29
|
-
return withLockSync(lock, () => {
|
|
30
|
-
let map = {};
|
|
31
|
-
try {
|
|
32
|
-
const parsed = JSON.parse(readFileSync(file, "utf8"));
|
|
33
|
-
if (parsed && typeof parsed === "object")
|
|
34
|
-
map = parsed;
|
|
35
|
-
}
|
|
36
|
-
catch {
|
|
37
|
-
map = {};
|
|
38
|
-
}
|
|
39
|
-
if (seq <= (map[instance] ?? 0))
|
|
40
|
-
return false;
|
|
41
|
-
map[instance] = seq;
|
|
42
|
-
writeFileSync(file, `${JSON.stringify(map)}\n`, "utf8");
|
|
43
|
-
return true;
|
|
44
|
-
});
|
|
45
|
-
};
|
|
46
|
-
}
|
|
47
|
-
/** Map a mirror-pipeline rejection to an HTTP status code. */
|
|
48
|
-
export function mirrorRejectionStatus(reason) {
|
|
49
|
-
switch (reason) {
|
|
50
|
-
case "malformed":
|
|
51
|
-
case "not-mirror":
|
|
52
|
-
case "no-signature":
|
|
53
|
-
case "instance-key-mismatch":
|
|
54
|
-
case "invalid-timestamp":
|
|
55
|
-
return 400;
|
|
56
|
-
case "unauthorized-key":
|
|
57
|
-
case "bad-signature":
|
|
58
|
-
return 401;
|
|
59
|
-
case "replayed":
|
|
60
|
-
return 409;
|
|
61
|
-
case "expired":
|
|
62
|
-
case "future":
|
|
63
|
-
return 422;
|
|
64
|
-
default:
|
|
65
|
-
return 400;
|
|
66
|
-
}
|
|
67
|
-
}
|
|
68
|
-
/** Build (unstarted) the mirror ingester bound to `store`. */
|
|
69
|
-
export function mirrorServerForStore(store, options = {}) {
|
|
70
|
-
const guard = options.guard ?? createReplayGuard();
|
|
71
|
-
const enrolledKeys = options.enrolledKeys ?? [];
|
|
72
|
-
const path = options.path ?? "/h2a/mirror";
|
|
73
|
-
const maxBodyBytes = options.maxBodyBytes ?? 256 * 1024;
|
|
74
|
-
const root = store.paths.root;
|
|
75
|
-
const fenceSequence = makeSequenceFence(root);
|
|
76
|
-
return createServer((req, res) => {
|
|
77
|
-
const respond = (status, body) => {
|
|
78
|
-
res.writeHead(status, { "content-type": "application/json" });
|
|
79
|
-
res.end(JSON.stringify(body));
|
|
80
|
-
};
|
|
81
|
-
if ((req.url ?? "").split("?")[0] !== path)
|
|
82
|
-
return respond(404, { ok: false, error: "not-found" });
|
|
83
|
-
if (req.method !== "POST") {
|
|
84
|
-
res.setHeader("allow", "POST");
|
|
85
|
-
return respond(405, { ok: false, error: "method-not-allowed" });
|
|
86
|
-
}
|
|
87
|
-
const chunks = [];
|
|
88
|
-
let total = 0;
|
|
89
|
-
let aborted = false;
|
|
90
|
-
req.on("data", (chunk) => {
|
|
91
|
-
if (aborted)
|
|
92
|
-
return;
|
|
93
|
-
total += chunk.length;
|
|
94
|
-
if (total > maxBodyBytes) {
|
|
95
|
-
aborted = true;
|
|
96
|
-
respond(413, { ok: false, error: "payload-too-large" });
|
|
97
|
-
req.destroy();
|
|
98
|
-
return;
|
|
99
|
-
}
|
|
100
|
-
chunks.push(chunk);
|
|
101
|
-
});
|
|
102
|
-
req.on("end", () => {
|
|
103
|
-
if (aborted)
|
|
104
|
-
return;
|
|
105
|
-
let payload;
|
|
106
|
-
try {
|
|
107
|
-
payload = JSON.parse(Buffer.concat(chunks).toString("utf8"));
|
|
108
|
-
}
|
|
109
|
-
catch {
|
|
110
|
-
return respond(400, { ok: false, error: "malformed" });
|
|
111
|
-
}
|
|
112
|
-
const stampMs = options.now ? options.now() : Date.now();
|
|
113
|
-
const result = acceptMirrorEnvelope(payload, {
|
|
114
|
-
resolvePublicKeys: (signer) => store.listInstanceKeys(signer),
|
|
115
|
-
enrolledKeys,
|
|
116
|
-
guard,
|
|
117
|
-
applyRegistration: (reg) => store.registerInstance(reg),
|
|
118
|
-
// Re-stamp heartbeatAt with the REMOTE clock → freshness derives from the
|
|
119
|
-
// beat (no local-clock skew, no immortal ghost when the agent dies).
|
|
120
|
-
applyPresence: (session) => writePresence(root, { ...session, heartbeatAt: new Date(stampMs).toISOString(), state: "live", mirroredAt: new Date(stampMs).toISOString() }),
|
|
121
|
-
// Idempotent: registerSubagent throws on a known id — re-mirroring a beat
|
|
122
|
-
// re-sends the same bindings, so treat "already registered" as a no-op.
|
|
123
|
-
applySubagent: (binding) => {
|
|
124
|
-
try {
|
|
125
|
-
store.registerSubagent(binding);
|
|
126
|
-
}
|
|
127
|
-
catch (error) {
|
|
128
|
-
if (!/already registered/i.test(error.message))
|
|
129
|
-
throw error;
|
|
130
|
-
}
|
|
131
|
-
},
|
|
132
|
-
fenceSequence,
|
|
133
|
-
now: stampMs
|
|
134
|
-
});
|
|
135
|
-
if (result.ok)
|
|
136
|
-
return respond(202, { ok: true, applied: result.applied, signer: result.signer });
|
|
137
|
-
return respond(mirrorRejectionStatus(result.reason), { ok: false, reason: result.reason });
|
|
138
|
-
});
|
|
139
|
-
});
|
|
140
|
-
}
|
|
141
|
-
//# sourceMappingURL=serve.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"serve.js","sourceRoot":"","sources":["../../../src/runtime/mirror/serve.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AACH,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AACjE,OAAO,EAAE,YAAY,EAAe,MAAM,WAAW,CAAC;AACtD,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAEjC,OAAO,EAAE,iBAAiB,EAAuB,MAAM,gBAAgB,CAAC;AAExE,OAAO,EAAE,eAAe,EAAE,YAAY,EAAE,aAAa,EAAmB,MAAM,yBAAyB,CAAC;AACxG,OAAO,EAAE,oBAAoB,EAA2B,MAAM,aAAa,CAAC;AAE5E;;;;;;GAMG;AACH,SAAS,iBAAiB,CAAC,IAAY;IACrC,MAAM,GAAG,GAAG,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,CAAC,IAAI,EAAE,UAAU,CAAC,CAAC;IACzD,MAAM,IAAI,GAAG,IAAI,CAAC,GAAG,EAAE,iBAAiB,CAAC,CAAC;IAC1C,MAAM,IAAI,GAAG,IAAI,CAAC,GAAG,EAAE,kBAAkB,CAAC,CAAC;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
* DEC-087: gather the NHI posture snapshot from a local store for
|
|
3
|
-
* `auditNhiPosture` (core). Shared by the CLI (`nhi report`) and the MCP tool
|
|
4
|
-
* (`h2a_nhi_report`) so both classify the same registry view. Pure read.
|
|
5
|
-
*/
|
|
6
|
-
import type { H2ANhiInstanceSnapshot, H2ANhiKeyEventSnapshot, H2ANhiOffboardSnapshot, H2ANhiSubagentSnapshot } from "@sentropic/h2a";
|
|
7
|
-
import type { LocalStore } from "./local-files/store.js";
|
|
8
|
-
export interface H2ANhiSnapshot {
|
|
9
|
-
instances: H2ANhiInstanceSnapshot[];
|
|
10
|
-
subagents: H2ANhiSubagentSnapshot[];
|
|
11
|
-
keyEvents: H2ANhiKeyEventSnapshot[];
|
|
12
|
-
offboards: H2ANhiOffboardSnapshot[];
|
|
13
|
-
}
|
|
14
|
-
export declare function gatherNhiSnapshot(store: LocalStore): H2ANhiSnapshot;
|
|
15
|
-
//# sourceMappingURL=nhi.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"nhi.d.ts","sourceRoot":"","sources":["../../src/runtime/nhi.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,KAAK,EACV,sBAAsB,EACtB,sBAAsB,EACtB,sBAAsB,EACtB,sBAAsB,EACvB,MAAM,gBAAgB,CAAC;AAExB,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;AAEzD,MAAM,WAAW,cAAc;IAC7B,SAAS,EAAE,sBAAsB,EAAE,CAAC;IACpC,SAAS,EAAE,sBAAsB,EAAE,CAAC;IACpC,SAAS,EAAE,sBAAsB,EAAE,CAAC;IACpC,SAAS,EAAE,sBAAsB,EAAE,CAAC;CACrC;AAED,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,UAAU,GAAG,cAAc,CAwBnE"}
|
package/dist/runtime/nhi.js
DELETED
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
export function gatherNhiSnapshot(store) {
|
|
2
|
-
const instances = store.listInstances().map((reg) => ({
|
|
3
|
-
id: reg.id,
|
|
4
|
-
...(reg.roles && reg.roles.length > 0 ? { role: reg.roles.join(",") } : {}),
|
|
5
|
-
activeKeys: store.listInstanceKeys(reg.id)
|
|
6
|
-
}));
|
|
7
|
-
const subagents = store.listSubagents().map((b) => ({
|
|
8
|
-
id: b.id,
|
|
9
|
-
parentInstance: b.parentInstance,
|
|
10
|
-
status: store.subagentStatus(b.id),
|
|
11
|
-
...(b.capabilities ? { capabilities: b.capabilities } : {})
|
|
12
|
-
}));
|
|
13
|
-
const keyEvents = store.listKeyEvents().map((e) => ({
|
|
14
|
-
instance: e.instance,
|
|
15
|
-
publicKey: e.publicKey,
|
|
16
|
-
type: e.type,
|
|
17
|
-
at: e.at
|
|
18
|
-
}));
|
|
19
|
-
const offboards = store.listOffboards().map((o) => ({
|
|
20
|
-
instance: o.instance,
|
|
21
|
-
at: o.at,
|
|
22
|
-
...(o.reason ? { reason: o.reason } : {})
|
|
23
|
-
}));
|
|
24
|
-
return { instances, subagents, keyEvents, offboards };
|
|
25
|
-
}
|
|
26
|
-
//# sourceMappingURL=nhi.js.map
|
package/dist/runtime/nhi.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"nhi.js","sourceRoot":"","sources":["../../src/runtime/nhi.ts"],"names":[],"mappings":"AAqBA,MAAM,UAAU,iBAAiB,CAAC,KAAiB;IACjD,MAAM,SAAS,GAA6B,KAAK,CAAC,aAAa,EAAE,CAAC,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,CAAC;QAC9E,EAAE,EAAE,GAAG,CAAC,EAAE;QACV,GAAG,CAAC,GAAG,CAAC,KAAK,IAAI,GAAG,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,IAAI,EAAE,GAAG,CAAC,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;QAC3E,UAAU,E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(DEC-075), slice 3a of the signed-bearer
|
|
3
|
-
* transport-auth workstream (DEC-032 / DEC-073 / DEC-074).
|
|
4
|
-
*
|
|
5
|
-
* `acceptRemoteEnvelope` is the trust boundary for an envelope arriving from
|
|
6
|
-
* off-host: it does NOT trust the channel. It verifies, in order:
|
|
7
|
-
* 1. the payload is a well-formed H2A envelope,
|
|
8
|
-
* 2. it declares a local delivery target,
|
|
9
|
-
* 3. it carries a signature by its emitter (`actor.instance`) that verifies
|
|
10
|
-
* against that emitter's public key (DEC-073),
|
|
11
|
-
* 4. it is fresh and not a replay (DEC-074),
|
|
12
|
-
* and only then delivers it to the target's local inbox.
|
|
13
|
-
*
|
|
14
|
-
* The pipeline takes its key lookup, replay guard and delivery as callbacks, so
|
|
15
|
-
* it is transport-agnostic (the HTTP wiring is slice 3b) and testable without a
|
|
16
|
-
* network or a real store.
|
|
17
|
-
*/
|
|
18
|
-
import { type H2AEnvelope, type H2AReplayGuard } from "@sentropic/h2a";
|
|
19
|
-
export type H2AAcceptRejection = "malformed" | "no-target" | "no-signature" | "no-public-key" | "bad-signature" | "invalid-timestamp" | "expired" | "future" | "replayed";
|
|
20
|
-
export type H2AAcceptResult = {
|
|
21
|
-
ok: true;
|
|
22
|
-
deliveredTo: string;
|
|
23
|
-
signer: string;
|
|
24
|
-
} | {
|
|
25
|
-
ok: false;
|
|
26
|
-
reason: H2AAcceptRejection;
|
|
27
|
-
};
|
|
28
|
-
export interface AcceptRemoteOptions {
|
|
29
|
-
/**
|
|
30
|
-
* Resolve a signer instance to its active ed25519 public-key PEMs (DEC-078:
|
|
31
|
-
* registration keys + keyring, minus revoked). The signature is accepted if
|
|
32
|
-
* it verifies against ANY of them, which is what makes key rotation work
|
|
33
|
-
* (old + new key both valid during the overlap). Return `[]` for an unknown
|
|
34
|
-
* or key-less signer.
|
|
35
|
-
*/
|
|
36
|
-
resolvePublicKeys: (signerInstance: string) => string[];
|
|
37
|
-
/** Replay guard (DEC-074). Its freshness window also enforces timestamp checks. */
|
|
38
|
-
guard: H2AReplayGuard;
|
|
39
|
-
/** Deliver the accepted envelope to a local recipient's inbox. */
|
|
40
|
-
deliver: (recipient: string, envelope: H2AEnvelope) => void;
|
|
41
|
-
/** Reference time (ms epoch) handed to the guard. Defaults to `Date.now()`. */
|
|
42
|
-
now?: number;
|
|
43
|
-
}
|
|
44
|
-
/**
|
|
45
|
-
* Validate and deliver a remotely-received envelope. Returns a structured
|
|
46
|
-
* result; never throws on a rejection (only the caller-supplied `deliver` may
|
|
47
|
-
* throw, which propagates).
|
|
48
|
-
*/
|
|
49
|
-
export declare function acceptRemoteEnvelope(payload: unknown, options: AcceptRemoteOptions): H2AAcceptResult;
|
|
50
|
-
//# sourceMappingURL=accept.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"accept.d.ts","sourceRoot":"","sources":["../../../src/runtime/remote/accept.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAGL,KAAK,WAAW,EAEhB,KAAK,cAAc,EACpB,MAAM,gBAAgB,CAAC;AAExB,MAAM,MAAM,kBAAkB,GAC1B,WAAW,GACX,WAAW,GACX,cAAc,GACd,eAAe,GACf,eAAe,GACf,mBAAmB,GACnB,SAAS,GACT,QAAQ,GACR,UAAU,CAAC;AAEf,MAAM,MAAM,eAAe,GACvB;IAAE,EAAE,EAAE,IAAI,CAAC;IAAC,WAAW,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,GACjD;IAAE,EAAE,EAAE,KAAK,CAAC;IAAC,MAAM,EAAE,kBAAkB,CAAA;CAAE,CAAC;AAE9C,MAAM,WAAW,mBAAmB;IAClC;;;;;;OAMG;IACH,iBAAiB,EAAE,CAAC,cAAc,EAAE,MAAM,KAAK,MAAM,EAAE,CAAC;IACxD,mFAAmF;IACnF,KAAK,EAAE,cAAc,CAAC;IACtB,kEAAkE;IAClE,OAAO,EAAE,CAAC,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAE,WAAW,KAAK,IAAI,CAAC;IAC5D,+EAA+E;IAC/E,GAAG,CAAC,EAAE,MAAM,CAAC;CACd;AAED;;;;GAIG;AACH,wBAAgB,oBAAoB,CAClC,OAAO,EAAE,OAAO,EAChB,OAAO,EAAE,mBAAmB,GAC3B,eAAe,CAoCjB"}
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Remote-receive pipeline (DEC-075), slice 3a of the signed-bearer
|
|
3
|
-
* transport-auth workstream (DEC-032 / DEC-073 / DEC-074).
|
|
4
|
-
*
|
|
5
|
-
* `acceptRemoteEnvelope` is the trust boundary for an envelope arriving from
|
|
6
|
-
* off-host: it does NOT trust the channel. It verifies, in order:
|
|
7
|
-
* 1. the payload is a well-formed H2A envelope,
|
|
8
|
-
* 2. it declares a local delivery target,
|
|
9
|
-
* 3. it carries a signature by its emitter (`actor.instance`) that verifies
|
|
10
|
-
* against that emitter's public key (DEC-073),
|
|
11
|
-
* 4. it is fresh and not a replay (DEC-074),
|
|
12
|
-
* and only then delivers it to the target's local inbox.
|
|
13
|
-
*
|
|
14
|
-
* The pipeline takes its key lookup, replay guard and delivery as callbacks, so
|
|
15
|
-
* it is transport-agnostic (the HTTP wiring is slice 3b) and testable without a
|
|
16
|
-
* network or a real store.
|
|
17
|
-
*/
|
|
18
|
-
import { isH2AEnvelope, verifyEnvelopeSignature } from "@sentropic/h2a";
|
|
19
|
-
/**
|
|
20
|
-
* Validate and deliver a remotely-received envelope. Returns a structured
|
|
21
|
-
* result; never throws on a rejection (only the caller-supplied `deliver` may
|
|
22
|
-
* throw, which propagates).
|
|
23
|
-
*/
|
|
24
|
-
export function acceptRemoteEnvelope(payload, options) {
|
|
25
|
-
if (!isH2AEnvelope(payload)) {
|
|
26
|
-
return { ok: false, reason: "malformed" };
|
|
27
|
-
}
|
|
28
|
-
const envelope = payload;
|
|
29
|
-
const recipient = envelope.target?.instance;
|
|
30
|
-
if (!recipient) {
|
|
31
|
-
return { ok: false, reason: "no-target" };
|
|
32
|
-
}
|
|
33
|
-
const signer = envelope.actor.instance;
|
|
34
|
-
const hasSignerSig = (envelope.signatures ?? []).some((s) => s.by === signer);
|
|
35
|
-
if (!hasSignerSig) {
|
|
36
|
-
return { ok: false, reason: "no-signature" };
|
|
37
|
-
}
|
|
38
|
-
const publicKeys = options.resolvePublicKeys(signer);
|
|
39
|
-
if (publicKeys.length === 0) {
|
|
40
|
-
return { ok: false, reason: "no-public-key" };
|
|
41
|
-
}
|
|
42
|
-
const verified = publicKeys.some((pem) => verifyEnvelopeSignature(envelope, pem, { by: signer }));
|
|
43
|
-
if (!verified) {
|
|
44
|
-
return { ok: false, reason: "bad-signature" };
|
|
45
|
-
}
|
|
46
|
-
const replay = options.guard.accept(envelope, options.now);
|
|
47
|
-
if (!replay.ok) {
|
|
48
|
-
// freshness/replay reasons map 1:1 onto our rejection union
|
|
49
|
-
return { ok: false, reason: replay.reason };
|
|
50
|
-
}
|
|
51
|
-
options.deliver(recipient, envelope);
|
|
52
|
-
return { ok: true, deliveredTo: recipient, signer };
|
|
53
|
-
}
|
|
54
|
-
//# sourceMappingURL=accept.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"accept.js","sourceRoot":"","sources":["../../../src/runtime/remote/accept.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EACL,aAAa,EACb,uBAAuB,EAIxB,MAAM,gBAAgB,CAAC;AAkCxB;;;;GAIG;AACH,MAAM,UAAU,oBAAoB,CAClC,OAAgB,EAChB,OAA4B;IAE5B,IAAI,CAAC,aAAa,CAAC,OAAO,CAAC,EAAE,CAAC;QAC5B,OAAO,EAAE,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,WAAW,EAAE,CAAC;IAC5C,CAAC;IACD,MAAM,QAAQ,GAAG,OAAO,CAAC;IAEzB,MAAM,SAAS,GAAG,QAAQ,CAAC,MAAM,EAAE,QAAQ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