@cello-protocol/daemon 0.0.227 → 0.0.229
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/agent-admin-handlers.d.ts +56 -0
- package/dist/agent-admin-handlers.d.ts.map +1 -0
- package/dist/agent-admin-handlers.js +73 -0
- package/dist/agent-admin-handlers.js.map +1 -0
- package/dist/agent-handlers.d.ts +72 -0
- package/dist/agent-handlers.d.ts.map +1 -0
- package/dist/agent-handlers.js +604 -0
- package/dist/agent-handlers.js.map +1 -0
- package/dist/agent-id-migration.d.ts +70 -0
- package/dist/agent-id-migration.d.ts.map +1 -0
- package/dist/agent-id-migration.js +468 -0
- package/dist/agent-id-migration.js.map +1 -0
- package/dist/agent-loader.d.ts +37 -0
- package/dist/agent-loader.d.ts.map +1 -0
- package/dist/agent-loader.js +37 -0
- package/dist/agent-loader.js.map +1 -0
- package/dist/agent-selection-root.d.ts +29 -0
- package/dist/agent-selection-root.d.ts.map +1 -0
- package/dist/agent-selection-root.js +126 -0
- package/dist/agent-selection-root.js.map +1 -0
- package/dist/agent-selection.d.ts +73 -0
- package/dist/agent-selection.d.ts.map +1 -0
- package/dist/agent-selection.js +80 -0
- package/dist/agent-selection.js.map +1 -0
- package/dist/agent-settings-keys.d.ts +52 -0
- package/dist/agent-settings-keys.d.ts.map +1 -0
- package/dist/agent-settings-keys.js +114 -0
- package/dist/agent-settings-keys.js.map +1 -0
- package/dist/agent-state.d.ts +67 -0
- package/dist/agent-state.d.ts.map +1 -0
- package/dist/agent-state.js +66 -0
- package/dist/agent-state.js.map +1 -0
- package/dist/assignment-verify.d.ts +90 -0
- package/dist/assignment-verify.d.ts.map +1 -0
- package/dist/assignment-verify.js +301 -0
- package/dist/assignment-verify.js.map +1 -0
- package/dist/attendance-wiring.d.ts +23 -0
- package/dist/attendance-wiring.d.ts.map +1 -0
- package/dist/attendance-wiring.js +248 -0
- package/dist/attendance-wiring.js.map +1 -0
- package/dist/attestation-body.d.ts +47 -0
- package/dist/attestation-body.d.ts.map +1 -0
- package/dist/attestation-body.js +71 -0
- package/dist/attestation-body.js.map +1 -0
- package/dist/authorship-verification.d.ts +91 -0
- package/dist/authorship-verification.d.ts.map +1 -0
- package/dist/authorship-verification.js +532 -0
- package/dist/authorship-verification.js.map +1 -0
- package/dist/away-detection.d.ts +139 -0
- package/dist/away-detection.d.ts.map +1 -0
- package/dist/away-detection.js +186 -0
- package/dist/away-detection.js.map +1 -0
- package/dist/away-inbox-oneshot.d.ts +40 -0
- package/dist/away-inbox-oneshot.d.ts.map +1 -0
- package/dist/away-inbox-oneshot.js +311 -0
- package/dist/away-inbox-oneshot.js.map +1 -0
- package/dist/backup-restore-handlers.d.ts +10 -0
- package/dist/backup-restore-handlers.d.ts.map +1 -0
- package/dist/backup-restore-handlers.js +82 -0
- package/dist/backup-restore-handlers.js.map +1 -0
- package/dist/backup-restore.d.ts +102 -0
- package/dist/backup-restore.d.ts.map +1 -0
- package/dist/backup-restore.js +341 -0
- package/dist/backup-restore.js.map +1 -0
- package/dist/bin/cello-daemon.d.ts +13 -0
- package/dist/bin/cello-daemon.d.ts.map +1 -0
- package/dist/bin/cello-daemon.js.map +1 -0
- package/dist/boot-agents.d.ts +64 -0
- package/dist/boot-agents.d.ts.map +1 -0
- package/dist/boot-agents.js +241 -0
- package/dist/boot-agents.js.map +1 -0
- package/dist/boot-connection-state.d.ts +38 -0
- package/dist/boot-connection-state.d.ts.map +1 -0
- package/dist/boot-connection-state.js +95 -0
- package/dist/boot-connection-state.js.map +1 -0
- package/dist/boot-core.d.ts +36 -0
- package/dist/boot-core.d.ts.map +1 -0
- package/dist/boot-core.js +293 -0
- package/dist/boot-core.js.map +1 -0
- package/dist/boot-parked-content.d.ts +34 -0
- package/dist/boot-parked-content.d.ts.map +1 -0
- package/dist/boot-parked-content.js +528 -0
- package/dist/boot-parked-content.js.map +1 -0
- package/dist/boot-sweeps.d.ts +22 -0
- package/dist/boot-sweeps.d.ts.map +1 -0
- package/dist/boot-sweeps.js +51 -0
- package/dist/boot-sweeps.js.map +1 -0
- package/dist/bundled-consortium-manifest.d.ts +47 -0
- package/dist/bundled-consortium-manifest.d.ts.map +1 -0
- package/dist/bundled-consortium-manifest.js +116 -0
- package/dist/bundled-consortium-manifest.js.map +1 -0
- package/dist/cbor-blob-migration.d.ts +8 -0
- package/dist/cbor-blob-migration.d.ts.map +1 -0
- package/dist/cbor-blob-migration.js +116 -0
- package/dist/cbor-blob-migration.js.map +1 -0
- package/dist/challenge-verifier.d.ts +12 -0
- package/dist/challenge-verifier.d.ts.map +1 -0
- package/dist/challenge-verifier.js +11 -0
- package/dist/challenge-verifier.js.map +1 -0
- package/dist/channel-log-store.d.ts +80 -0
- package/dist/channel-log-store.d.ts.map +1 -0
- package/dist/channel-log-store.js +290 -0
- package/dist/channel-log-store.js.map +1 -0
- package/dist/close-commitment.d.ts +67 -0
- package/dist/close-commitment.d.ts.map +1 -0
- package/dist/close-commitment.js +78 -0
- package/dist/close-commitment.js.map +1 -0
- package/dist/close-session-handler.d.ts +94 -0
- package/dist/close-session-handler.d.ts.map +1 -0
- package/dist/close-session-handler.js +1418 -0
- package/dist/close-session-handler.js.map +1 -0
- package/dist/co-attendance.d.ts +29 -0
- package/dist/co-attendance.d.ts.map +1 -0
- package/dist/co-attendance.js +32 -0
- package/dist/co-attendance.js.map +1 -0
- package/dist/column-birth.d.ts +40 -0
- package/dist/column-birth.d.ts.map +1 -0
- package/dist/column-birth.js +61 -0
- package/dist/column-birth.js.map +1 -0
- package/dist/connect-or-start.d.ts +25 -0
- package/dist/connect-or-start.d.ts.map +1 -0
- package/dist/connect-or-start.js +175 -0
- package/dist/connect-or-start.js.map +1 -0
- package/dist/connection-agents.d.ts +16 -0
- package/dist/connection-agents.d.ts.map +1 -0
- package/dist/connection-agents.js +68 -0
- package/dist/connection-agents.js.map +1 -0
- package/dist/consent-migration.d.ts +49 -0
- package/dist/consent-migration.d.ts.map +1 -0
- package/dist/consent-migration.js +128 -0
- package/dist/consent-migration.js.map +1 -0
- package/dist/consortium-bootstrap.d.ts +138 -0
- package/dist/consortium-bootstrap.d.ts.map +1 -0
- package/dist/consortium-bootstrap.js +339 -0
- package/dist/consortium-bootstrap.js.map +1 -0
- package/dist/consortium-fingerprint.d.ts +115 -0
- package/dist/consortium-fingerprint.d.ts.map +1 -0
- package/dist/consortium-fingerprint.js +175 -0
- package/dist/consortium-fingerprint.js.map +1 -0
- package/dist/contact-handlers.d.ts +59 -0
- package/dist/contact-handlers.d.ts.map +1 -0
- package/dist/contact-handlers.js +343 -0
- package/dist/contact-handlers.js.map +1 -0
- package/dist/contact-pubkey-case.d.ts +65 -0
- package/dist/contact-pubkey-case.d.ts.map +1 -0
- package/dist/contact-pubkey-case.js +136 -0
- package/dist/contact-pubkey-case.js.map +1 -0
- package/dist/contacts-tier-migration.d.ts +90 -0
- package/dist/contacts-tier-migration.d.ts.map +1 -0
- package/dist/contacts-tier-migration.js +150 -0
- package/dist/contacts-tier-migration.js.map +1 -0
- package/dist/content-encryption-status.d.ts +111 -0
- package/dist/content-encryption-status.d.ts.map +1 -0
- package/dist/content-encryption-status.js +158 -0
- package/dist/content-encryption-status.js.map +1 -0
- package/dist/content-park-client.d.ts +90 -0
- package/dist/content-park-client.d.ts.map +1 -0
- package/dist/content-park-client.js +362 -0
- package/dist/content-park-client.js.map +1 -0
- package/dist/content-park.d.ts +52 -0
- package/dist/content-park.d.ts.map +1 -0
- package/dist/content-park.js +1309 -0
- package/dist/content-park.js.map +1 -0
- package/dist/cross-node-negotiation.d.ts +44 -0
- package/dist/cross-node-negotiation.d.ts.map +1 -0
- package/dist/cross-node-negotiation.js +34 -0
- package/dist/cross-node-negotiation.js.map +1 -0
- package/dist/daemon-handle.d.ts +57 -0
- package/dist/daemon-handle.d.ts.map +1 -0
- package/dist/daemon-handle.js +2 -0
- package/dist/daemon-handle.js.map +1 -0
- package/dist/daemon-status-report.d.ts +50 -0
- package/dist/daemon-status-report.d.ts.map +1 -0
- package/dist/daemon-status-report.js +81 -0
- package/dist/daemon-status-report.js.map +1 -0
- package/dist/daemon.d.ts +45 -0
- package/dist/daemon.d.ts.map +1 -0
- package/dist/daemon.js +1177 -0
- package/dist/daemon.js.map +1 -0
- package/dist/db-identity-store.d.ts +159 -0
- package/dist/db-identity-store.d.ts.map +1 -0
- package/dist/db-identity-store.js +502 -0
- package/dist/db-identity-store.js.map +1 -0
- package/dist/delivery-open-registry.d.ts +92 -0
- package/dist/delivery-open-registry.d.ts.map +1 -0
- package/dist/delivery-open-registry.js +121 -0
- package/dist/delivery-open-registry.js.map +1 -0
- package/dist/delivery-session-suspects.d.ts +56 -0
- package/dist/delivery-session-suspects.d.ts.map +1 -0
- package/dist/delivery-session-suspects.js +94 -0
- package/dist/delivery-session-suspects.js.map +1 -0
- package/dist/directory-auth-posture.d.ts +87 -0
- package/dist/directory-auth-posture.d.ts.map +1 -0
- package/dist/directory-auth-posture.js +134 -0
- package/dist/directory-auth-posture.js.map +1 -0
- package/dist/directory-bootstrap.d.ts +310 -0
- package/dist/directory-bootstrap.d.ts.map +1 -0
- package/dist/directory-bootstrap.js +557 -0
- package/dist/directory-bootstrap.js.map +1 -0
- package/dist/directory-connect.d.ts +27 -0
- package/dist/directory-connect.d.ts.map +1 -0
- package/dist/directory-connect.js +106 -0
- package/dist/directory-connect.js.map +1 -0
- package/dist/disconnect-cleanup.d.ts +51 -0
- package/dist/disconnect-cleanup.d.ts.map +1 -0
- package/dist/disconnect-cleanup.js +72 -0
- package/dist/disconnect-cleanup.js.map +1 -0
- package/dist/document-amendment-store.d.ts +120 -0
- package/dist/document-amendment-store.d.ts.map +1 -0
- package/dist/document-amendment-store.js +266 -0
- package/dist/document-amendment-store.js.map +1 -0
- package/dist/document-delivery-transport.d.ts +168 -0
- package/dist/document-delivery-transport.d.ts.map +1 -0
- package/dist/document-delivery-transport.js +206 -0
- package/dist/document-delivery-transport.js.map +1 -0
- package/dist/document-engine.d.ts +134 -0
- package/dist/document-engine.d.ts.map +1 -0
- package/dist/document-engine.js +282 -0
- package/dist/document-engine.js.map +1 -0
- package/dist/document-flag.d.ts +58 -0
- package/dist/document-flag.d.ts.map +1 -0
- package/dist/document-flag.js +70 -0
- package/dist/document-flag.js.map +1 -0
- package/dist/document-frame-router.d.ts +245 -0
- package/dist/document-frame-router.d.ts.map +1 -0
- package/dist/document-frame-router.js +397 -0
- package/dist/document-frame-router.js.map +1 -0
- package/dist/document-gate-wiring.d.ts +61 -0
- package/dist/document-gate-wiring.d.ts.map +1 -0
- package/dist/document-gate-wiring.js +125 -0
- package/dist/document-gate-wiring.js.map +1 -0
- package/dist/document-gate.d.ts +149 -0
- package/dist/document-gate.d.ts.map +1 -0
- package/dist/document-gate.js +509 -0
- package/dist/document-gate.js.map +1 -0
- package/dist/document-handlers.d.ts +47 -0
- package/dist/document-handlers.d.ts.map +1 -0
- package/dist/document-handlers.js +2203 -0
- package/dist/document-handlers.js.map +1 -0
- package/dist/document-handshake.d.ts +176 -0
- package/dist/document-handshake.d.ts.map +1 -0
- package/dist/document-handshake.js +452 -0
- package/dist/document-handshake.js.map +1 -0
- package/dist/document-inbound.d.ts +162 -0
- package/dist/document-inbound.d.ts.map +1 -0
- package/dist/document-inbound.js +530 -0
- package/dist/document-inbound.js.map +1 -0
- package/dist/document-json.d.ts +120 -0
- package/dist/document-json.d.ts.map +1 -0
- package/dist/document-json.js +191 -0
- package/dist/document-json.js.map +1 -0
- package/dist/document-layer.d.ts +215 -0
- package/dist/document-layer.d.ts.map +1 -0
- package/dist/document-layer.js +1025 -0
- package/dist/document-layer.js.map +1 -0
- package/dist/document-lifecycle.d.ts +52 -0
- package/dist/document-lifecycle.d.ts.map +1 -0
- package/dist/document-lifecycle.js +134 -0
- package/dist/document-lifecycle.js.map +1 -0
- package/dist/document-live-docs.d.ts +58 -0
- package/dist/document-live-docs.d.ts.map +1 -0
- package/dist/document-live-docs.js +126 -0
- package/dist/document-live-docs.js.map +1 -0
- package/dist/document-notify.d.ts +228 -0
- package/dist/document-notify.d.ts.map +1 -0
- package/dist/document-notify.js +580 -0
- package/dist/document-notify.js.map +1 -0
- package/dist/document-profile.d.ts +61 -0
- package/dist/document-profile.d.ts.map +1 -0
- package/dist/document-profile.js +112 -0
- package/dist/document-profile.js.map +1 -0
- package/dist/document-publish.d.ts +87 -0
- package/dist/document-publish.d.ts.map +1 -0
- package/dist/document-publish.js +173 -0
- package/dist/document-publish.js.map +1 -0
- package/dist/document-reachability.d.ts +42 -0
- package/dist/document-reachability.d.ts.map +1 -0
- package/dist/document-reachability.js +80 -0
- package/dist/document-reachability.js.map +1 -0
- package/dist/document-reconcile-engine.d.ts +66 -0
- package/dist/document-reconcile-engine.d.ts.map +1 -0
- package/dist/document-reconcile-engine.js +225 -0
- package/dist/document-reconcile-engine.js.map +1 -0
- package/dist/document-reconcile-scheduler.d.ts +163 -0
- package/dist/document-reconcile-scheduler.d.ts.map +1 -0
- package/dist/document-reconcile-scheduler.js +303 -0
- package/dist/document-reconcile-scheduler.js.map +1 -0
- package/dist/document-rejection.d.ts +251 -0
- package/dist/document-rejection.d.ts.map +1 -0
- package/dist/document-rejection.js +435 -0
- package/dist/document-rejection.js.map +1 -0
- package/dist/document-screen.d.ts +114 -0
- package/dist/document-screen.d.ts.map +1 -0
- package/dist/document-screen.js +223 -0
- package/dist/document-screen.js.map +1 -0
- package/dist/document-store.d.ts +372 -0
- package/dist/document-store.d.ts.map +1 -0
- package/dist/document-store.js +931 -0
- package/dist/document-store.js.map +1 -0
- package/dist/document-surface.d.ts +32 -0
- package/dist/document-surface.d.ts.map +1 -0
- package/dist/document-surface.js +151 -0
- package/dist/document-surface.js.map +1 -0
- package/dist/document-types.d.ts +94 -0
- package/dist/document-types.d.ts.map +1 -0
- package/dist/document-types.js +90 -0
- package/dist/document-types.js.map +1 -0
- package/dist/document-watch.d.ts +69 -0
- package/dist/document-watch.d.ts.map +1 -0
- package/dist/document-watch.js +108 -0
- package/dist/document-watch.js.map +1 -0
- package/dist/document-wiring.d.ts +53 -0
- package/dist/document-wiring.d.ts.map +1 -0
- package/dist/document-wiring.js +323 -0
- package/dist/document-wiring.js.map +1 -0
- package/dist/document-write-guard.d.ts +66 -0
- package/dist/document-write-guard.d.ts.map +1 -0
- package/dist/document-write-guard.js +98 -0
- package/dist/document-write-guard.js.map +1 -0
- package/dist/document-write-path.d.ts +94 -0
- package/dist/document-write-path.d.ts.map +1 -0
- package/dist/document-write-path.js +530 -0
- package/dist/document-write-path.js.map +1 -0
- package/dist/error-message.d.ts +7 -0
- package/dist/error-message.d.ts.map +1 -0
- package/dist/error-message.js +19 -0
- package/dist/error-message.js.map +1 -0
- package/dist/file-manifest-provider.d.ts +37 -0
- package/dist/file-manifest-provider.d.ts.map +1 -0
- package/dist/file-manifest-provider.js +105 -0
- package/dist/file-manifest-provider.js.map +1 -0
- package/dist/frame-values.d.ts +3 -0
- package/dist/frame-values.d.ts.map +1 -0
- package/dist/frame-values.js +84 -0
- package/dist/frame-values.js.map +1 -0
- package/dist/frontier-mismatch.d.ts +73 -0
- package/dist/frontier-mismatch.d.ts.map +1 -0
- package/dist/frontier-mismatch.js +89 -0
- package/dist/frontier-mismatch.js.map +1 -0
- package/dist/gateway-config-handlers.d.ts +26 -0
- package/dist/gateway-config-handlers.d.ts.map +1 -0
- package/dist/gateway-config-handlers.js +454 -0
- package/dist/gateway-config-handlers.js.map +1 -0
- package/dist/held-content.d.ts +145 -0
- package/dist/held-content.d.ts.map +1 -0
- package/dist/held-content.js +389 -0
- package/dist/held-content.js.map +1 -0
- package/dist/http-manifest-poll.d.ts +67 -0
- package/dist/http-manifest-poll.d.ts.map +1 -0
- package/dist/http-manifest-poll.js +150 -0
- package/dist/http-manifest-poll.js.map +1 -0
- package/dist/identity-migration.d.ts +40 -0
- package/dist/identity-migration.d.ts.map +1 -0
- package/dist/identity-migration.js +461 -0
- package/dist/identity-migration.js.map +1 -0
- package/dist/inbound-refusals.d.ts +283 -0
- package/dist/inbound-refusals.d.ts.map +1 -0
- package/dist/inbound-refusals.js +919 -0
- package/dist/inbound-refusals.js.map +1 -0
- package/dist/inbound-seal-request.d.ts +32 -0
- package/dist/inbound-seal-request.d.ts.map +1 -0
- package/dist/inbound-seal-request.js +228 -0
- package/dist/inbound-seal-request.js.map +1 -0
- package/dist/inbound-sessions.d.ts +291 -0
- package/dist/inbound-sessions.d.ts.map +1 -0
- package/dist/inbound-sessions.js +1609 -0
- package/dist/inbound-sessions.js.map +1 -0
- package/dist/inclusion-proof-handlers.d.ts +43 -0
- package/dist/inclusion-proof-handlers.d.ts.map +1 -0
- package/dist/inclusion-proof-handlers.js +565 -0
- package/dist/inclusion-proof-handlers.js.map +1 -0
- package/dist/inclusion-proof.d.ts +151 -0
- package/dist/inclusion-proof.d.ts.map +1 -0
- package/dist/inclusion-proof.js +228 -0
- package/dist/inclusion-proof.js.map +1 -0
- package/dist/index.d.ts +32 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js.map +1 -0
- package/dist/initiate-session-handler.d.ts +55 -0
- package/dist/initiate-session-handler.d.ts.map +1 -0
- package/dist/initiate-session-handler.js +310 -0
- package/dist/initiate-session-handler.js.map +1 -0
- package/dist/ipc-client.d.ts +31 -0
- package/dist/ipc-client.d.ts.map +1 -0
- package/dist/ipc-client.js +113 -0
- package/dist/ipc-client.js.map +1 -0
- package/dist/ipc-server.d.ts +63 -0
- package/dist/ipc-server.d.ts.map +1 -0
- package/dist/ipc-server.js +429 -0
- package/dist/ipc-server.js.map +1 -0
- package/dist/ipc-surface.d.ts +44 -0
- package/dist/ipc-surface.d.ts.map +1 -0
- package/dist/ipc-surface.js +107 -0
- package/dist/ipc-surface.js.map +1 -0
- package/dist/line-lcs.d.ts +51 -0
- package/dist/line-lcs.d.ts.map +1 -0
- package/dist/line-lcs.js +71 -0
- package/dist/line-lcs.js.map +1 -0
- package/dist/lock-file.d.ts +39 -0
- package/dist/lock-file.d.ts.map +1 -0
- package/dist/lock-file.js +120 -0
- package/dist/lock-file.js.map +1 -0
- package/dist/log-collapse.d.ts +66 -0
- package/dist/log-collapse.d.ts.map +1 -0
- package/dist/log-collapse.js +244 -0
- package/dist/log-collapse.js.map +1 -0
- package/dist/log-rotate.d.ts +67 -0
- package/dist/log-rotate.d.ts.map +1 -0
- package/dist/log-rotate.js +134 -0
- package/dist/log-rotate.js.map +1 -0
- package/dist/manifest-deps.d.ts +25 -0
- package/dist/manifest-deps.d.ts.map +1 -0
- package/dist/manifest-deps.js +151 -0
- package/dist/manifest-deps.js.map +1 -0
- package/dist/manifest-poll-scheduler.d.ts +31 -0
- package/dist/manifest-poll-scheduler.d.ts.map +1 -0
- package/dist/manifest-poll-scheduler.js +59 -0
- package/dist/manifest-poll-scheduler.js.map +1 -0
- package/dist/manifest-validity.d.ts +153 -0
- package/dist/manifest-validity.d.ts.map +1 -0
- package/dist/manifest-validity.js +268 -0
- package/dist/manifest-validity.js.map +1 -0
- package/dist/manifest-version-store-db.d.ts +24 -0
- package/dist/manifest-version-store-db.d.ts.map +1 -0
- package/dist/manifest-version-store-db.js +58 -0
- package/dist/manifest-version-store-db.js.map +1 -0
- package/dist/manifest-version-store.d.ts +16 -0
- package/dist/manifest-version-store.d.ts.map +1 -0
- package/dist/manifest-version-store.js +15 -0
- package/dist/manifest-version-store.js.map +1 -0
- package/dist/network-directory-node.d.ts +136 -0
- package/dist/network-directory-node.d.ts.map +1 -0
- package/dist/network-directory-node.js +810 -0
- package/dist/network-directory-node.js.map +1 -0
- package/dist/nonce-dedup.d.ts +68 -0
- package/dist/nonce-dedup.d.ts.map +1 -0
- package/dist/nonce-dedup.js +205 -0
- package/dist/nonce-dedup.js.map +1 -0
- package/dist/notification-dispatcher.d.ts +92 -0
- package/dist/notification-dispatcher.d.ts.map +1 -0
- package/dist/notification-dispatcher.js +210 -0
- package/dist/notification-dispatcher.js.map +1 -0
- package/dist/notification-handlers.d.ts +53 -0
- package/dist/notification-handlers.d.ts.map +1 -0
- package/dist/notification-handlers.js +461 -0
- package/dist/notification-handlers.js.map +1 -0
- package/dist/onboarding-guidance.d.ts +79 -0
- package/dist/onboarding-guidance.d.ts.map +1 -0
- package/dist/onboarding-guidance.js +95 -0
- package/dist/onboarding-guidance.js.map +1 -0
- package/dist/operator-guidance.d.ts +25 -0
- package/dist/operator-guidance.d.ts.map +1 -0
- package/dist/operator-guidance.js +50 -0
- package/dist/operator-guidance.js.map +1 -0
- package/dist/orphan-triage.d.ts +130 -0
- package/dist/orphan-triage.d.ts.map +1 -0
- package/dist/orphan-triage.js +207 -0
- package/dist/orphan-triage.js.map +1 -0
- package/dist/outbound-sessions.d.ts +126 -0
- package/dist/outbound-sessions.d.ts.map +1 -0
- package/dist/outbound-sessions.js +1052 -0
- package/dist/outbound-sessions.js.map +1 -0
- package/dist/park-envelope.d.ts +329 -0
- package/dist/park-envelope.d.ts.map +1 -0
- package/dist/park-envelope.js +509 -0
- package/dist/park-envelope.js.map +1 -0
- package/dist/park-recovery.d.ts +273 -0
- package/dist/park-recovery.d.ts.map +1 -0
- package/dist/park-recovery.js +717 -0
- package/dist/park-recovery.js.map +1 -0
- package/dist/park-refusals.d.ts +147 -0
- package/dist/park-refusals.d.ts.map +1 -0
- package/dist/park-refusals.js +331 -0
- package/dist/park-refusals.js.map +1 -0
- package/dist/quarantine-framing.d.ts +92 -0
- package/dist/quarantine-framing.d.ts.map +1 -0
- package/dist/quarantine-framing.js +111 -0
- package/dist/quarantine-framing.js.map +1 -0
- package/dist/reconnect-drain.d.ts +22 -0
- package/dist/reconnect-drain.d.ts.map +1 -0
- package/dist/reconnect-drain.js +65 -0
- package/dist/reconnect-drain.js.map +1 -0
- package/dist/recovered-position.d.ts +14 -0
- package/dist/recovered-position.d.ts.map +1 -0
- package/dist/recovered-position.js +59 -0
- package/dist/recovered-position.js.map +1 -0
- package/dist/refusal-notices.d.ts +196 -0
- package/dist/refusal-notices.d.ts.map +1 -0
- package/dist/refusal-notices.js +516 -0
- package/dist/refusal-notices.js.map +1 -0
- package/dist/refusal-reasons.d.ts +245 -0
- package/dist/refusal-reasons.d.ts.map +1 -0
- package/dist/refusal-reasons.js +363 -0
- package/dist/refusal-reasons.js.map +1 -0
- package/dist/register-handler.d.ts +36 -0
- package/dist/register-handler.d.ts.map +1 -0
- package/dist/register-handler.js +285 -0
- package/dist/register-handler.js.map +1 -0
- package/dist/registration-context.d.ts +72 -0
- package/dist/registration-context.d.ts.map +1 -0
- package/dist/registration-context.js +126 -0
- package/dist/registration-context.js.map +1 -0
- package/dist/registration-manager.d.ts +94 -0
- package/dist/registration-manager.d.ts.map +1 -0
- package/dist/registration-manager.js +585 -0
- package/dist/registration-manager.js.map +1 -0
- package/dist/registration-persistence.d.ts +183 -0
- package/dist/registration-persistence.d.ts.map +1 -0
- package/dist/registration-persistence.js +263 -0
- package/dist/registration-persistence.js.map +1 -0
- package/dist/registry-poll.d.ts +52 -0
- package/dist/registry-poll.d.ts.map +1 -0
- package/dist/registry-poll.js +140 -0
- package/dist/registry-poll.js.map +1 -0
- package/dist/registry-version-store-db.d.ts +22 -0
- package/dist/registry-version-store-db.d.ts.map +1 -0
- package/dist/registry-version-store-db.js +50 -0
- package/dist/registry-version-store-db.js.map +1 -0
- package/dist/relay-endpoints.d.ts +18 -0
- package/dist/relay-endpoints.d.ts.map +1 -0
- package/dist/relay-endpoints.js +9 -0
- package/dist/relay-endpoints.js.map +1 -0
- package/dist/relay-only.d.ts +140 -0
- package/dist/relay-only.d.ts.map +1 -0
- package/dist/relay-only.js +193 -0
- package/dist/relay-only.js.map +1 -0
- package/dist/relay-receipt-store.d.ts +155 -0
- package/dist/relay-receipt-store.d.ts.map +1 -0
- package/dist/relay-receipt-store.js +284 -0
- package/dist/relay-receipt-store.js.map +1 -0
- package/dist/relay-reconnect.d.ts +32 -0
- package/dist/relay-reconnect.d.ts.map +1 -0
- package/dist/relay-reconnect.js +29 -0
- package/dist/relay-reconnect.js.map +1 -0
- package/dist/reply-lag.d.ts +11 -0
- package/dist/reply-lag.d.ts.map +1 -0
- package/dist/reply-lag.js +46 -0
- package/dist/reply-lag.js.map +1 -0
- package/dist/resolve-named-agent.d.ts +49 -0
- package/dist/resolve-named-agent.d.ts.map +1 -0
- package/dist/resolve-named-agent.js +77 -0
- package/dist/resolve-named-agent.js.map +1 -0
- package/dist/restart-seal-resolver.d.ts +110 -0
- package/dist/restart-seal-resolver.d.ts.map +1 -0
- package/dist/restart-seal-resolver.js +353 -0
- package/dist/restart-seal-resolver.js.map +1 -0
- package/dist/resume-last-seen.d.ts +15 -0
- package/dist/resume-last-seen.d.ts.map +1 -0
- package/dist/resume-last-seen.js +44 -0
- package/dist/resume-last-seen.js.map +1 -0
- package/dist/retry-queue.d.ts +203 -0
- package/dist/retry-queue.d.ts.map +1 -0
- package/dist/retry-queue.js +701 -0
- package/dist/retry-queue.js.map +1 -0
- package/dist/roster-freshness.d.ts +160 -0
- package/dist/roster-freshness.d.ts.map +1 -0
- package/dist/roster-freshness.js +250 -0
- package/dist/roster-freshness.js.map +1 -0
- package/dist/screening-status.d.ts +15 -0
- package/dist/screening-status.d.ts.map +1 -0
- package/dist/screening-status.js +65 -0
- package/dist/screening-status.js.map +1 -0
- package/dist/seal-carried-close.d.ts +37 -0
- package/dist/seal-carried-close.d.ts.map +1 -0
- package/dist/seal-carried-close.js +179 -0
- package/dist/seal-carried-close.js.map +1 -0
- package/dist/seal-certificate-pull.d.ts +79 -0
- package/dist/seal-certificate-pull.d.ts.map +1 -0
- package/dist/seal-certificate-pull.js +186 -0
- package/dist/seal-certificate-pull.js.map +1 -0
- package/dist/seal-certified-root-check.d.ts +37 -0
- package/dist/seal-certified-root-check.d.ts.map +1 -0
- package/dist/seal-certified-root-check.js +127 -0
- package/dist/seal-certified-root-check.js.map +1 -0
- package/dist/seal-coordinator.d.ts +118 -0
- package/dist/seal-coordinator.d.ts.map +1 -0
- package/dist/seal-coordinator.js +927 -0
- package/dist/seal-coordinator.js.map +1 -0
- package/dist/seal-escalation.d.ts +80 -0
- package/dist/seal-escalation.d.ts.map +1 -0
- package/dist/seal-escalation.js +283 -0
- package/dist/seal-escalation.js.map +1 -0
- package/dist/seal-evidence-root-check.d.ts +70 -0
- package/dist/seal-evidence-root-check.d.ts.map +1 -0
- package/dist/seal-evidence-root-check.js +199 -0
- package/dist/seal-evidence-root-check.js.map +1 -0
- package/dist/seal-failure-store.d.ts +139 -0
- package/dist/seal-failure-store.d.ts.map +1 -0
- package/dist/seal-failure-store.js +207 -0
- package/dist/seal-failure-store.js.map +1 -0
- package/dist/seal-flows.d.ts +107 -0
- package/dist/seal-flows.d.ts.map +1 -0
- package/dist/seal-flows.js +638 -0
- package/dist/seal-flows.js.map +1 -0
- package/dist/seal-frontier-verify.d.ts +103 -0
- package/dist/seal-frontier-verify.d.ts.map +1 -0
- package/dist/seal-frontier-verify.js +143 -0
- package/dist/seal-frontier-verify.js.map +1 -0
- package/dist/seal-leaf.d.ts +58 -0
- package/dist/seal-leaf.d.ts.map +1 -0
- package/dist/seal-leaf.js +112 -0
- package/dist/seal-leaf.js.map +1 -0
- package/dist/seal-legibility-tbs.d.ts +25 -0
- package/dist/seal-legibility-tbs.d.ts.map +1 -0
- package/dist/seal-legibility-tbs.js +77 -0
- package/dist/seal-legibility-tbs.js.map +1 -0
- package/dist/seal-local-terminus.d.ts +41 -0
- package/dist/seal-local-terminus.d.ts.map +1 -0
- package/dist/seal-local-terminus.js +170 -0
- package/dist/seal-local-terminus.js.map +1 -0
- package/dist/seal-receipt-upgrade.d.ts +30 -0
- package/dist/seal-receipt-upgrade.d.ts.map +1 -0
- package/dist/seal-receipt-upgrade.js +49 -0
- package/dist/seal-receipt-upgrade.js.map +1 -0
- package/dist/seal-relay-silence.d.ts +51 -0
- package/dist/seal-relay-silence.d.ts.map +1 -0
- package/dist/seal-relay-silence.js +76 -0
- package/dist/seal-relay-silence.js.map +1 -0
- package/dist/seal-settle.d.ts +38 -0
- package/dist/seal-settle.d.ts.map +1 -0
- package/dist/seal-settle.js +33 -0
- package/dist/seal-settle.js.map +1 -0
- package/dist/seal-upgrade.d.ts +107 -0
- package/dist/seal-upgrade.d.ts.map +1 -0
- package/dist/seal-upgrade.js +200 -0
- package/dist/seal-upgrade.js.map +1 -0
- package/dist/sealed-conversation.d.ts +36 -0
- package/dist/sealed-conversation.d.ts.map +1 -0
- package/dist/sealed-conversation.js +171 -0
- package/dist/sealed-conversation.js.map +1 -0
- package/dist/sealed-leaf-set.d.ts +92 -0
- package/dist/sealed-leaf-set.d.ts.map +1 -0
- package/dist/sealed-leaf-set.js +122 -0
- package/dist/sealed-leaf-set.js.map +1 -0
- package/dist/send-claims.d.ts +56 -0
- package/dist/send-claims.d.ts.map +1 -0
- package/dist/send-claims.js +50 -0
- package/dist/send-claims.js.map +1 -0
- package/dist/session-assignment-parser.d.ts +104 -0
- package/dist/session-assignment-parser.d.ts.map +1 -0
- package/dist/session-assignment-parser.js +345 -0
- package/dist/session-assignment-parser.js.map +1 -0
- package/dist/session-category.d.ts +19 -0
- package/dist/session-category.d.ts.map +1 -0
- package/dist/session-category.js +14 -0
- package/dist/session-category.js.map +1 -0
- package/dist/session-ceremony.d.ts +297 -0
- package/dist/session-ceremony.d.ts.map +1 -0
- package/dist/session-ceremony.js +964 -0
- package/dist/session-ceremony.js.map +1 -0
- package/dist/session-closed.d.ts +79 -0
- package/dist/session-closed.d.ts.map +1 -0
- package/dist/session-closed.js +189 -0
- package/dist/session-closed.js.map +1 -0
- package/dist/session-connection-gater.d.ts +148 -0
- package/dist/session-connection-gater.d.ts.map +1 -0
- package/dist/session-connection-gater.js +332 -0
- package/dist/session-connection-gater.js.map +1 -0
- package/dist/session-content-context.d.ts +162 -0
- package/dist/session-content-context.d.ts.map +1 -0
- package/dist/session-content-context.js +2 -0
- package/dist/session-content-context.js.map +1 -0
- package/dist/session-content-handlers.d.ts +82 -0
- package/dist/session-content-handlers.d.ts.map +1 -0
- package/dist/session-content-handlers.js +1382 -0
- package/dist/session-content-handlers.js.map +1 -0
- package/dist/session-content-ingest.d.ts +206 -0
- package/dist/session-content-ingest.d.ts.map +1 -0
- package/dist/session-content-ingest.js +2167 -0
- package/dist/session-content-ingest.js.map +1 -0
- package/dist/session-content-send.d.ts +191 -0
- package/dist/session-content-send.d.ts.map +1 -0
- package/dist/session-content-send.js +1360 -0
- package/dist/session-content-send.js.map +1 -0
- package/dist/session-delivery-acks.d.ts +169 -0
- package/dist/session-delivery-acks.d.ts.map +1 -0
- package/dist/session-delivery-acks.js +569 -0
- package/dist/session-delivery-acks.js.map +1 -0
- package/dist/session-ephemerals.d.ts +279 -0
- package/dist/session-ephemerals.d.ts.map +1 -0
- package/dist/session-ephemerals.js +591 -0
- package/dist/session-ephemerals.js.map +1 -0
- package/dist/session-leaf-records.d.ts +159 -0
- package/dist/session-leaf-records.d.ts.map +1 -0
- package/dist/session-leaf-records.js +408 -0
- package/dist/session-leaf-records.js.map +1 -0
- package/dist/session-lifecycle.d.ts +303 -0
- package/dist/session-lifecycle.d.ts.map +1 -0
- package/dist/session-lifecycle.js +1679 -0
- package/dist/session-lifecycle.js.map +1 -0
- package/dist/session-liveness.d.ts +135 -0
- package/dist/session-liveness.d.ts.map +1 -0
- package/dist/session-liveness.js +347 -0
- package/dist/session-liveness.js.map +1 -0
- package/dist/session-name.d.ts +35 -0
- package/dist/session-name.d.ts.map +1 -0
- package/dist/session-name.js +60 -0
- package/dist/session-name.js.map +1 -0
- package/dist/session-node-factory.d.ts +18 -0
- package/dist/session-node-factory.d.ts.map +1 -0
- package/dist/session-node-factory.js +182 -0
- package/dist/session-node-factory.js.map +1 -0
- package/dist/session-node-manager.d.ts +877 -0
- package/dist/session-node-manager.d.ts.map +1 -0
- package/dist/session-node-manager.js +2998 -0
- package/dist/session-node-manager.js.map +1 -0
- package/dist/session-node-types.d.ts +1057 -0
- package/dist/session-node-types.d.ts.map +1 -0
- package/dist/session-node-types.js +657 -0
- package/dist/session-node-types.js.map +1 -0
- package/dist/session-notify.d.ts +46 -0
- package/dist/session-notify.d.ts.map +1 -0
- package/dist/session-notify.js +116 -0
- package/dist/session-notify.js.map +1 -0
- package/dist/session-own-chain-store.d.ts +65 -0
- package/dist/session-own-chain-store.d.ts.map +1 -0
- package/dist/session-own-chain-store.js +75 -0
- package/dist/session-own-chain-store.js.map +1 -0
- package/dist/session-queries.d.ts +476 -0
- package/dist/session-queries.d.ts.map +1 -0
- package/dist/session-queries.js +1007 -0
- package/dist/session-queries.js.map +1 -0
- package/dist/session-read-handlers.d.ts +87 -0
- package/dist/session-read-handlers.d.ts.map +1 -0
- package/dist/session-read-handlers.js +689 -0
- package/dist/session-read-handlers.js.map +1 -0
- package/dist/session-records.d.ts +341 -0
- package/dist/session-records.d.ts.map +1 -0
- package/dist/session-records.js +858 -0
- package/dist/session-records.js.map +1 -0
- package/dist/session-relay-client.d.ts +659 -0
- package/dist/session-relay-client.d.ts.map +1 -0
- package/dist/session-relay-client.js +2876 -0
- package/dist/session-relay-client.js.map +1 -0
- package/dist/session-relay.d.ts +397 -0
- package/dist/session-relay.d.ts.map +1 -0
- package/dist/session-relay.js +1636 -0
- package/dist/session-relay.js.map +1 -0
- package/dist/session-salt-agreement.d.ts +331 -0
- package/dist/session-salt-agreement.d.ts.map +1 -0
- package/dist/session-salt-agreement.js +472 -0
- package/dist/session-salt-agreement.js.map +1 -0
- package/dist/session-salts.d.ts +432 -0
- package/dist/session-salts.d.ts.map +1 -0
- package/dist/session-salts.js +1540 -0
- package/dist/session-salts.js.map +1 -0
- package/dist/session-schema.d.ts +30 -0
- package/dist/session-schema.d.ts.map +1 -0
- package/dist/session-schema.js +877 -0
- package/dist/session-schema.js.map +1 -0
- package/dist/session-seal-leaf-store.d.ts +70 -0
- package/dist/session-seal-leaf-store.d.ts.map +1 -0
- package/dist/session-seal-leaf-store.js +105 -0
- package/dist/session-seal-leaf-store.js.map +1 -0
- package/dist/session-seal.d.ts +334 -0
- package/dist/session-seal.d.ts.map +1 -0
- package/dist/session-seal.js +1017 -0
- package/dist/session-seal.js.map +1 -0
- package/dist/session-terminal-refusal.d.ts +65 -0
- package/dist/session-terminal-refusal.d.ts.map +1 -0
- package/dist/session-terminal-refusal.js +87 -0
- package/dist/session-terminal-refusal.js.map +1 -0
- package/dist/session-tree.d.ts +110 -0
- package/dist/session-tree.d.ts.map +1 -0
- package/dist/session-tree.js +144 -0
- package/dist/session-tree.js.map +1 -0
- package/dist/session-views.d.ts +47 -0
- package/dist/session-views.d.ts.map +1 -0
- package/dist/session-views.js +278 -0
- package/dist/session-views.js.map +1 -0
- package/dist/signal-handlers.d.ts +63 -0
- package/dist/signal-handlers.d.ts.map +1 -0
- package/dist/signal-handlers.js +980 -0
- package/dist/signal-handlers.js.map +1 -0
- package/dist/signal-requirement-policy.d.ts +51 -0
- package/dist/signal-requirement-policy.d.ts.map +1 -0
- package/dist/signal-requirement-policy.js +89 -0
- package/dist/signal-requirement-policy.js.map +1 -0
- package/dist/signal-revocability.d.ts +49 -0
- package/dist/signal-revocability.d.ts.map +1 -0
- package/dist/signal-revocability.js +93 -0
- package/dist/signal-revocability.js.map +1 -0
- package/dist/signal-submission.d.ts +181 -0
- package/dist/signal-submission.d.ts.map +1 -0
- package/dist/signal-submission.js +368 -0
- package/dist/signal-submission.js.map +1 -0
- package/dist/signaling-connect.d.ts +118 -0
- package/dist/signaling-connect.d.ts.map +1 -0
- package/dist/signaling-connect.js +538 -0
- package/dist/signaling-connect.js.map +1 -0
- package/dist/signaling-wiring.d.ts +105 -0
- package/dist/signaling-wiring.d.ts.map +1 -0
- package/dist/signaling-wiring.js +393 -0
- package/dist/signaling-wiring.js.map +1 -0
- package/dist/singleton-lock.d.ts +85 -0
- package/dist/singleton-lock.d.ts.map +1 -0
- package/dist/singleton-lock.js +219 -0
- package/dist/singleton-lock.js.map +1 -0
- package/dist/sqlcipher-db.d.ts +139 -0
- package/dist/sqlcipher-db.d.ts.map +1 -0
- package/dist/sqlcipher-db.js +357 -0
- package/dist/sqlcipher-db.js.map +1 -0
- package/dist/standing-receivers.d.ts +319 -0
- package/dist/standing-receivers.d.ts.map +1 -0
- package/dist/standing-receivers.js +1295 -0
- package/dist/standing-receivers.js.map +1 -0
- package/dist/start-agent.d.ts +64 -0
- package/dist/start-agent.d.ts.map +1 -0
- package/dist/start-agent.js +136 -0
- package/dist/start-agent.js.map +1 -0
- package/dist/status-handler.d.ts +54 -0
- package/dist/status-handler.d.ts.map +1 -0
- package/dist/status-handler.js +61 -0
- package/dist/status-handler.js.map +1 -0
- package/dist/submission-retry.d.ts +208 -0
- package/dist/submission-retry.d.ts.map +1 -0
- package/dist/submission-retry.js +506 -0
- package/dist/submission-retry.js.map +1 -0
- package/dist/telegram-bot-client.d.ts +34 -0
- package/dist/telegram-bot-client.d.ts.map +1 -0
- package/dist/telegram-bot-client.js +36 -0
- package/dist/telegram-bot-client.js.map +1 -0
- package/dist/telegram-doorbell.d.ts +38 -0
- package/dist/telegram-doorbell.d.ts.map +1 -0
- package/dist/telegram-doorbell.js +140 -0
- package/dist/telegram-doorbell.js.map +1 -0
- package/dist/test-handlers.d.ts +62 -0
- package/dist/test-handlers.d.ts.map +1 -0
- package/dist/test-handlers.js +240 -0
- package/dist/test-handlers.js.map +1 -0
- package/dist/testing.d.ts +10 -0
- package/dist/testing.d.ts.map +1 -0
- package/dist/testing.js +10 -0
- package/dist/testing.js.map +1 -0
- package/dist/transport-composition.d.ts +31 -0
- package/dist/transport-composition.d.ts.map +1 -0
- package/dist/transport-composition.js +55 -0
- package/dist/transport-composition.js.map +1 -0
- package/dist/transport-selector.d.ts +202 -0
- package/dist/transport-selector.d.ts.map +1 -0
- package/dist/transport-selector.js +196 -0
- package/dist/transport-selector.js.map +1 -0
- package/dist/trust-signal-pickup-listener.d.ts +43 -0
- package/dist/trust-signal-pickup-listener.d.ts.map +1 -0
- package/dist/trust-signal-pickup-listener.js +48 -0
- package/dist/trust-signal-pickup-listener.js.map +1 -0
- package/dist/trust-signal-store.d.ts +406 -0
- package/dist/trust-signal-store.d.ts.map +1 -0
- package/dist/trust-signal-store.js +939 -0
- package/dist/trust-signal-store.js.map +1 -0
- package/dist/trust-signal-sweep-tick.d.ts +60 -0
- package/dist/trust-signal-sweep-tick.d.ts.map +1 -0
- package/dist/trust-signal-sweep-tick.js +101 -0
- package/dist/trust-signal-sweep-tick.js.map +1 -0
- package/dist/trust-signal-sweep.d.ts +94 -0
- package/dist/trust-signal-sweep.d.ts.map +1 -0
- package/dist/trust-signal-sweep.js +147 -0
- package/dist/trust-signal-sweep.js.map +1 -0
- package/dist/type-registry.d.ts +42 -0
- package/dist/type-registry.d.ts.map +1 -0
- package/dist/type-registry.js +37 -0
- package/dist/type-registry.js.map +1 -0
- package/dist/types.d.ts +746 -0
- package/dist/types.d.ts.map +1 -0
- package/dist/types.js +20 -0
- package/dist/types.js.map +1 -0
- package/dist/unresolved-nodes-report.d.ts +14 -0
- package/dist/unresolved-nodes-report.d.ts.map +1 -0
- package/dist/unresolved-nodes-report.js +96 -0
- package/dist/unresolved-nodes-report.js.map +1 -0
- package/dist/vocabulary.d.ts +150 -0
- package/dist/vocabulary.d.ts.map +1 -0
- package/dist/vocabulary.js +386 -0
- package/dist/vocabulary.js.map +1 -0
- package/dist/who-label.d.ts +28 -0
- package/dist/who-label.d.ts.map +1 -0
- package/dist/who-label.js +31 -0
- package/dist/who-label.js.map +1 -0
- package/dist/who-resolver.d.ts +15 -0
- package/dist/who-resolver.d.ts.map +1 -0
- package/dist/who-resolver.js +47 -0
- package/dist/who-resolver.js.map +1 -0
- package/dist/wire-content-hash.d.ts +93 -0
- package/dist/wire-content-hash.d.ts.map +1 -0
- package/dist/wire-content-hash.js +116 -0
- package/dist/wire-content-hash.js.map +1 -0
- package/dist/withheld-content.d.ts +13 -0
- package/dist/withheld-content.d.ts.map +1 -0
- package/dist/withheld-content.js +46 -0
- package/dist/withheld-content.js.map +1 -0
- package/dist/witness-alerts.d.ts +40 -0
- package/dist/witness-alerts.d.ts.map +1 -0
- package/dist/witness-alerts.js +102 -0
- package/dist/witness-alerts.js.map +1 -0
- package/package.json +5 -5
|
@@ -0,0 +1,223 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* DOD-DOC-SCREEN-1 — the document content gate: REFUSE, never mutate.
|
|
3
|
+
*
|
|
4
|
+
* ── WHY A DOCUMENT DOES NOT GET THE MESSAGE SANITIZER ─────────────────────────────────────────
|
|
5
|
+
*
|
|
6
|
+
* The inbound message path may REWRITE content on a `redact` verdict: the operator sees a sanitized
|
|
7
|
+
* form while the leaf still binds the original. That is right for conversation and catastrophic for
|
|
8
|
+
* a document. Measured on 2026-08-05 against eighteen realistic samples, six were silently altered:
|
|
9
|
+
*
|
|
10
|
+
* कर्म → कर्म a different Hindi word; the ZWJ is orthography in Devanagari
|
|
11
|
+
* 👨👩👧 → 👨👩👧 one family emoji becomes three separate people
|
|
12
|
+
* Hello → Hello full-width is how CJK users type
|
|
13
|
+
* file is ½ → file is 1⁄2 ligatures and fractions normalised away
|
|
14
|
+
* <|im_start|> → ␠ a document ABOUT prompt formats loses its subject
|
|
15
|
+
*
|
|
16
|
+
* For a CRDT replica that is not a false positive. It is permanent divergence: the receiver applies
|
|
17
|
+
* different bytes than the sender signed, both sides believe they converged, and nothing reports
|
|
18
|
+
* it. And screening the PROJECTION instead does not help — documents are read-WRITE, so the next
|
|
19
|
+
* write-back diffs the operator's screened file against their replica and publishes the redaction
|
|
20
|
+
* as a real, signed edit that deletes the peer's content.
|
|
21
|
+
*
|
|
22
|
+
* So this rule has exactly two outcomes: carry the text exactly, or refuse the envelope. There is
|
|
23
|
+
* no third return value, and that is deliberate — a rule that COULD return replacement text would
|
|
24
|
+
* eventually be used to.
|
|
25
|
+
*
|
|
26
|
+
* ── WHAT IT REFUSES, AND WHY THAT LIST IS SHORT ───────────────────────────────────────────────
|
|
27
|
+
*
|
|
28
|
+
* Only characters whose presence changes what the text MEANS to a reader or a model, independent of
|
|
29
|
+
* language:
|
|
30
|
+
*
|
|
31
|
+
* - BIDI overrides and isolates, which make what an operator reads differ from what the document
|
|
32
|
+
* says. In a shared document that is a signature on content the signer did not see.
|
|
33
|
+
* - Chat-template control markers, which are not content in any document — they are an attempt to
|
|
34
|
+
* address the reader's model rather than the reader.
|
|
35
|
+
*
|
|
36
|
+
* NOT on the list: zero-width joiners, full-width forms, ligatures, typographic punctuation,
|
|
37
|
+
* combining marks. Every one of those is legitimate text in some language, and refusing them would
|
|
38
|
+
* make CELLO unusable for the operators most likely to need it. Zero-width SPACE is refused —
|
|
39
|
+
* it joins nothing, and its only use in a document is to hide a boundary.
|
|
40
|
+
*
|
|
41
|
+
* This is the denylist half. `DOD-DOC-PROFILE-1` adds the allowlist: a codepoint set agreed at the
|
|
42
|
+
* handshake and bound into `document_id`, which is a stronger instrument because it is decided at
|
|
43
|
+
* consent rather than argued at the boundary. This rule stays underneath it — a profile a peer
|
|
44
|
+
* never agreed to cannot be used to smuggle a BIDI override.
|
|
45
|
+
*/
|
|
46
|
+
import { PRIVILEGED_TURN_MARKERS, pipeTurnMarkerRegex } from "@cello-protocol/gateway";
|
|
47
|
+
import { profileViolation } from "./document-profile.js";
|
|
48
|
+
/** Named so a refusal can say which rule fired without the sender parsing prose (§16.7-6). */
|
|
49
|
+
export const SCREEN_RULE_ID = "document_content_screen";
|
|
50
|
+
/** Named separately so a refusal says WHICH screen refused — the gateway's, not this module's. */
|
|
51
|
+
export const SEMANTIC_RULE_ID = "document_content_semantic_screen";
|
|
52
|
+
/** Named separately so a refusal says whether the AGREED profile or the default floor refused. */
|
|
53
|
+
export const PROFILE_RULE_ID = "document_content_profile";
|
|
54
|
+
/**
|
|
55
|
+
* The one sentence every surface uses to say WHY, so the four call sites cannot describe the same
|
|
56
|
+
* rule differently. It names both halves: the earlier wording described only the invisible-character
|
|
57
|
+
* half, which reads as nonsense to an operator who was refused for `[INST]`.
|
|
58
|
+
*/
|
|
59
|
+
export const SCREEN_GUIDANCE = "These are either invisible or direction-altering characters, which make what a reader SEES " +
|
|
60
|
+
"differ from what the document SAYS, or chat-template markers, which address a reader's model " +
|
|
61
|
+
"rather than the reader.";
|
|
62
|
+
/**
|
|
63
|
+
* Codepoints refused anywhere in inserted text.
|
|
64
|
+
*
|
|
65
|
+
* Every entry needs a reason that survives the question "is this legitimate in some language?" —
|
|
66
|
+
* because for almost every invisible character the answer is yes, and the audit above is what
|
|
67
|
+
* happens when that question is not asked.
|
|
68
|
+
*/
|
|
69
|
+
const REFUSED_CODEPOINTS = new Set([
|
|
70
|
+
0x200b, // ZERO WIDTH SPACE — joins nothing; in a document it only hides a boundary
|
|
71
|
+
0x202a, // LEFT-TO-RIGHT EMBEDDING
|
|
72
|
+
0x202b, // RIGHT-TO-LEFT EMBEDDING
|
|
73
|
+
0x202c, // POP DIRECTIONAL FORMATTING
|
|
74
|
+
0x202d, // LEFT-TO-RIGHT OVERRIDE
|
|
75
|
+
0x202e, // RIGHT-TO-LEFT OVERRIDE — renders text as something other than it is
|
|
76
|
+
0x2066, // LEFT-TO-RIGHT ISOLATE
|
|
77
|
+
0x2067, // RIGHT-TO-LEFT ISOLATE
|
|
78
|
+
0x2068, // FIRST STRONG ISOLATE
|
|
79
|
+
0x2069, // POP DIRECTIONAL ISOLATE
|
|
80
|
+
]);
|
|
81
|
+
/**
|
|
82
|
+
* Markers that address the READER'S MODEL rather than the reader.
|
|
83
|
+
*
|
|
84
|
+
* THE LIST IS THE MESSAGE PATH'S LIST. Two copies of a security literal drift, and this one had
|
|
85
|
+
* drifted: four markers where the sanitizer strips ten, and matched case-sensitively where the
|
|
86
|
+
* sanitizer is deliberately case-insensitive ("bypassable by shift-key" is its own wording). So
|
|
87
|
+
* `[SYSTEM]`, `<<SYS>>`, `[INST]`, `SYSTEM PROMPT:` and `<|IM_START|>` reached an operator's agent
|
|
88
|
+
* through a shared document while being stripped out of every message. The affordance prefix is the
|
|
89
|
+
* sharpest: the sanitizer strips it so relayed text cannot forge local provenance, and a document
|
|
90
|
+
* carried it verbatim.
|
|
91
|
+
*
|
|
92
|
+
* Same list, different remedy — the message path strips, a signed CRDT replica cannot be rewritten,
|
|
93
|
+
* so this path REFUSES. Refusing is honest: a document about prompt formats is told which literal
|
|
94
|
+
* to quote differently, where erasing would change its subject without saying so.
|
|
95
|
+
*
|
|
96
|
+
* NOT taken from the sanitizer, deliberately: its `### Instruction:` heading family and its `</s>`
|
|
97
|
+
* pattern are ordinary markdown and ordinary prose in a technical document. Refusing those would
|
|
98
|
+
* refuse legitimate writing, which is the false-positive class this whole rule exists to avoid.
|
|
99
|
+
*/
|
|
100
|
+
/**
|
|
101
|
+
* The prose-ambiguous members of the shared list, excluded HERE and only here.
|
|
102
|
+
*
|
|
103
|
+
* A message gets these STRIPPED, which costs a reader a few characters. A document gets a hard
|
|
104
|
+
* REFUSAL, and these three are ordinary English and ordinary markup:
|
|
105
|
+
* - `SYSTEM PROMPT:` — "Here is the system prompt: keep it short" is a sentence someone writes.
|
|
106
|
+
* - `<system>` / `</system>` — a tag in any XML or config document.
|
|
107
|
+
* Refusing them would refuse legitimate writing, which is the false-positive class this whole rule
|
|
108
|
+
* exists to avoid, and the same objection that kept `### Instruction:` and `</s>` off the list.
|
|
109
|
+
* Excluded by name rather than by omission so the choice is visible and testable.
|
|
110
|
+
*/
|
|
111
|
+
export const PROSE_AMBIGUOUS = ["SYSTEM PROMPT:", "<system>", "</system>"];
|
|
112
|
+
const REFUSED_MARKERS = PRIVILEGED_TURN_MARKERS.filter((m) => !PROSE_AMBIGUOUS.includes(m));
|
|
113
|
+
/** `U+XXXX`, uppercase, at least four digits — the form a human reads and a machine can match. */
|
|
114
|
+
function formatCodepoint(cp) {
|
|
115
|
+
return `U+${cp.toString(16).toUpperCase().padStart(4, "0")}`;
|
|
116
|
+
}
|
|
117
|
+
/** A literal is data, not a pattern — `[SYSTEM]` is a character class until it is escaped. */
|
|
118
|
+
function escapeForRegex(literal) {
|
|
119
|
+
return literal.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
120
|
+
}
|
|
121
|
+
/**
|
|
122
|
+
* The rule. Null admits; anything else refuses.
|
|
123
|
+
*
|
|
124
|
+
* Offsets are in CODE POINTS, not UTF-16 units, because they exist for a human or an agent to find
|
|
125
|
+
* the character in their own editor — and an offset that lands mid-surrogate in a document with an
|
|
126
|
+
* emoji in it is worse than none.
|
|
127
|
+
*/
|
|
128
|
+
/**
|
|
129
|
+
* The denylist scan itself, over plain text — no gate, no diff, no context.
|
|
130
|
+
*
|
|
131
|
+
* Extracted so the AUTHORING check and the RECEIVING gate cannot drift. Two implementations of one
|
|
132
|
+
* rule is how a sender-side "advisory" ends up refusing things the receiver admits, or worse
|
|
133
|
+
* admitting things it refuses — and this milestone has now been bitten four times by a second copy
|
|
134
|
+
* of a rule that was supposed to match the first.
|
|
135
|
+
*
|
|
136
|
+
* Returns null when the text is clean; otherwise every distinct offender, a count, and CODE-POINT
|
|
137
|
+
* offsets (not UTF-16, which lands mid-surrogate in any document containing an emoji).
|
|
138
|
+
*/
|
|
139
|
+
export function screenText(text) {
|
|
140
|
+
if (text.length === 0)
|
|
141
|
+
return null;
|
|
142
|
+
const codepoints = new Set();
|
|
143
|
+
const offsets = [];
|
|
144
|
+
let index = 0;
|
|
145
|
+
for (const ch of text) {
|
|
146
|
+
const cp = ch.codePointAt(0);
|
|
147
|
+
if (REFUSED_CODEPOINTS.has(cp)) {
|
|
148
|
+
codepoints.add(formatCodepoint(cp));
|
|
149
|
+
offsets.push(index);
|
|
150
|
+
}
|
|
151
|
+
index++;
|
|
152
|
+
}
|
|
153
|
+
// Case-INSENSITIVE. `[CELLO Security Layer, Local]` is the same claim of provenance to a model as
|
|
154
|
+
// the lowercase form, so a case-sensitive search leaves every marker bypassable by shift-key —
|
|
155
|
+
// the sanitizer's own reasoning, which this path did not carry.
|
|
156
|
+
//
|
|
157
|
+
// Matched on the ORIGINAL text with a case-insensitive pattern, never by scanning a lowercased
|
|
158
|
+
// copy: `toLowerCase` can change UTF-16 LENGTH (`İ` lowercases to two units), so an index into the
|
|
159
|
+
// copy does not address the original and the reported offset skews by one per such character.
|
|
160
|
+
// Offsets exist for a human to find the marker in their own editor — a wrong one is worse than none.
|
|
161
|
+
for (const marker of REFUSED_MARKERS) {
|
|
162
|
+
for (const m of text.matchAll(new RegExp(escapeForRegex(marker), "gi"))) {
|
|
163
|
+
// The marker AS WRITTEN in the list, not as the sender cased it — the sender needs to know
|
|
164
|
+
// which literal to stop emitting, and its casing is not the thing being refused.
|
|
165
|
+
codepoints.add(marker);
|
|
166
|
+
offsets.push([...text.slice(0, m.index)].length);
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
// Any pipe-delimited turn marker, not an enumerated four — a model family this build has never
|
|
170
|
+
// heard of names its turns the same way, and enumerating them is a list that is always one short.
|
|
171
|
+
for (const m of text.matchAll(pipeTurnMarkerRegex())) {
|
|
172
|
+
// LOWERCASED, for the reason the literal branch names the list form: this string is read back to
|
|
173
|
+
// the operator's agent in the refusal guidance, and reflecting an attacker's exact casing puts
|
|
174
|
+
// the very marker the message path exists to strip into a model's context.
|
|
175
|
+
codepoints.add(m[0].toLowerCase());
|
|
176
|
+
offsets.push([...text.slice(0, m.index)].length);
|
|
177
|
+
}
|
|
178
|
+
if (codepoints.size === 0)
|
|
179
|
+
return null;
|
|
180
|
+
offsets.sort((a, b) => a - b);
|
|
181
|
+
return { codepoints: [...codepoints], count: offsets.length, offsets };
|
|
182
|
+
}
|
|
183
|
+
export const screeningRule = (diff, context) => {
|
|
184
|
+
const text = diff.inserted;
|
|
185
|
+
if (text.length === 0)
|
|
186
|
+
return null;
|
|
187
|
+
// THE AGREED PROFILE FIRST (DOD-DOC-PROFILE-1). An allowlist is the stronger instrument — the
|
|
188
|
+
// decision was made once, at consent, by a human who was engaged — so when a document has one it
|
|
189
|
+
// answers before the denylist argues character by character.
|
|
190
|
+
//
|
|
191
|
+
// It cannot WIDEN anything: every profile still refuses what the denylist below refuses, so a
|
|
192
|
+
// peer cannot ask for a permissive profile at consent time as a way out of screening. Enforced
|
|
193
|
+
// here because the sender's own enforcement is unverifiable; that is the security half, and the
|
|
194
|
+
// authoring check is the ergonomics half, not a substitute for it.
|
|
195
|
+
const violation = profileViolation(context.contentProfile, text);
|
|
196
|
+
if (violation) {
|
|
197
|
+
return {
|
|
198
|
+
reason: "document_profile_violation",
|
|
199
|
+
detail: JSON.stringify({ rule: PROFILE_RULE_ID, ...violation }),
|
|
200
|
+
};
|
|
201
|
+
}
|
|
202
|
+
// ONE implementation, shared with the authoring check — see `screenText`.
|
|
203
|
+
const found = screenText(text);
|
|
204
|
+
if (!found)
|
|
205
|
+
return null;
|
|
206
|
+
const { codepoints, count, offsets } = found;
|
|
207
|
+
return {
|
|
208
|
+
reason: "document_content_refused",
|
|
209
|
+
// MACHINE-READABLE (§16.7-6). The default resolution is that the SENDER adopts the receiver's
|
|
210
|
+
// rule for this document — rules compose toward strict — and that only works if the sender can
|
|
211
|
+
// tell which character to stop emitting. Prose cannot carry that.
|
|
212
|
+
//
|
|
213
|
+
// Every distinct offender is named, not just the first: one round trip per character would be a
|
|
214
|
+
// rejection round each, and the protocol stalls at three.
|
|
215
|
+
detail: JSON.stringify({
|
|
216
|
+
rule: SCREEN_RULE_ID,
|
|
217
|
+
codepoints,
|
|
218
|
+
count,
|
|
219
|
+
offsets,
|
|
220
|
+
}),
|
|
221
|
+
};
|
|
222
|
+
};
|
|
223
|
+
//# sourceMappingURL=document-screen.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"document-screen.js","sourceRoot":"","sources":["../src/document-screen.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4CG;AAEH,OAAO,EAAE,uBAAuB,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC;AAEvF,OAAO,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AAEzD,8FAA8F;AAC9F,MAAM,CAAC,MAAM,cAAc,GAAG,yBAAyB,CAAC;AAExD,kGAAkG;AAClG,MAAM,CAAC,MAAM,gBAAgB,GAAG,kCAAkC,CAAC;AAEnE,kGAAkG;AAClG,MAAM,CAAC,MAAM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F;QAC9F,+FAA+F;QAC/F,kEAAkE;QAClE,EAAE;QACF,gGAAgG;QAChG,0DAA0D;QAC1D,MAAM,EAAE,IAAI,CAAC,SAAS,CAAC;YACrB,IAAI,EAAE,cAAc;YACpB,UAAU;YACV,KAAK;YACL,OAAO;SACR,CAAC;KACH,CAAC;AACJ,CAAC,CAAC"}
|
|
@@ -0,0 +1,372 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* DOD-DOC-STORE-1 — the daemon's three document tables (§16.7-12).
|
|
3
|
+
*
|
|
4
|
+
* TWO LAYERS, NOT ONE (§14). Storing only a merged Yjs binary would discard the signed envelope
|
|
5
|
+
* chain that makes a seal verifiable, so both are kept:
|
|
6
|
+
*
|
|
7
|
+
* `document_envelopes` — the IMMUTABLE log: signatures, provenance, the per-document chain.
|
|
8
|
+
* This is the truth.
|
|
9
|
+
* `document_snapshots` — a MATERIALIZATION for fast start. Disposable by construction:
|
|
10
|
+
* delete it and it rebuilds from the log, byte-identical.
|
|
11
|
+
*
|
|
12
|
+
* The distinction is load-bearing rather than stylistic. Live Yjs state deliberately does NOT
|
|
13
|
+
* survive a daemon restart — CELLO's invariant is daemon-up-is-CELLO-on — and that is only safe
|
|
14
|
+
* because the log makes rebuilding a lookup rather than an archaeology exercise.
|
|
15
|
+
*
|
|
16
|
+
* THIS MODULE PERSISTS; IT DOES NOT APPLY. Replay is INJECTED (`rebuildSnapshot`), so the store
|
|
17
|
+
* owns *what to replay and in what order* while the engine (DOD-DOC-ENGINE-1) owns *how to
|
|
18
|
+
* apply*. That keeps `yjs` out of this file's imports entirely and keeps the P0/P1 boundary
|
|
19
|
+
* honest — a store that quietly grew a Y.Doc would be the engine wearing a store's name.
|
|
20
|
+
*
|
|
21
|
+
* WHAT IS NEVER STORED HERE: a Yjs clientID. §14's one-line rule is "let Yjs mint its own per
|
|
22
|
+
* live Y.Doc; never derive it from agent identity, never persist and restore one." DOD-DOC-FUZZ-1
|
|
23
|
+
* measured the cost of getting this wrong — two live docs sharing a clientID means the colliding
|
|
24
|
+
* writer silently wins, the honest client's update is accepted-and-dropped, and the result is a
|
|
25
|
+
* splice of two authors with an EMPTY pending set and no error on any path. So the snapshot
|
|
26
|
+
* stores a binary and a state vector, and nothing that could be restored into a live document as
|
|
27
|
+
* an identity.
|
|
28
|
+
*
|
|
29
|
+
* KEYED ON STABLE IDS ONLY. `agent_id` and `document_id`, never `agent_name` — it is a mutable
|
|
30
|
+
* display label and reusable after retirement. The M7 session tables join on `agent_name`; that
|
|
31
|
+
* is a known defect (`DOD-AGENT-ID-JOINKEY-1`), not a precedent to copy.
|
|
32
|
+
*/
|
|
33
|
+
import type { DaemonDatabase } from "./sqlcipher-db.js";
|
|
34
|
+
import type { Logger } from "./types.js";
|
|
35
|
+
/** Lifecycle states a document can hold (§3.5). `stalled` is DOD-DOC-REJECT-1's terminal state. */
|
|
36
|
+
export type DocumentStatus = "active" | "closed" | "killed" | "stalled";
|
|
37
|
+
/**
|
|
38
|
+
* What an envelope IS, as opposed to what it says. A withdrawal or a rejection is a NEW ROW that
|
|
39
|
+
* references an earlier envelope — never an edit to it. The log is append-only, so the only way
|
|
40
|
+
* to say "that one no longer counts" is to add a record saying so.
|
|
41
|
+
*/
|
|
42
|
+
export type DocumentEnvelopeKind = "update" | "withdrawal" | "rejection";
|
|
43
|
+
/**
|
|
44
|
+
* RE-EXPORTED, not redefined.
|
|
45
|
+
*
|
|
46
|
+
* This was a second, structurally-similar interface declared here, and that is a drift risk with
|
|
47
|
+
* teeth: `properties` is inside the proposal's SIGNED preimage and `seamViolation` reads it, so two
|
|
48
|
+
* definitions of what a property is means two answers to what is admissible — one enforced at the
|
|
49
|
+
* signature and one at the store. They agreed by coincidence, and the first field added to one of
|
|
50
|
+
* them would have ended that quietly.
|
|
51
|
+
*/
|
|
52
|
+
export type { DocumentProperties } from "@cello-protocol/protocol-types";
|
|
53
|
+
import type { DocumentProperties } from "@cello-protocol/protocol-types";
|
|
54
|
+
export interface DocumentRow {
|
|
55
|
+
documentId: string;
|
|
56
|
+
ownerAgentId: string;
|
|
57
|
+
peerAgentId: string;
|
|
58
|
+
documentType: string;
|
|
59
|
+
properties: DocumentProperties;
|
|
60
|
+
status: DocumentStatus;
|
|
61
|
+
createdAtMs: number;
|
|
62
|
+
}
|
|
63
|
+
export interface DocumentEnvelopeRow {
|
|
64
|
+
/** Content hash of the envelope — the stable identity, and the log's primary key. */
|
|
65
|
+
envelopeHash: string;
|
|
66
|
+
documentId: string;
|
|
67
|
+
/** WHO authored it. The chain is per-sender, so this is what partitions it. */
|
|
68
|
+
senderAgentId: string;
|
|
69
|
+
/** The sender's previous envelope for this document, or null at genesis (§9.1). */
|
|
70
|
+
docPrevHash: string | null;
|
|
71
|
+
signature: Uint8Array;
|
|
72
|
+
/** The sender's Yjs state vector at publish time (§7). */
|
|
73
|
+
stateVector: Uint8Array;
|
|
74
|
+
/** NULLABLE — a purged envelope keeps its hash and signature, proving it existed (§16.7-12). */
|
|
75
|
+
payload: Uint8Array | null;
|
|
76
|
+
/** SYNC-G1: the author's governance frontier at authoring — entry hashes, from the signed TBS. */
|
|
77
|
+
governanceParents: string[];
|
|
78
|
+
kind: DocumentEnvelopeKind;
|
|
79
|
+
/** For a withdrawal or rejection: the envelope it concerns. */
|
|
80
|
+
referencesEnvelopeHash?: string | null;
|
|
81
|
+
createdAtMs: number;
|
|
82
|
+
/** The Yjs clientID this sender signed for — the gate's authorship binding. */
|
|
83
|
+
senderClientId?: number | null;
|
|
84
|
+
/** Position in this document's log. Assigned on append; absent until then. */
|
|
85
|
+
logIndex?: number;
|
|
86
|
+
}
|
|
87
|
+
export interface QuarantineRow {
|
|
88
|
+
documentId: string;
|
|
89
|
+
/** The 0x05 leaf this row belongs to — the PK. One leaf, one row; see the table comment. */
|
|
90
|
+
rejectionEnvelopeHash: string;
|
|
91
|
+
rejectedEnvelopeHash: string;
|
|
92
|
+
/** The refused envelope's own author and chain link, so the chain verifier can bridge it. */
|
|
93
|
+
rejectedSenderAgentId: string;
|
|
94
|
+
rejectedDocPrevHash: string | null;
|
|
95
|
+
payload: Uint8Array;
|
|
96
|
+
reason: string;
|
|
97
|
+
detail?: string;
|
|
98
|
+
/** Which pluggable rule refused, when one did — the gate produces this and it must not be lost. */
|
|
99
|
+
rule?: string;
|
|
100
|
+
limitName?: string;
|
|
101
|
+
limitValue?: number;
|
|
102
|
+
limitActual?: number;
|
|
103
|
+
/** SYNC-R35: the exact signed refusal frame; absent on rows born before it. */
|
|
104
|
+
rejectionWire?: Uint8Array;
|
|
105
|
+
createdAtMs: number;
|
|
106
|
+
}
|
|
107
|
+
export interface DocumentSnapshot {
|
|
108
|
+
binary: Uint8Array;
|
|
109
|
+
stateVector: Uint8Array;
|
|
110
|
+
/**
|
|
111
|
+
* The `log_index` of the last envelope this snapshot reflects. §14 is explicit about why it is
|
|
112
|
+
* stored rather than derived: with it, "where does the snapshot sit relative to the log" is a
|
|
113
|
+
* lookup; without it, every rebuild works it out from scratch.
|
|
114
|
+
*
|
|
115
|
+
* **-1 means nothing has been applied.** The resume point is ALWAYS `lastAppliedIndex + 1`,
|
|
116
|
+
* so an empty log yields 0 and `getEnvelopesSince(0)` reads the whole log — the sentinel and
|
|
117
|
+
* the convention are chosen to agree.
|
|
118
|
+
*/
|
|
119
|
+
lastAppliedIndex: number;
|
|
120
|
+
}
|
|
121
|
+
/** Thrown when a read path refuses to materialize over a chain that does not verify. */
|
|
122
|
+
export declare class DocumentChainError extends Error {
|
|
123
|
+
readonly reason: "document_chain_broken" | "document_chain_forked";
|
|
124
|
+
readonly detail: string;
|
|
125
|
+
constructor(reason: "document_chain_broken" | "document_chain_forked", detail: string);
|
|
126
|
+
}
|
|
127
|
+
export type ChainVerdict = {
|
|
128
|
+
ok: true;
|
|
129
|
+
} | {
|
|
130
|
+
ok: false;
|
|
131
|
+
reason: "document_chain_broken" | "document_chain_forked";
|
|
132
|
+
detail: string;
|
|
133
|
+
};
|
|
134
|
+
/**
|
|
135
|
+
* Injected by the engine: fold an ordered envelope list into a materialized state.
|
|
136
|
+
*
|
|
137
|
+
* Takes ROWS, not bare payloads. The engine has to distinguish an update from a withdrawal or a
|
|
138
|
+
* rejection to fold correctly — a withdrawn envelope's payload must not be applied — and it
|
|
139
|
+
* cannot do that from `Uint8Array[]`. The store supplies the WHOLE log in order — withdrawal and
|
|
140
|
+
* rejection records included, payload-free though they are; deciding what counts is the engine's
|
|
141
|
+
* call, not the store's.
|
|
142
|
+
*/
|
|
143
|
+
export type ReplayFn = (envelopes: DocumentEnvelopeRow[]) => {
|
|
144
|
+
binary: Uint8Array;
|
|
145
|
+
stateVector: Uint8Array;
|
|
146
|
+
};
|
|
147
|
+
export declare class DocumentStore {
|
|
148
|
+
#private;
|
|
149
|
+
/**
|
|
150
|
+
* The underlying handle, for modules that own their OWN tables alongside this one
|
|
151
|
+
* (DocumentLifecycle). Deliberately not a licence to query this store's tables from outside —
|
|
152
|
+
* every one of them has a method here, and a second query path is a second set of rules about
|
|
153
|
+
* scoping that nobody remembers to keep in step.
|
|
154
|
+
*/
|
|
155
|
+
get rawDb(): DaemonDatabase;
|
|
156
|
+
constructor(db: DaemonDatabase, logger: Logger);
|
|
157
|
+
createDocument(row: DocumentRow): void;
|
|
158
|
+
getDocument(ownerAgentId: string, documentId: string): DocumentRow | null;
|
|
159
|
+
listDocuments(ownerAgentId: string): DocumentRow[];
|
|
160
|
+
setDocumentStatus(ownerAgentId: string, documentId: string, status: DocumentStatus): void;
|
|
161
|
+
/**
|
|
162
|
+
* Append an envelope at the next log position.
|
|
163
|
+
*
|
|
164
|
+
* IMMUTABLE AT A HASH: the conflict clause is scoped to the envelope hash ALONE, so a
|
|
165
|
+
* re-delivery — or a peer replaying the same hash with different bytes — cannot overwrite what
|
|
166
|
+
* was recorded. Returns whether a new row was written, so the caller can tell a genuine append
|
|
167
|
+
* from a duplicate rather than inferring it.
|
|
168
|
+
*
|
|
169
|
+
* Scoped deliberately, not written as a bare `OR IGNORE`: that form suppresses CHECK, UNIQUE
|
|
170
|
+
* and NOT NULL as well, which on an append-only log means a malformed `kind` or a colliding
|
|
171
|
+
* `log_index` would be DROPPED and reported to the caller as an already-seen duplicate. Every
|
|
172
|
+
* constraint except the hash conflict must throw, or `false` means three different things the
|
|
173
|
+
* caller cannot tell apart.
|
|
174
|
+
*/
|
|
175
|
+
appendEnvelope(ownerAgentId: string, envelope: DocumentEnvelopeRow): boolean;
|
|
176
|
+
/**
|
|
177
|
+
* Envelopes at or after `fromIndex`, in log order. This is what makes `lastAppliedIndex` the
|
|
178
|
+
* lookup §14 asks for: resume an incremental rebuild at `lastAppliedIndex + 1` without reading
|
|
179
|
+
* the whole log.
|
|
180
|
+
*/
|
|
181
|
+
getEnvelopesSince(ownerAgentId: string, documentId: string, fromIndex: number): DocumentEnvelopeRow[];
|
|
182
|
+
getEnvelopeLog(ownerAgentId: string, documentId: string): DocumentEnvelopeRow[];
|
|
183
|
+
/**
|
|
184
|
+
* Verify each sender's `doc_prev_hash` chain independently.
|
|
185
|
+
*
|
|
186
|
+
* The log interleaves both parties' envelopes, so there is no single total order to check —
|
|
187
|
+
* §16.7-5 defines replay set-based per epoch for exactly this reason. What must hold is that
|
|
188
|
+
* every sender's own links form one unbroken chain from a single genesis.
|
|
189
|
+
*
|
|
190
|
+
* A break REFUSES and names the sender and the missing predecessor. Skipping the leaf and
|
|
191
|
+
* carrying on would leave a document that reads as complete while missing operations, which is
|
|
192
|
+
* the silent-divergence failure the chain exists to prevent.
|
|
193
|
+
*
|
|
194
|
+
* LINKAGE ONLY — the name says so deliberately. This verifies no signature and does not check
|
|
195
|
+
* that `envelope_hash` hashes the content; neither is possible here (no key, no encoder). A
|
|
196
|
+
* caller must not read `ok: true` as authenticity — that belongs to the engine.
|
|
197
|
+
*/
|
|
198
|
+
verifyChainLinkage(ownerAgentId: string, documentId: string): ChainVerdict;
|
|
199
|
+
/**
|
|
200
|
+
* Hold a refused update's bytes. Idempotent per REJECTION (per 0x05 leaf), not per refused
|
|
201
|
+
* envelope — one envelope may be refused across several retry rounds and each round's reason,
|
|
202
|
+
* rule and limit are distinct facts an operator needs.
|
|
203
|
+
*
|
|
204
|
+
* Returns whether a row was written, so a caller never has to infer it. The previous signature
|
|
205
|
+
* returned void and the conflict clause silently dropped every round after the first.
|
|
206
|
+
*/
|
|
207
|
+
holdQuarantined(ownerAgentId: string, row: QuarantineRow): boolean;
|
|
208
|
+
listQuarantined(ownerAgentId: string, documentId: string): QuarantineRow[];
|
|
209
|
+
/**
|
|
210
|
+
* Release every entry for a refused envelope once its superseding update has been admitted.
|
|
211
|
+
* Returns whether anything was released. Keyed by the REFUSED envelope rather than the rejection
|
|
212
|
+
* leaf, because admitting the supersession resolves all of that envelope's rounds at once.
|
|
213
|
+
*/
|
|
214
|
+
releaseQuarantined(ownerAgentId: string, documentId: string, rejectedEnvelopeHash: string): boolean;
|
|
215
|
+
/**
|
|
216
|
+
* Every envelope hash we hold from one sender. Hash-only on purpose: the caller needs a set for a
|
|
217
|
+
* membership test, and `getEnvelopeLog` selects `*` — including every payload BLOB — so building
|
|
218
|
+
* that set from it materialized the whole document's content on every inbound update.
|
|
219
|
+
*/
|
|
220
|
+
knownEnvelopeHashesBySender(ownerAgentId: string, documentId: string, senderAgentId: string): Set<string>;
|
|
221
|
+
/** The clientIDs one sender has signed for on this document. Also hash-free — see above. */
|
|
222
|
+
senderClientIdsFor(ownerAgentId: string, documentId: string, senderAgentId: string): number[];
|
|
223
|
+
/**
|
|
224
|
+
* The state vector the PEER last told us they had — from their most recent envelope.
|
|
225
|
+
*
|
|
226
|
+
* This is what a publish diffs against (§3.2 step 3, §7): an update computed against what they
|
|
227
|
+
* have already seen carries exactly the operations they lack. Diffing against OUR OWN snapshot
|
|
228
|
+
* instead publishes what we have not yet snapshotted, which is a different question with an
|
|
229
|
+
* answer that happens to look plausible.
|
|
230
|
+
*/
|
|
231
|
+
peerStateVector(ownerAgentId: string, documentId: string, peerAgentId: string): Uint8Array | null;
|
|
232
|
+
/**
|
|
233
|
+
* The state vector OUR last published envelope carried — what we had when we last spoke.
|
|
234
|
+
*
|
|
235
|
+
* Distinct from `peerStateVector`, and the distinction is the point: that one answers "what does
|
|
236
|
+
* the peer lack" (what to send), this one answers "has anything changed since I last published"
|
|
237
|
+
* (whether to send at all). Conflating them meant a republish with no edits still produced a
|
|
238
|
+
* non-empty update, because before the peer has ever published the diff is the whole document.
|
|
239
|
+
*/
|
|
240
|
+
lastPublishedStateVector(ownerAgentId: string, documentId: string, senderAgentId: string): Uint8Array | null;
|
|
241
|
+
/** The rejecting agent's most recent envelope for this document, for chain linkage. */
|
|
242
|
+
/**
|
|
243
|
+
* The head of a sender's chain AS WE SEE IT — including envelopes we REFUSED.
|
|
244
|
+
*
|
|
245
|
+
* A refused envelope is never written to `document_envelopes`, but the sender's chain does not
|
|
246
|
+
* rewind: their supersession links to the envelope we just refused. Taking the head from the log
|
|
247
|
+
* alone meant that link never matched, so the supersession was refused as `document_chain_broken`
|
|
248
|
+
* — and so was everything after it, forever. Measured against two real daemons: the gate fired
|
|
249
|
+
* ONCE and the next three envelopes never reached it, so the retry round stuck at 1 and the
|
|
250
|
+
* document could never reach the stall the protocol defines.
|
|
251
|
+
*
|
|
252
|
+
* That is the bridge the quarantine was built for — it stores the refused envelope's own author
|
|
253
|
+
* and prev-hash saying exactly this — and it had only ever been applied to `verifyChainLinkage`,
|
|
254
|
+
* the local replay check. An earlier attempt added the quarantine to the KNOWN-hash set, which
|
|
255
|
+
* was not enough and is worth recording: `known` answers "have I seen this before" (duplicate
|
|
256
|
+
* detection), while the forward link is checked against the HEAD. Bridging the wrong one looks
|
|
257
|
+
* right and changes nothing.
|
|
258
|
+
*
|
|
259
|
+
* `log_index` and the quarantine's `created_at` are different clocks, so they are not merged into
|
|
260
|
+
* one ORDER BY. Whichever is newer by arrival is the head: a refusal always happens after the
|
|
261
|
+
* envelope it refuses, so a quarantine row newer than the last admitted envelope IS the head.
|
|
262
|
+
*/
|
|
263
|
+
lastEnvelopeHashBySender(ownerAgentId: string, documentId: string, senderAgentId: string): string | null;
|
|
264
|
+
/**
|
|
265
|
+
* Envelopes this agent authored that the peer has not acknowledged, and whose next attempt is
|
|
266
|
+
* due. DERIVED — there is no queue. Survives a restart because the log does.
|
|
267
|
+
*
|
|
268
|
+
* Scoped to `senderAgentId = ownerAgentId`: an envelope we RECEIVED is not ours to deliver, and
|
|
269
|
+
* without the scope a receiver would helpfully re-send the sender's own updates back at it.
|
|
270
|
+
*/
|
|
271
|
+
/**
|
|
272
|
+
* The document's CURRENT epoch: the head of its recorded amendment chain, 0 at genesis.
|
|
273
|
+
* Trustworthy for stamping because every append site rules on admissibility before
|
|
274
|
+
* recording — a row in document_amendments is post-validation by invariant (M14B Entry 5).
|
|
275
|
+
*/
|
|
276
|
+
/** SYNC-P5 (review F6) — per-sender envelope counts without hauling payload blobs. */
|
|
277
|
+
envelopeCountsBySender(ownerAgentId: string, documentId: string): Map<string, number>;
|
|
278
|
+
/** SYNC-P5 — record what a party's exchange just showed us (display cache; see the table). */
|
|
279
|
+
recordPartyView(ownerAgentId: string, documentId: string, partyAgentId: string, view: {
|
|
280
|
+
govSeqs: Record<string, number>;
|
|
281
|
+
contentCounts: Record<string, number>;
|
|
282
|
+
refused: string[];
|
|
283
|
+
}, nowMs: number): void;
|
|
284
|
+
partyView(ownerAgentId: string, documentId: string, partyAgentId: string): {
|
|
285
|
+
lastExchangeMs: number;
|
|
286
|
+
govSeqs: Record<string, number>;
|
|
287
|
+
contentCounts: Record<string, number>;
|
|
288
|
+
refused: string[];
|
|
289
|
+
} | null;
|
|
290
|
+
/** Record a rejection the PEER sent us. Returns whether a row was written (idempotent by leaf). */
|
|
291
|
+
recordRejectionReceived(ownerAgentId: string, row: {
|
|
292
|
+
documentId: string;
|
|
293
|
+
rejectionEnvelopeHash: string;
|
|
294
|
+
rejectedEnvelopeHash: string;
|
|
295
|
+
fromAgentId: string;
|
|
296
|
+
reason: string;
|
|
297
|
+
detail?: string;
|
|
298
|
+
createdAtMs: number;
|
|
299
|
+
}): boolean;
|
|
300
|
+
/**
|
|
301
|
+
* DOD-DOC-SCREEN-1 (§16.7-16) — SENDER ADOPTS THE RECEIVER'S RULE.
|
|
302
|
+
*
|
|
303
|
+
* The codepoints this peer has actually refused for this document, learned from their own signed
|
|
304
|
+
* refusals rather than assumed. Rules compose toward STRICT: once they have said no to a
|
|
305
|
+
* character, we stop emitting it, so the same refusal cannot be spent twice — and three refusals
|
|
306
|
+
* stall the document, which makes every avoidable one expensive.
|
|
307
|
+
*
|
|
308
|
+
* Scoped to (owner, document), never global. A rule adopted for one document must not silently
|
|
309
|
+
* narrow what an operator may write everywhere else — the peer refused it HERE, under the profile
|
|
310
|
+
* agreed HERE, and another peer may accept it happily.
|
|
311
|
+
*
|
|
312
|
+
* Stored as the refusal's own machine-readable codepoints, which is why the refusal was made
|
|
313
|
+
* machine-readable in the first place: prose cannot be adopted.
|
|
314
|
+
*/
|
|
315
|
+
adoptedRefusedCodepoints(ownerAgentId: string, documentId: string): Set<string>;
|
|
316
|
+
/**
|
|
317
|
+
* How many ROUNDS this document has been through — DISTINCT refused envelopes, not rows.
|
|
318
|
+
*
|
|
319
|
+
* ONE REFUSED ENVELOPE IS ONE ROUND, however many times the refusal is announced. A peer's refusal
|
|
320
|
+
* arrives TWICE by design: once as the signed `document_rejection` frame, and once as the ack that
|
|
321
|
+
* settles the delivery (`admitted: false`). Both are recorded — correctly, they are two real
|
|
322
|
+
* events — but the table is keyed on the ANNOUNCEMENT's hash, so the two land as separate rows.
|
|
323
|
+
*
|
|
324
|
+
* Counting rows therefore advanced the round by two per refusal, and `MAX_REJECTED_ROUNDS` is 3 —
|
|
325
|
+
* so a document stalled after TWO refusals instead of three, cutting the supersede-and-retry
|
|
326
|
+
* budget the protocol grants an operator by a third. Measured: the stall enforcer's sender was
|
|
327
|
+
* refused at attempt 2 with `document_stalled`.
|
|
328
|
+
*
|
|
329
|
+
* Counted rather than deduplicated on write, deliberately. Both announcements genuinely happened
|
|
330
|
+
* and the audit record should say so; what was wrong is the arithmetic built on top of it. And a
|
|
331
|
+
* UNIQUE index on the refused hash would fail to create on any database that already holds the
|
|
332
|
+
* duplicate rows this fix is about.
|
|
333
|
+
*
|
|
334
|
+
* Same principle as `ackRecordHash` one layer down — that one collapsed repeated ACKS of one
|
|
335
|
+
* envelope; this collapses the two KINDS of announcement of one refusal.
|
|
336
|
+
*/
|
|
337
|
+
countRejectionsReceived(ownerAgentId: string, documentId: string): number;
|
|
338
|
+
/**
|
|
339
|
+
* Was a rejection received for THIS envelope? Envelope-scoped on purpose: the document-scoped
|
|
340
|
+
* reader below answers a different question, and using it to decide whether one envelope was
|
|
341
|
+
* refused makes a rejection of any OTHER envelope in the document look like a rejection of this
|
|
342
|
+
* one.
|
|
343
|
+
*/
|
|
344
|
+
rejectionReceivedFor(ownerAgentId: string, documentId: string, envelopeHash: string): boolean;
|
|
345
|
+
/** The most recently received rejection, for the reason an operator is shown on a stall. */
|
|
346
|
+
latestRejectionReceived(ownerAgentId: string, documentId: string): {
|
|
347
|
+
reason: string;
|
|
348
|
+
detail?: string;
|
|
349
|
+
fromAgentId: string;
|
|
350
|
+
} | null;
|
|
351
|
+
/**
|
|
352
|
+
* How many rejection records this document carries, PER REJECTING AGENT — the retry round.
|
|
353
|
+
*
|
|
354
|
+
* Scoped by author, because a mutual exchange puts both directions' 0x05 leaves in one document
|
|
355
|
+
* log. Counting across senders conflated them, so two peers each rejecting once read as round 2
|
|
356
|
+
* and the document stalled at half the intended rounds.
|
|
357
|
+
*/
|
|
358
|
+
countRejections(ownerAgentId: string, documentId: string, rejectingAgentId: string): number;
|
|
359
|
+
getSnapshot(ownerAgentId: string, documentId: string): DocumentSnapshot | null;
|
|
360
|
+
/** REPLACES — a snapshot is a cache of the log, not a second log. */
|
|
361
|
+
putSnapshot(ownerAgentId: string, documentId: string, snapshot: DocumentSnapshot): void;
|
|
362
|
+
deleteSnapshot(ownerAgentId: string, documentId: string): void;
|
|
363
|
+
/**
|
|
364
|
+
* Rebuild a snapshot from the envelope log alone, using the caller's replay function.
|
|
365
|
+
*
|
|
366
|
+
* Payload-stripped envelopes (purged, or withdrawal/rejection records that carry none)
|
|
367
|
+
* contribute nothing to replay but STILL COUNT toward `lastAppliedIndex` — otherwise the next
|
|
368
|
+
* incremental rebuild would start behind them and replay them forever.
|
|
369
|
+
*/
|
|
370
|
+
rebuildSnapshot(ownerAgentId: string, documentId: string, replay: ReplayFn): DocumentSnapshot;
|
|
371
|
+
}
|
|
372
|
+
//# sourceMappingURL=document-store.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"document-store.d.ts","sourceRoot":"","sources":["../src/document-store.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AACxD,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC;AAOzC,mGAAmG;AACnG,MAAM,MAAM,cAAc,GAAG,QAAQ,GAAG,QAAQ,GAAG,QAAQ,GAAG,SAAS,CAAC;AAExE;;;;GAIG;AACH,MAAM,MAAM,oBAAoB,GAAG,QAAQ,GAAG,YAAY,GAAG,WAAW,CAAC;AAEzE;;;;;;;;GAQG;AACH,YAAY,EAAE,kBAAkB,EAAE,MAAM,gCAAgC,CAAC;AACzE,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,gCAAgC,CAAC;AAGzE,MAAM,WAAW,WAAW;IAC1B,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,EAAE,MAAM,CAAC;IACrB,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,EAAE,MAAM,CAAC;IACrB,UAAU,EAAE,kBAAkB,CAAC;IAC/B,MAAM,EAAE,cAAc,CAAC;IACvB,WAAW,EAAE,MAAM,CAAC;CACrB;AAED,MAAM,WAAW,mBAAmB;IAClC,qFAAqF;IACrF,YAAY,EAAE,MAAM,CAAC;IACrB,UAAU,EAAE,MA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