keri-ts 1.0.0 → 2.0.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/README.md +23 -0
- package/esm/keri/npm/src/acdc/chaining.js +213 -0
- package/esm/keri/npm/src/acdc/dhking.js +716 -0
- package/esm/keri/npm/src/acdc/messaging.js +2 -0
- package/esm/keri/npm/src/acdc/observing.js +40 -7
- package/esm/keri/npm/src/acdc/regbasing.js +13 -2
- package/esm/keri/npm/src/acdc/regengine.js +71 -23
- package/esm/keri/npm/src/acdc/regeventing.js +163 -44
- package/esm/keri/npm/src/acdc/registering.js +93 -14
- package/esm/keri/npm/src/acdc/relating.js +59 -0
- package/esm/keri/npm/src/acdc/salting.js +720 -0
- package/esm/keri/npm/src/acdc/scheming.js +94 -39
- package/esm/keri/npm/src/acdc/unblinding.js +1042 -0
- package/esm/keri/npm/src/app/{authenticating.js → bootstrap/authenticating.js} +39 -18
- package/esm/keri/npm/src/app/bootstrap/bootstrapping.js +109 -0
- package/esm/keri/npm/src/app/{oobi-replies.js → bootstrap/oobi-replies.js} +8 -6
- package/esm/keri/npm/src/app/{oobiery.js → bootstrap/oobiery.js} +161 -75
- package/esm/keri/npm/src/app/credentials/credential-importing.js +201 -0
- package/esm/keri/npm/src/app/credentials/credential-proposals.js +120 -0
- package/esm/keri/npm/src/app/credentials/credential-revoking.js +165 -0
- package/esm/keri/npm/src/app/credentials/credential-workflows.js +365 -0
- package/esm/keri/npm/src/app/credentials/tel-publishing.js +27 -0
- package/esm/keri/npm/src/app/{verifying.js → credentials/verifying.js} +41 -6
- package/esm/keri/npm/src/app/delivery/forwarding.js +600 -0
- package/esm/keri/npm/src/app/delivery/introducing.js +68 -0
- package/esm/keri/npm/src/app/{reply-streams.js → delivery/reply-streams.js} +52 -7
- package/esm/keri/npm/src/app/delivery/respondant.js +159 -0
- package/esm/keri/npm/src/app/{stored-replies.js → delivery/stored-replies.js} +4 -4
- package/esm/keri/npm/src/app/exchanges/essr.js +111 -0
- package/esm/keri/npm/src/app/exchanges/exchange-messaging.js +66 -0
- package/esm/keri/npm/src/app/exchanges/exchanging.js +1354 -0
- package/esm/keri/npm/src/app/{configing.js → identity/configing.js} +4 -4
- package/esm/keri/npm/src/app/{delegating.js → identity/delegating.js} +99 -29
- package/esm/keri/npm/src/app/{endpoint-roleing.js → identity/endpoint-roleing.js} +36 -36
- package/esm/keri/npm/src/app/{habbing.js → identity/habbing.js} +232 -150
- package/esm/keri/npm/src/app/{keeping.js → identity/keeping.js} +60 -56
- package/esm/keri/npm/src/app/{organizing.js → identity/organizing.js} +47 -21
- package/esm/keri/npm/src/app/ipex/ipex-building.js +162 -0
- package/esm/keri/npm/src/app/{ipex-credentialing.js → ipex/ipex-credentialing.js} +142 -31
- package/esm/keri/npm/src/app/ipex/ipex-graph.js +243 -0
- package/esm/keri/npm/src/app/ipex/ipex-grouping.js +664 -0
- package/esm/keri/npm/src/app/{ipex-node-authentication.js → ipex/ipex-node-authentication.js} +83 -6
- package/esm/keri/npm/src/app/ipex/ipex-v2.js +692 -0
- package/esm/keri/npm/src/app/{ipexing.js → ipex/ipexing.js} +58 -1
- package/esm/keri/npm/src/app/mailbox/forward-handler.js +228 -0
- package/esm/keri/npm/src/app/{mailbox-director.js → mailbox/mailbox-director.js} +120 -15
- package/esm/keri/npm/src/app/mailbox/mailbox-poller.js +305 -0
- package/esm/keri/npm/src/app/mailbox/mailbox-sse.js +254 -0
- package/esm/keri/npm/src/app/{mailboxing.js → mailbox/mailboxing.js} +118 -67
- package/esm/keri/npm/src/app/mailbox/topic-routing.js +54 -0
- package/esm/keri/npm/src/app/multisig/group-members.js +173 -0
- package/esm/keri/npm/src/app/{grouping.js → multisig/grouping.js} +384 -70
- package/esm/keri/npm/src/app/multisig/multisig-messaging.js +164 -0
- package/esm/keri/npm/src/app/multisig/multisig-workflows.js +821 -0
- package/esm/keri/npm/src/app/{notifying.js → notifications/notifying.js} +8 -14
- package/esm/keri/npm/src/app/{signaling.js → notifications/signaling.js} +1 -1
- package/esm/keri/npm/src/app/{parsering.js → protocol/parsering.js} +86 -18
- package/esm/keri/npm/src/app/protocol/protocol-processing.js +245 -0
- package/esm/keri/npm/src/app/protocol/reactor.js +55 -0
- package/esm/keri/npm/src/app/{query-replies.js → queries/query-replies.js} +57 -6
- package/esm/keri/npm/src/app/queries/querying.js +306 -0
- package/esm/keri/npm/src/app/queries/witness-inquisitor.js +415 -0
- package/esm/keri/npm/src/app/{abortable.js → runtime/abortable.js} +43 -4
- package/esm/keri/npm/src/app/runtime/agent-runtime.js +633 -0
- package/esm/keri/npm/src/app/runtime/cue-runtime.js +61 -0
- package/esm/keri/npm/src/app/runtime/runtime-clock.js +6 -0
- package/esm/keri/npm/src/app/{byte-source.js → transport/byte-source.js} +36 -6
- package/esm/keri/npm/src/app/transport/cesr-egress.js +317 -0
- package/esm/keri/npm/src/app/{cesr-http.js → transport/cesr-http.js} +20 -55
- package/esm/keri/npm/src/app/transport/http-client.js +172 -0
- package/esm/keri/npm/src/app/transport/http-messenger.js +52 -0
- package/esm/keri/npm/src/app/transport/http-stream-messenger.js +60 -0
- package/esm/keri/npm/src/app/transport/httping.js +57 -0
- package/esm/keri/npm/src/app/transport/message-source.js +77 -0
- package/esm/keri/npm/src/app/transport/messengering.js +68 -0
- package/esm/keri/npm/src/app/{socket-source.js → transport/socket-source.js} +39 -2
- package/esm/keri/npm/src/app/transport/tcp-egress.js +377 -0
- package/esm/keri/npm/src/app/transport/tcp-messenger.js +162 -0
- package/esm/keri/npm/src/app/transport/tcp-stream-messenger.js +40 -0
- package/esm/keri/npm/src/app/transport/transport-error.js +14 -0
- package/esm/keri/npm/src/app/witness/http-endpoints.js +185 -0
- package/esm/keri/npm/src/app/witness/ingress.js +148 -0
- package/esm/keri/npm/src/app/witness/receipt-client.js +248 -0
- package/esm/keri/npm/src/app/witness/receipt-messages.js +29 -0
- package/esm/keri/npm/src/app/witness/receipting.js +323 -0
- package/esm/keri/npm/src/app/witness/registration.js +50 -0
- package/esm/keri/npm/src/cli/common/bootstrap.js +12 -0
- package/esm/keri/npm/src/{app/cli → cli}/common/context.js +47 -6
- package/esm/keri/npm/src/{app/cli → cli}/common/existing.js +9 -11
- package/esm/keri/npm/src/cli/common/parsing.js +279 -0
- package/esm/keri/npm/src/cli/common/passcode.js +66 -0
- package/esm/keri/npm/src/cli/common/tel-completion.js +24 -0
- package/esm/keri/npm/src/{app/cli → cli}/common/witness-auth.js +2 -2
- package/esm/keri/npm/src/cli/credentials/ipex.js +702 -0
- package/esm/keri/npm/src/cli/credentials/vc.js +399 -0
- package/esm/keri/npm/src/{app/cli → cli/endpoints}/did.js +63 -36
- package/esm/keri/npm/src/{app/cli → cli/endpoints}/ends.js +33 -28
- package/esm/keri/npm/src/{app/cli → cli/endpoints}/loc.js +16 -11
- package/esm/keri/npm/src/cli/endpoints/oobi-clean.js +134 -0
- package/esm/keri/npm/src/{app/cli → cli/endpoints}/oobi.js +35 -32
- package/esm/keri/npm/src/{app/cli → cli/identity}/aid.js +8 -7
- package/esm/keri/npm/src/{app/cli → cli/identity}/challenge.js +60 -49
- package/esm/keri/npm/src/{app/cli → cli/identity}/delegate.js +61 -26
- package/esm/keri/npm/src/{app/cli → cli/identity}/export.js +9 -8
- package/esm/keri/npm/src/cli/identity/incept.js +181 -0
- package/esm/keri/npm/src/cli/identity/init.js +153 -0
- package/esm/keri/npm/src/cli/identity/interact.js +84 -0
- package/esm/keri/npm/src/{app/cli → cli/identity}/list.js +7 -6
- package/esm/keri/npm/src/{app/cli → cli/identity}/rotate.js +60 -57
- package/esm/keri/npm/src/cli/index.js +38 -0
- package/esm/keri/npm/src/{app/cli → cli/messaging}/exchange.js +24 -22
- package/esm/keri/npm/src/{app/cli → cli/messaging}/multisig.js +165 -156
- package/esm/keri/npm/src/{app/cli → cli/messaging}/notifications.js +26 -22
- package/esm/keri/npm/src/{app/cli → cli}/output.js +1 -1
- package/esm/keri/npm/src/{app/cli → cli/tools}/annotate.js +10 -4
- package/esm/keri/npm/src/{app/cli → cli/tools}/benchmark.js +15 -4
- package/esm/keri/npm/src/{app/cli → cli/tools}/db-dump.js +11 -10
- package/esm/keri/npm/src/{app/cli → cli/tools}/saidify.js +3 -2
- package/esm/keri/npm/src/{app/cli → cli/tools}/sign.js +16 -10
- package/esm/keri/npm/src/{app/cli → cli/tools}/verify.js +10 -10
- package/esm/keri/npm/src/core/attachment-countering.js +31 -1
- package/esm/keri/npm/src/core/{exchange-proofing.js → exchange/exchange-proofing.js} +32 -2
- package/esm/keri/npm/src/core/{protocol-exchanging.js → exchange/protocol-exchanging.js} +26 -4
- package/esm/keri/npm/src/core/genus-framing.js +44 -0
- package/esm/keri/npm/src/core/{eventing.js → kel/eventing.js} +57 -25
- package/esm/keri/npm/src/core/{kever-decisions.js → kel/kever-decisions.js} +24 -12
- package/esm/keri/npm/src/core/{kever.js → kel/kever.js} +4 -4
- package/esm/keri/npm/src/core/logger.js +3 -3
- package/esm/keri/npm/src/core/{kram-policy.js → mailbox/kram-policy.js} +14 -4
- package/esm/keri/npm/src/core/{kram-pruning.js → mailbox/kram-pruning.js} +3 -3
- package/esm/keri/npm/src/core/{kram-signatures.js → mailbox/kram-signatures.js} +1 -1
- package/esm/keri/npm/src/core/{kram-staging.js → mailbox/kram-staging.js} +6 -6
- package/esm/keri/npm/src/core/{kram-time.js → mailbox/kram-time.js} +4 -3
- package/esm/keri/npm/src/core/{kraming.js → mailbox/kraming.js} +2 -2
- package/esm/keri/npm/src/core/protocol-eventing.js +1 -1
- package/esm/keri/npm/src/core/protocol-serialization.js +9 -34
- package/esm/keri/npm/src/core/routing.js +52 -17
- package/esm/keri/npm/src/db/baser-defaults.js +11 -0
- package/esm/keri/npm/src/db/basing.js +89 -232
- package/esm/keri/npm/src/db/core/lmdber.js +102 -63
- package/esm/keri/npm/src/db/escrowing.js +73 -49
- package/esm/keri/npm/src/db/exchange/exchange-nests.js +54 -0
- package/esm/keri/npm/src/db/exchange/exchange-records.js +7 -0
- package/esm/keri/npm/src/db/index.js +5 -4
- package/esm/keri/npm/src/db/keeping.js +122 -3
- package/esm/keri/npm/src/db/{kram-factors.js → mailbox/kram-factors.js} +1 -1
- package/esm/keri/npm/src/db/{mailboxing.js → mailbox/mailboxing.js} +3 -3
- package/esm/keri/npm/src/db/reger.js +38 -29
- package/esm/keri/npm/src/db/{kel-replay.js → replay/kel-replay.js} +11 -4
- package/esm/keri/npm/src/db/{tel-replay.js → replay/tel-replay.js} +34 -0
- package/esm/keri/npm/src/db/{witness-replay.js → replay/witness-replay.js} +2 -2
- package/esm/keri/npm/src/db/subing.js +2 -3
- package/esm/keri/npm/src/did/webs/artifacts.js +15 -18
- package/esm/keri/npm/src/did/webs/designated-aliases.js +5 -7
- package/esm/keri/npm/src/did/webs/resolving.js +73 -56
- package/esm/keri/npm/src/library/index.js +1 -1
- package/esm/keri/npm/src/npm/cli.js +1 -1
- package/esm/keri/npm/src/npm/index.js +1 -1
- package/esm/keri/npm/src/runtime/index.js +79 -47
- package/esm/keri/npm/src/vdr/backer-state.js +55 -0
- package/esm/keri/npm/src/vdr/credential-tsn-record.js +59 -0
- package/esm/keri/npm/src/vdr/credentialing.js +84 -82
- package/esm/keri/npm/src/vdr/eventing.js +592 -204
- package/esm/keri/npm/src/vdr/registry-tsn-record.js +55 -0
- package/esm/keri/npm/src/vdr/revoking.js +90 -0
- package/esm/keri/npm/src/vdr/tel-anchor.js +29 -0
- package/esm/keri/npm/src/vdr/tel-publication.js +178 -0
- package/esm/keri/npm/src/{app/version.js → version.js} +2 -2
- package/package.json +5 -3
- package/types/_dnt.polyfills.d.ts +6 -0
- package/types/_dnt.polyfills.d.ts.map +1 -1
- package/types/acdc/chaining.d.ts +35 -0
- package/types/acdc/chaining.d.ts.map +1 -0
- package/types/acdc/dhking.d.ts +136 -0
- package/types/acdc/dhking.d.ts.map +1 -0
- package/types/acdc/messaging.d.ts.map +1 -1
- package/types/acdc/observing.d.ts +18 -7
- package/types/acdc/observing.d.ts.map +1 -1
- package/types/acdc/regbasing.d.ts +3 -1
- package/types/acdc/regbasing.d.ts.map +1 -1
- package/types/acdc/regengine.d.ts +9 -4
- package/types/acdc/regengine.d.ts.map +1 -1
- package/types/acdc/regeventing.d.ts +24 -7
- package/types/acdc/regeventing.d.ts.map +1 -1
- package/types/acdc/registering.d.ts +22 -6
- package/types/acdc/registering.d.ts.map +1 -1
- package/types/acdc/registraring.d.ts +1 -1
- package/types/acdc/registraring.d.ts.map +1 -1
- package/types/acdc/relating.d.ts +21 -0
- package/types/acdc/relating.d.ts.map +1 -0
- package/types/acdc/salting.d.ts +241 -0
- package/types/acdc/salting.d.ts.map +1 -0
- package/types/acdc/scheming.d.ts +1 -1
- package/types/acdc/scheming.d.ts.map +1 -1
- package/types/acdc/unblinding.d.ts +150 -0
- package/types/acdc/unblinding.d.ts.map +1 -0
- package/types/app/bootstrap/authenticating.d.ts +54 -0
- package/types/app/bootstrap/authenticating.d.ts.map +1 -0
- package/types/app/bootstrap/bootstrapping.d.ts +45 -0
- package/types/app/bootstrap/bootstrapping.d.ts.map +1 -0
- package/types/app/{oobi-replies.d.ts → bootstrap/oobi-replies.d.ts} +1 -1
- package/types/app/bootstrap/oobi-replies.d.ts.map +1 -0
- package/types/app/{oobiery.d.ts → bootstrap/oobiery.d.ts} +98 -25
- package/types/app/bootstrap/oobiery.d.ts.map +1 -0
- package/types/app/credentials/credential-importing.d.ts +29 -0
- package/types/app/credentials/credential-importing.d.ts.map +1 -0
- package/types/app/credentials/credential-proposals.d.ts +27 -0
- package/types/app/credentials/credential-proposals.d.ts.map +1 -0
- package/types/app/credentials/credential-revoking.d.ts +44 -0
- package/types/app/credentials/credential-revoking.d.ts.map +1 -0
- package/types/app/credentials/credential-workflows.d.ts +149 -0
- package/types/app/credentials/credential-workflows.d.ts.map +1 -0
- package/types/app/{schema-resolving.d.ts → credentials/schema-resolving.d.ts} +2 -2
- package/types/app/credentials/schema-resolving.d.ts.map +1 -0
- package/types/app/credentials/tel-publishing.d.ts +16 -0
- package/types/app/credentials/tel-publishing.d.ts.map +1 -0
- package/types/app/{verifying.d.ts → credentials/verifying.d.ts} +19 -7
- package/types/app/credentials/verifying.d.ts.map +1 -0
- package/types/app/delivery/forwarding.d.ts +227 -0
- package/types/app/delivery/forwarding.d.ts.map +1 -0
- package/types/app/delivery/introducing.d.ts +21 -0
- package/types/app/delivery/introducing.d.ts.map +1 -0
- package/types/app/delivery/reply-streams.d.ts +49 -0
- package/types/app/delivery/reply-streams.d.ts.map +1 -0
- package/types/app/delivery/respondant.d.ts +52 -0
- package/types/app/delivery/respondant.d.ts.map +1 -0
- package/types/app/{stored-replies.d.ts → delivery/stored-replies.d.ts} +1 -1
- package/types/app/delivery/stored-replies.d.ts.map +1 -0
- package/types/app/exchanges/essr.d.ts +53 -0
- package/types/app/exchanges/essr.d.ts.map +1 -0
- package/types/app/exchanges/exchange-messaging.d.ts +73 -0
- package/types/app/exchanges/exchange-messaging.d.ts.map +1 -0
- package/types/app/exchanges/exchanging.d.ts +379 -0
- package/types/app/exchanges/exchanging.d.ts.map +1 -0
- package/types/app/{challenging.d.ts → identity/challenging.d.ts} +3 -3
- package/types/app/identity/challenging.d.ts.map +1 -0
- package/types/app/{configing.d.ts → identity/configing.d.ts} +1 -1
- package/types/app/identity/configing.d.ts.map +1 -0
- package/types/app/{delegating.d.ts → identity/delegating.d.ts} +52 -15
- package/types/app/identity/delegating.d.ts.map +1 -0
- package/types/app/{endpoint-roleing.d.ts → identity/endpoint-roleing.d.ts} +24 -13
- package/types/app/identity/endpoint-roleing.d.ts.map +1 -0
- package/types/app/{habbing.d.ts → identity/habbing.d.ts} +73 -32
- package/types/app/identity/habbing.d.ts.map +1 -0
- package/types/app/{keeping.d.ts → identity/keeping.d.ts} +19 -5
- package/types/app/identity/keeping.d.ts.map +1 -0
- package/types/app/{organizing.d.ts → identity/organizing.d.ts} +19 -4
- package/types/app/identity/organizing.d.ts.map +1 -0
- package/types/app/ipex/ipex-building.d.ts +30 -0
- package/types/app/ipex/ipex-building.d.ts.map +1 -0
- package/types/app/{ipex-credentialing.d.ts → ipex/ipex-credentialing.d.ts} +33 -6
- package/types/app/ipex/ipex-credentialing.d.ts.map +1 -0
- package/types/app/ipex/ipex-graph.d.ts +28 -0
- package/types/app/ipex/ipex-graph.d.ts.map +1 -0
- package/types/app/ipex/ipex-grouping.d.ts +112 -0
- package/types/app/ipex/ipex-grouping.d.ts.map +1 -0
- package/types/app/{ipex-node-authentication.d.ts → ipex/ipex-node-authentication.d.ts} +10 -5
- package/types/app/ipex/ipex-node-authentication.d.ts.map +1 -0
- package/types/app/ipex/ipex-v2.d.ts +71 -0
- package/types/app/ipex/ipex-v2.d.ts.map +1 -0
- package/types/app/{ipexing.d.ts → ipex/ipexing.d.ts} +21 -6
- package/types/app/ipex/ipexing.d.ts.map +1 -0
- package/types/app/mailbox/forward-handler.d.ts +68 -0
- package/types/app/mailbox/forward-handler.d.ts.map +1 -0
- package/types/app/mailbox/mailbox-director.d.ts +252 -0
- package/types/app/mailbox/mailbox-director.d.ts.map +1 -0
- package/types/app/mailbox/mailbox-poller.d.ts +149 -0
- package/types/app/mailbox/mailbox-poller.d.ts.map +1 -0
- package/types/app/mailbox/mailbox-sse.d.ts +63 -0
- package/types/app/mailbox/mailbox-sse.d.ts.map +1 -0
- package/types/app/{mailboxing.d.ts → mailbox/mailboxing.d.ts} +92 -40
- package/types/app/mailbox/mailboxing.d.ts.map +1 -0
- package/types/app/mailbox/topic-routing.d.ts +18 -0
- package/types/app/mailbox/topic-routing.d.ts.map +1 -0
- package/types/app/multisig/group-members.d.ts +60 -0
- package/types/app/multisig/group-members.d.ts.map +1 -0
- package/types/app/{grouping.d.ts → multisig/grouping.d.ts} +142 -19
- package/types/app/multisig/grouping.d.ts.map +1 -0
- package/types/app/multisig/multisig-messaging.d.ts +97 -0
- package/types/app/multisig/multisig-messaging.d.ts.map +1 -0
- package/types/app/multisig/multisig-workflows.d.ts +85 -0
- package/types/app/multisig/multisig-workflows.d.ts.map +1 -0
- package/types/app/{notifying.d.ts → notifications/notifying.d.ts} +4 -5
- package/types/app/notifications/notifying.d.ts.map +1 -0
- package/types/app/notifications/signaling.d.ts.map +1 -0
- package/types/app/{parsering.d.ts → protocol/parsering.d.ts} +40 -11
- package/types/app/protocol/parsering.d.ts.map +1 -0
- package/types/app/{protocol-host-policy.d.ts → protocol/protocol-host-policy.d.ts} +1 -10
- package/types/app/protocol/protocol-host-policy.d.ts.map +1 -0
- package/types/app/protocol/protocol-processing.d.ts +140 -0
- package/types/app/protocol/protocol-processing.d.ts.map +1 -0
- package/types/app/protocol/reactor.d.ts +43 -0
- package/types/app/protocol/reactor.d.ts.map +1 -0
- package/types/app/queries/query-replies.d.ts +78 -0
- package/types/app/queries/query-replies.d.ts.map +1 -0
- package/types/app/queries/querying.d.ts +155 -0
- package/types/app/queries/querying.d.ts.map +1 -0
- package/types/app/queries/witness-inquisitor.d.ts +150 -0
- package/types/app/queries/witness-inquisitor.d.ts.map +1 -0
- package/types/app/runtime/abortable.d.ts +39 -0
- package/types/app/runtime/abortable.d.ts.map +1 -0
- package/types/app/runtime/agent-runtime.d.ts +348 -0
- package/types/app/runtime/agent-runtime.d.ts.map +1 -0
- package/types/app/runtime/cue-runtime.d.ts +33 -0
- package/types/app/runtime/cue-runtime.d.ts.map +1 -0
- package/types/app/runtime/runtime-clock.d.ts +28 -0
- package/types/app/runtime/runtime-clock.d.ts.map +1 -0
- package/types/app/runtime/runtime-turn.d.ts.map +1 -0
- package/types/app/transport/byte-source.d.ts +41 -0
- package/types/app/transport/byte-source.d.ts.map +1 -0
- package/types/app/transport/cesr-egress.d.ts +117 -0
- package/types/app/transport/cesr-egress.d.ts.map +1 -0
- package/types/app/{cesr-http.d.ts → transport/cesr-http.d.ts} +4 -27
- package/types/app/transport/cesr-http.d.ts.map +1 -0
- package/types/app/transport/http-client.d.ts +99 -0
- package/types/app/transport/http-client.d.ts.map +1 -0
- package/types/app/transport/http-messenger.d.ts +37 -0
- package/types/app/transport/http-messenger.d.ts.map +1 -0
- package/types/app/transport/http-stream-messenger.d.ts +30 -0
- package/types/app/transport/http-stream-messenger.d.ts.map +1 -0
- package/types/app/transport/httping.d.ts +19 -0
- package/types/app/transport/httping.d.ts.map +1 -0
- package/types/app/transport/message-source.d.ts +22 -0
- package/types/app/transport/message-source.d.ts.map +1 -0
- package/types/app/transport/messengering.d.ts +41 -0
- package/types/app/transport/messengering.d.ts.map +1 -0
- package/types/app/{socket-source.d.ts → transport/socket-source.d.ts} +8 -0
- package/types/app/transport/socket-source.d.ts.map +1 -0
- package/types/app/transport/tcp-egress.d.ts +118 -0
- package/types/app/transport/tcp-egress.d.ts.map +1 -0
- package/types/app/transport/tcp-messenger.d.ts +69 -0
- package/types/app/transport/tcp-messenger.d.ts.map +1 -0
- package/types/app/transport/tcp-stream-messenger.d.ts +25 -0
- package/types/app/transport/tcp-stream-messenger.d.ts.map +1 -0
- package/types/app/transport/transport-error.d.ts +12 -0
- package/types/app/transport/transport-error.d.ts.map +1 -0
- package/types/app/witness/http-endpoints.d.ts +77 -0
- package/types/app/witness/http-endpoints.d.ts.map +1 -0
- package/types/app/witness/ingress.d.ts +65 -0
- package/types/app/witness/ingress.d.ts.map +1 -0
- package/types/app/witness/receipt-client.d.ts +82 -0
- package/types/app/witness/receipt-client.d.ts.map +1 -0
- package/types/app/witness/receipt-messages.d.ts +21 -0
- package/types/app/witness/receipt-messages.d.ts.map +1 -0
- package/types/app/witness/receipting.d.ts +117 -0
- package/types/app/witness/receipting.d.ts.map +1 -0
- package/types/app/witness/registration.d.ts +27 -0
- package/types/app/witness/registration.d.ts.map +1 -0
- package/types/cli/common/bootstrap.d.ts +5 -0
- package/types/cli/common/bootstrap.d.ts.map +1 -0
- package/types/{app/cli → cli}/common/context.d.ts +10 -5
- package/types/cli/common/context.d.ts.map +1 -0
- package/types/{app/cli → cli}/common/existing.d.ts +2 -4
- package/types/cli/common/existing.d.ts.map +1 -0
- package/types/{app/cli → cli}/common/parsing.d.ts +26 -15
- package/types/cli/common/parsing.d.ts.map +1 -0
- package/types/cli/common/passcode.d.ts +9 -0
- package/types/cli/common/passcode.d.ts.map +1 -0
- package/types/cli/common/rendering.d.ts.map +1 -0
- package/types/cli/common/tel-completion.d.ts +8 -0
- package/types/cli/common/tel-completion.d.ts.map +1 -0
- package/types/{app/cli → cli}/common/witness-auth.d.ts +1 -1
- package/types/cli/common/witness-auth.d.ts.map +1 -0
- package/types/cli/credentials/ipex.d.ts +110 -0
- package/types/cli/credentials/ipex.d.ts.map +1 -0
- package/types/cli/credentials/vc.d.ts +42 -0
- package/types/cli/credentials/vc.d.ts.map +1 -0
- package/types/{app/cli → cli/endpoints}/did.d.ts +5 -1
- package/types/cli/endpoints/did.d.ts.map +1 -0
- package/types/{app/cli → cli/endpoints}/ends.d.ts +9 -1
- package/types/cli/endpoints/ends.d.ts.map +1 -0
- package/types/cli/endpoints/loc.d.ts.map +1 -0
- package/types/cli/endpoints/oobi-clean.d.ts +8 -0
- package/types/cli/endpoints/oobi-clean.d.ts.map +1 -0
- package/types/{app/cli → cli/endpoints}/oobi.d.ts +2 -0
- package/types/cli/endpoints/oobi.d.ts.map +1 -0
- package/types/cli/identity/aid.d.ts.map +1 -0
- package/types/{app/cli → cli/identity}/challenge.d.ts +5 -1
- package/types/cli/identity/challenge.d.ts.map +1 -0
- package/types/cli/identity/delegate.d.ts.map +1 -0
- package/types/cli/identity/export.d.ts.map +1 -0
- package/types/{app/cli → cli/identity}/incept.d.ts +2 -0
- package/types/cli/identity/incept.d.ts.map +1 -0
- package/types/{app/cli → cli/identity}/init.d.ts +2 -0
- package/types/cli/identity/init.d.ts.map +1 -0
- package/types/{app/cli → cli/identity}/interact.d.ts +2 -0
- package/types/cli/identity/interact.d.ts.map +1 -0
- package/types/cli/identity/list.d.ts.map +1 -0
- package/types/{app/cli → cli/identity}/rotate.d.ts +9 -2
- package/types/cli/identity/rotate.d.ts.map +1 -0
- package/types/cli/index.d.ts +39 -0
- package/types/cli/index.d.ts.map +1 -0
- package/types/{app/cli → cli/messaging}/exchange.d.ts +3 -1
- package/types/cli/messaging/exchange.d.ts.map +1 -0
- package/types/cli/messaging/multisig.d.ts +29 -0
- package/types/cli/messaging/multisig.d.ts.map +1 -0
- package/types/cli/messaging/notifications.d.ts.map +1 -0
- package/types/cli/output.d.ts.map +1 -0
- package/types/cli/tools/annotate-color.d.ts.map +1 -0
- package/types/cli/tools/annotate.d.ts.map +1 -0
- package/types/cli/tools/benchmark.d.ts.map +1 -0
- package/types/cli/tools/db-dump.d.ts.map +1 -0
- package/types/cli/tools/saidify.d.ts.map +1 -0
- package/types/{app/cli → cli/tools}/sign.d.ts +2 -0
- package/types/cli/tools/sign.d.ts.map +1 -0
- package/types/cli/tools/verify.d.ts.map +1 -0
- package/types/core/attachment-countering.d.ts +10 -1
- package/types/core/attachment-countering.d.ts.map +1 -1
- package/types/core/cues.d.ts +78 -21
- package/types/core/cues.d.ts.map +1 -1
- package/types/core/{exchange-proofing.d.ts → exchange/exchange-proofing.d.ts} +9 -2
- package/types/core/exchange/exchange-proofing.d.ts.map +1 -0
- package/types/core/{protocol-exchanging.d.ts → exchange/protocol-exchanging.d.ts} +10 -2
- package/types/core/exchange/protocol-exchanging.d.ts.map +1 -0
- package/types/core/genus-framing.d.ts +12 -0
- package/types/core/genus-framing.d.ts.map +1 -0
- package/types/core/{eventing.d.ts → kel/eventing.d.ts} +22 -10
- package/types/core/kel/eventing.d.ts.map +1 -0
- package/types/core/{kever-decisions.d.ts → kel/kever-decisions.d.ts} +21 -8
- package/types/core/kel/kever-decisions.d.ts.map +1 -0
- package/types/core/{kever.d.ts → kel/kever.d.ts} +2 -2
- package/types/core/kel/kever.d.ts.map +1 -0
- package/types/core/kel/witnesses.d.ts.map +1 -0
- package/types/core/logger.d.ts +1 -1
- package/types/core/logger.d.ts.map +1 -1
- package/types/core/{kram-auth.d.ts → mailbox/kram-auth.d.ts} +2 -2
- package/types/core/mailbox/kram-auth.d.ts.map +1 -0
- package/types/core/{kram-policy.d.ts → mailbox/kram-policy.d.ts} +2 -2
- package/types/core/mailbox/kram-policy.d.ts.map +1 -0
- package/types/core/{kram-pruning.d.ts → mailbox/kram-pruning.d.ts} +1 -1
- package/types/core/mailbox/kram-pruning.d.ts.map +1 -0
- package/types/core/{kram-signatures.d.ts → mailbox/kram-signatures.d.ts} +3 -3
- package/types/core/mailbox/kram-signatures.d.ts.map +1 -0
- package/types/core/{kram-staging.d.ts → mailbox/kram-staging.d.ts} +2 -2
- package/types/core/mailbox/kram-staging.d.ts.map +1 -0
- package/types/core/{kram-time.d.ts → mailbox/kram-time.d.ts} +2 -2
- package/types/core/mailbox/kram-time.d.ts.map +1 -0
- package/types/core/{kraming.d.ts → mailbox/kraming.d.ts} +5 -5
- package/types/core/mailbox/kraming.d.ts.map +1 -0
- package/types/core/mailbox/mailbox-topics.d.ts.map +1 -0
- package/types/core/protocol-eventing.d.ts.map +1 -1
- package/types/core/protocol-serialization.d.ts +1 -1
- package/types/core/protocol-serialization.d.ts.map +1 -1
- package/types/core/records.d.ts +1 -1
- package/types/core/records.d.ts.map +1 -1
- package/types/core/routing.d.ts +24 -4
- package/types/core/routing.d.ts.map +1 -1
- package/types/db/baser-defaults.d.ts +5 -0
- package/types/db/baser-defaults.d.ts.map +1 -0
- package/types/db/basing.d.ts +32 -44
- package/types/db/basing.d.ts.map +1 -1
- package/types/db/core/lmdber.d.ts +18 -13
- package/types/db/core/lmdber.d.ts.map +1 -1
- package/types/db/escrowing.d.ts +3 -1
- package/types/db/escrowing.d.ts.map +1 -1
- package/types/db/exchange/exchange-nests.d.ts +12 -0
- package/types/db/exchange/exchange-nests.d.ts.map +1 -0
- package/types/db/exchange/exchange-records.d.ts +38 -0
- package/types/db/exchange/exchange-records.d.ts.map +1 -0
- package/types/db/index.d.ts +5 -4
- package/types/db/index.d.ts.map +1 -1
- package/types/db/keeping.d.ts +19 -1
- package/types/db/keeping.d.ts.map +1 -1
- package/types/db/{kram-factors.d.ts → mailbox/kram-factors.d.ts} +2 -2
- package/types/db/mailbox/kram-factors.d.ts.map +1 -0
- package/types/db/{mailboxing.d.ts → mailbox/mailboxing.d.ts} +2 -2
- package/types/db/mailbox/mailboxing.d.ts.map +1 -0
- package/types/db/reger.d.ts +7 -6
- package/types/db/reger.d.ts.map +1 -1
- package/types/db/{kel-replay.d.ts → replay/kel-replay.d.ts} +1 -2
- package/types/db/replay/kel-replay.d.ts.map +1 -0
- package/types/db/{tel-replay.d.ts → replay/tel-replay.d.ts} +11 -1
- package/types/db/replay/tel-replay.d.ts.map +1 -0
- package/types/db/{witness-replay.d.ts → replay/witness-replay.d.ts} +1 -1
- package/types/db/replay/witness-replay.d.ts.map +1 -0
- package/types/db/subing.d.ts.map +1 -1
- package/types/did/keri/resolving.d.ts +1 -1
- package/types/did/keri/resolving.d.ts.map +1 -1
- package/types/did/webs/artifacts.d.ts +5 -5
- package/types/did/webs/artifacts.d.ts.map +1 -1
- package/types/did/webs/designated-aliases.d.ts +1 -2
- package/types/did/webs/designated-aliases.d.ts.map +1 -1
- package/types/did/webs/documenting.d.ts +1 -1
- package/types/did/webs/documenting.d.ts.map +1 -1
- package/types/did/webs/resolving.d.ts +13 -9
- package/types/did/webs/resolving.d.ts.map +1 -1
- package/types/library/index.d.ts +1 -1
- package/types/library/index.d.ts.map +1 -1
- package/types/npm/cli.d.ts +1 -1
- package/types/npm/cli.d.ts.map +1 -1
- package/types/npm/index.d.ts +1 -1
- package/types/npm/index.d.ts.map +1 -1
- package/types/runtime/index.d.ts +86 -51
- package/types/runtime/index.d.ts.map +1 -1
- package/types/vdr/backer-state.d.ts +22 -0
- package/types/vdr/backer-state.d.ts.map +1 -0
- package/types/vdr/credential-tsn-record.d.ts +13 -0
- package/types/vdr/credential-tsn-record.d.ts.map +1 -0
- package/types/vdr/credentialing.d.ts +16 -17
- package/types/vdr/credentialing.d.ts.map +1 -1
- package/types/vdr/eventing.d.ts +60 -18
- package/types/vdr/eventing.d.ts.map +1 -1
- package/types/vdr/registry-tsn-record.d.ts +6 -0
- package/types/vdr/registry-tsn-record.d.ts.map +1 -0
- package/types/vdr/revoking.d.ts +18 -0
- package/types/vdr/revoking.d.ts.map +1 -0
- package/types/vdr/tel-anchor.d.ts +10 -0
- package/types/vdr/tel-anchor.d.ts.map +1 -0
- package/types/vdr/tel-publication.d.ts +49 -0
- package/types/vdr/tel-publication.d.ts.map +1 -0
- package/types/vdr/tsn-query.d.ts +1 -1
- package/types/vdr/tsn-query.d.ts.map +1 -1
- package/types/{app/version.d.ts → version.d.ts} +2 -2
- package/types/version.d.ts.map +1 -0
- package/esm/keri/npm/src/app/agent-runtime.js +0 -544
- package/esm/keri/npm/src/app/cesr-egress.js +0 -294
- package/esm/keri/npm/src/app/cli/common/displaying.js +0 -43
- package/esm/keri/npm/src/app/cli/common/parsing.js +0 -215
- package/esm/keri/npm/src/app/cli/incept.js +0 -185
- package/esm/keri/npm/src/app/cli/index.js +0 -36
- package/esm/keri/npm/src/app/cli/init.js +0 -149
- package/esm/keri/npm/src/app/cli/interact.js +0 -72
- package/esm/keri/npm/src/app/cli/ipex.js +0 -519
- package/esm/keri/npm/src/app/cli/query.js +0 -142
- package/esm/keri/npm/src/app/cli/vc.js +0 -283
- package/esm/keri/npm/src/app/cli/verifier.js +0 -92
- package/esm/keri/npm/src/app/credential-workflows.js +0 -409
- package/esm/keri/npm/src/app/cue-runtime.js +0 -38
- package/esm/keri/npm/src/app/essr.js +0 -170
- package/esm/keri/npm/src/app/exchanging.js +0 -1001
- package/esm/keri/npm/src/app/forwarding.js +0 -936
- package/esm/keri/npm/src/app/group-members.js +0 -37
- package/esm/keri/npm/src/app/httping.js +0 -162
- package/esm/keri/npm/src/app/ipex-graph.js +0 -407
- package/esm/keri/npm/src/app/ipex-grouping.js +0 -276
- package/esm/keri/npm/src/app/ipex-v2.js +0 -438
- package/esm/keri/npm/src/app/mailbox-sse.js +0 -240
- package/esm/keri/npm/src/app/multisig-workflows.js +0 -457
- package/esm/keri/npm/src/app/querying.js +0 -775
- package/esm/keri/npm/src/app/reactor.js +0 -394
- package/esm/keri/npm/src/app/respondant.js +0 -358
- package/esm/keri/npm/src/app/runtime-services.js +0 -22
- package/esm/keri/npm/src/app/tcp-conversation.js +0 -85
- package/esm/keri/npm/src/app/tcp-egress.js +0 -251
- package/esm/keri/npm/src/app/verifier-agent.js +0 -443
- package/esm/keri/npm/src/app/witnessing.js +0 -914
- package/esm/keri/npm/src/core/index.js +0 -23
- package/esm/keri/npm/src/db/exchange-nests.js +0 -80
- package/esm/keri/npm/src/db/exchange-records.js +0 -7
- package/esm/keri/npm/src/db/payload-archive.js +0 -402
- package/esm/keri/npm/src/db/payload-store.js +0 -406
- package/esm/keri/npm/src/db/payload-view.js +0 -23
- package/esm/keri/npm/src/db/verifier-cueing.js +0 -132
- package/esm/keri/npm/src/vdr/credential-tsn.js +0 -230
- package/esm/keri/npm/src/vdr/registry-tsn.js +0 -217
- package/types/app/abortable.d.ts +0 -13
- package/types/app/abortable.d.ts.map +0 -1
- package/types/app/agent-runtime.d.ts +0 -221
- package/types/app/agent-runtime.d.ts.map +0 -1
- package/types/app/authenticating.d.ts +0 -36
- package/types/app/authenticating.d.ts.map +0 -1
- package/types/app/byte-source.d.ts +0 -16
- package/types/app/byte-source.d.ts.map +0 -1
- package/types/app/cesr-egress.d.ts +0 -45
- package/types/app/cesr-egress.d.ts.map +0 -1
- package/types/app/cesr-http.d.ts.map +0 -1
- package/types/app/challenging.d.ts.map +0 -1
- package/types/app/cli/aid.d.ts.map +0 -1
- package/types/app/cli/annotate-color.d.ts.map +0 -1
- package/types/app/cli/annotate.d.ts.map +0 -1
- package/types/app/cli/benchmark.d.ts.map +0 -1
- package/types/app/cli/challenge.d.ts.map +0 -1
- package/types/app/cli/common/context.d.ts.map +0 -1
- package/types/app/cli/common/displaying.d.ts +0 -12
- package/types/app/cli/common/displaying.d.ts.map +0 -1
- package/types/app/cli/common/existing.d.ts.map +0 -1
- package/types/app/cli/common/parsing.d.ts.map +0 -1
- package/types/app/cli/common/rendering.d.ts.map +0 -1
- package/types/app/cli/common/witness-auth.d.ts.map +0 -1
- package/types/app/cli/db-dump.d.ts.map +0 -1
- package/types/app/cli/delegate.d.ts.map +0 -1
- package/types/app/cli/did.d.ts.map +0 -1
- package/types/app/cli/ends.d.ts.map +0 -1
- package/types/app/cli/exchange.d.ts.map +0 -1
- package/types/app/cli/export.d.ts.map +0 -1
- package/types/app/cli/incept.d.ts.map +0 -1
- package/types/app/cli/index.d.ts +0 -37
- package/types/app/cli/index.d.ts.map +0 -1
- package/types/app/cli/init.d.ts.map +0 -1
- package/types/app/cli/interact.d.ts.map +0 -1
- package/types/app/cli/ipex.d.ts +0 -20
- package/types/app/cli/ipex.d.ts.map +0 -1
- package/types/app/cli/list.d.ts.map +0 -1
- package/types/app/cli/loc.d.ts.map +0 -1
- package/types/app/cli/multisig.d.ts +0 -12
- package/types/app/cli/multisig.d.ts.map +0 -1
- package/types/app/cli/notifications.d.ts.map +0 -1
- package/types/app/cli/oobi.d.ts.map +0 -1
- package/types/app/cli/output.d.ts.map +0 -1
- package/types/app/cli/query.d.ts +0 -12
- package/types/app/cli/query.d.ts.map +0 -1
- package/types/app/cli/rotate.d.ts.map +0 -1
- package/types/app/cli/saidify.d.ts.map +0 -1
- package/types/app/cli/sign.d.ts.map +0 -1
- package/types/app/cli/vc.d.ts +0 -20
- package/types/app/cli/vc.d.ts.map +0 -1
- package/types/app/cli/verifier.d.ts +0 -3
- package/types/app/cli/verifier.d.ts.map +0 -1
- package/types/app/cli/verify.d.ts.map +0 -1
- package/types/app/configing.d.ts.map +0 -1
- package/types/app/credential-workflows.d.ts +0 -113
- package/types/app/credential-workflows.d.ts.map +0 -1
- package/types/app/cue-runtime.d.ts +0 -12
- package/types/app/cue-runtime.d.ts.map +0 -1
- package/types/app/delegating.d.ts.map +0 -1
- package/types/app/endpoint-roleing.d.ts.map +0 -1
- package/types/app/essr.d.ts +0 -58
- package/types/app/essr.d.ts.map +0 -1
- package/types/app/exchanging.d.ts +0 -233
- package/types/app/exchanging.d.ts.map +0 -1
- package/types/app/forwarding.d.ts +0 -352
- package/types/app/forwarding.d.ts.map +0 -1
- package/types/app/group-members.d.ts +0 -12
- package/types/app/group-members.d.ts.map +0 -1
- package/types/app/grouping.d.ts.map +0 -1
- package/types/app/habbing.d.ts.map +0 -1
- package/types/app/httping.d.ts +0 -49
- package/types/app/httping.d.ts.map +0 -1
- package/types/app/ipex-credentialing.d.ts.map +0 -1
- package/types/app/ipex-graph.d.ts +0 -49
- package/types/app/ipex-graph.d.ts.map +0 -1
- package/types/app/ipex-grouping.d.ts +0 -43
- package/types/app/ipex-grouping.d.ts.map +0 -1
- package/types/app/ipex-node-authentication.d.ts.map +0 -1
- package/types/app/ipex-v2.d.ts +0 -46
- package/types/app/ipex-v2.d.ts.map +0 -1
- package/types/app/ipexing.d.ts.map +0 -1
- package/types/app/keeping.d.ts.map +0 -1
- package/types/app/mailbox-director.d.ts +0 -140
- package/types/app/mailbox-director.d.ts.map +0 -1
- package/types/app/mailbox-sse.d.ts +0 -32
- package/types/app/mailbox-sse.d.ts.map +0 -1
- package/types/app/mailboxing.d.ts.map +0 -1
- package/types/app/multisig-workflows.d.ts +0 -47
- package/types/app/multisig-workflows.d.ts.map +0 -1
- package/types/app/notifying.d.ts.map +0 -1
- package/types/app/oobi-replies.d.ts.map +0 -1
- package/types/app/oobiery.d.ts.map +0 -1
- package/types/app/organizing.d.ts.map +0 -1
- package/types/app/parsering.d.ts.map +0 -1
- package/types/app/protocol-host-policy.d.ts.map +0 -1
- package/types/app/query-replies.d.ts +0 -40
- package/types/app/query-replies.d.ts.map +0 -1
- package/types/app/querying.d.ts +0 -221
- package/types/app/querying.d.ts.map +0 -1
- package/types/app/reactor.d.ts +0 -138
- package/types/app/reactor.d.ts.map +0 -1
- package/types/app/reply-streams.d.ts +0 -20
- package/types/app/reply-streams.d.ts.map +0 -1
- package/types/app/respondant.d.ts +0 -63
- package/types/app/respondant.d.ts.map +0 -1
- package/types/app/runtime-services.d.ts +0 -26
- package/types/app/runtime-services.d.ts.map +0 -1
- package/types/app/runtime-turn.d.ts.map +0 -1
- package/types/app/schema-resolving.d.ts.map +0 -1
- package/types/app/signaling.d.ts.map +0 -1
- package/types/app/socket-source.d.ts.map +0 -1
- package/types/app/stored-replies.d.ts.map +0 -1
- package/types/app/tcp-conversation.d.ts +0 -27
- package/types/app/tcp-conversation.d.ts.map +0 -1
- package/types/app/tcp-egress.d.ts +0 -49
- package/types/app/tcp-egress.d.ts.map +0 -1
- package/types/app/verifier-agent.d.ts +0 -92
- package/types/app/verifier-agent.d.ts.map +0 -1
- package/types/app/verifying.d.ts.map +0 -1
- package/types/app/version.d.ts.map +0 -1
- package/types/app/witnessing.d.ts +0 -223
- package/types/app/witnessing.d.ts.map +0 -1
- package/types/core/eventing.d.ts.map +0 -1
- package/types/core/exchange-proofing.d.ts.map +0 -1
- package/types/core/index.d.ts +0 -24
- package/types/core/index.d.ts.map +0 -1
- package/types/core/kever-decisions.d.ts.map +0 -1
- package/types/core/kever.d.ts.map +0 -1
- package/types/core/kram-auth.d.ts.map +0 -1
- package/types/core/kram-policy.d.ts.map +0 -1
- package/types/core/kram-pruning.d.ts.map +0 -1
- package/types/core/kram-signatures.d.ts.map +0 -1
- package/types/core/kram-staging.d.ts.map +0 -1
- package/types/core/kram-time.d.ts.map +0 -1
- package/types/core/kraming.d.ts.map +0 -1
- package/types/core/mailbox-topics.d.ts.map +0 -1
- package/types/core/protocol-exchanging.d.ts.map +0 -1
- package/types/core/witnesses.d.ts.map +0 -1
- package/types/db/exchange-nests.d.ts +0 -15
- package/types/db/exchange-nests.d.ts.map +0 -1
- package/types/db/exchange-records.d.ts +0 -33
- package/types/db/exchange-records.d.ts.map +0 -1
- package/types/db/kel-replay.d.ts.map +0 -1
- package/types/db/kram-factors.d.ts.map +0 -1
- package/types/db/mailboxing.d.ts.map +0 -1
- package/types/db/payload-archive.d.ts +0 -70
- package/types/db/payload-archive.d.ts.map +0 -1
- package/types/db/payload-store.d.ts +0 -40
- package/types/db/payload-store.d.ts.map +0 -1
- package/types/db/payload-view.d.ts +0 -4
- package/types/db/payload-view.d.ts.map +0 -1
- package/types/db/tel-replay.d.ts.map +0 -1
- package/types/db/verifier-cueing.d.ts +0 -46
- package/types/db/verifier-cueing.d.ts.map +0 -1
- package/types/db/witness-replay.d.ts.map +0 -1
- package/types/vdr/credential-tsn.d.ts +0 -23
- package/types/vdr/credential-tsn.d.ts.map +0 -1
- package/types/vdr/registry-tsn.d.ts +0 -28
- package/types/vdr/registry-tsn.d.ts.map +0 -1
- /package/esm/keri/npm/src/app/{schema-resolving.js → credentials/schema-resolving.js} +0 -0
- /package/esm/keri/npm/src/app/{challenging.js → identity/challenging.js} +0 -0
- /package/esm/keri/npm/src/app/{protocol-host-policy.js → protocol/protocol-host-policy.js} +0 -0
- /package/esm/keri/npm/src/app/{runtime-turn.js → runtime/runtime-turn.js} +0 -0
- /package/esm/keri/npm/src/{app/cli → cli}/common/rendering.js +0 -0
- /package/esm/keri/npm/src/{app/cli → cli/tools}/annotate-color.js +0 -0
- /package/esm/keri/npm/src/core/{witnesses.js → kel/witnesses.js} +0 -0
- /package/esm/keri/npm/src/core/{kram-auth.js → mailbox/kram-auth.js} +0 -0
- /package/esm/keri/npm/src/core/{mailbox-topics.js → mailbox/mailbox-topics.js} +0 -0
- /package/types/app/{signaling.d.ts → notifications/signaling.d.ts} +0 -0
- /package/types/app/{runtime-turn.d.ts → runtime/runtime-turn.d.ts} +0 -0
- /package/types/{app/cli → cli}/common/rendering.d.ts +0 -0
- /package/types/{app/cli → cli/endpoints}/loc.d.ts +0 -0
- /package/types/{app/cli → cli/identity}/aid.d.ts +0 -0
- /package/types/{app/cli → cli/identity}/delegate.d.ts +0 -0
- /package/types/{app/cli → cli/identity}/export.d.ts +0 -0
- /package/types/{app/cli → cli/identity}/list.d.ts +0 -0
- /package/types/{app/cli → cli/messaging}/notifications.d.ts +0 -0
- /package/types/{app/cli → cli}/output.d.ts +0 -0
- /package/types/{app/cli → cli/tools}/annotate-color.d.ts +0 -0
- /package/types/{app/cli → cli/tools}/annotate.d.ts +0 -0
- /package/types/{app/cli → cli/tools}/benchmark.d.ts +0 -0
- /package/types/{app/cli → cli/tools}/db-dump.d.ts +0 -0
- /package/types/{app/cli → cli/tools}/saidify.d.ts +0 -0
- /package/types/{app/cli → cli/tools}/verify.d.ts +0 -0
- /package/types/core/{witnesses.d.ts → kel/witnesses.d.ts} +0 -0
- /package/types/core/{mailbox-topics.d.ts → mailbox/mailbox-topics.d.ts} +0 -0
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
*/
|
|
4
4
|
import * as dntShim from "../../_dnt.shims.js";
|
|
5
5
|
import { b, bytesEqual, bytesHex, t, toBytes } from "cesr-ts";
|
|
6
|
-
import {
|
|
6
|
+
import { call, ensure } from "effection";
|
|
7
7
|
import { open } from "lmdb";
|
|
8
8
|
import { startsWith } from "../../core/bytes.js";
|
|
9
9
|
import { DatabaseKeyError, DatabaseNotOpenError, DatabaseOperationError } from "../../core/errors.js";
|
|
@@ -209,6 +209,10 @@ const DEFAULT_DB_VERSION = "1.0.0";
|
|
|
209
209
|
* `PathManager` lifecycle instead of inheriting KERIpy's exact structure
|
|
210
210
|
*/
|
|
211
211
|
export class LMDBer {
|
|
212
|
+
/** Expose only a usable environment, never one whose shutdown has started or failed. */
|
|
213
|
+
get env() {
|
|
214
|
+
return this.closing ? null : this.root;
|
|
215
|
+
}
|
|
212
216
|
constructor(options = {}, defaults) {
|
|
213
217
|
Object.defineProperty(this, "pathManager", {
|
|
214
218
|
enumerable: true,
|
|
@@ -216,12 +220,19 @@ export class LMDBer {
|
|
|
216
220
|
writable: true,
|
|
217
221
|
value: void 0
|
|
218
222
|
});
|
|
219
|
-
Object.defineProperty(this, "
|
|
223
|
+
Object.defineProperty(this, "root", {
|
|
220
224
|
enumerable: true,
|
|
221
225
|
configurable: true,
|
|
222
226
|
writable: true,
|
|
223
227
|
value: void 0
|
|
224
228
|
});
|
|
229
|
+
/** A rejected close remains authoritative: the binding may have disabled only part of the handle. */
|
|
230
|
+
Object.defineProperty(this, "closing", {
|
|
231
|
+
enumerable: true,
|
|
232
|
+
configurable: true,
|
|
233
|
+
writable: true,
|
|
234
|
+
value: null
|
|
235
|
+
});
|
|
225
236
|
Object.defineProperty(this, "readonly", {
|
|
226
237
|
enumerable: true,
|
|
227
238
|
configurable: true,
|
|
@@ -247,6 +258,13 @@ export class LMDBer {
|
|
|
247
258
|
writable: true,
|
|
248
259
|
value: void 0
|
|
249
260
|
});
|
|
261
|
+
/** Existing-store maintenance may neither create tables nor clear its target. */
|
|
262
|
+
Object.defineProperty(this, "existingOnly", {
|
|
263
|
+
enumerable: true,
|
|
264
|
+
configurable: true,
|
|
265
|
+
writable: true,
|
|
266
|
+
value: false
|
|
267
|
+
});
|
|
250
268
|
this.defaults = { ...LMDBER_DEFAULTS, ...defaults };
|
|
251
269
|
this.logger = options.logger ?? consoleLogger;
|
|
252
270
|
this.configuredMapSize = options.mapSize;
|
|
@@ -264,7 +282,7 @@ export class LMDBer {
|
|
|
264
282
|
perm: this.defaults.perm,
|
|
265
283
|
};
|
|
266
284
|
this.pathManager = new PathManager(options, pathDefaults);
|
|
267
|
-
this.
|
|
285
|
+
this.root = null;
|
|
268
286
|
this.readonly = options.readonly || false;
|
|
269
287
|
}
|
|
270
288
|
/** Expose the resolved logical database name used for path derivation and temp dirs. */
|
|
@@ -307,23 +325,32 @@ export class LMDBer {
|
|
|
307
325
|
const message = error instanceof Error ? error.message : String(error);
|
|
308
326
|
return new DatabaseKeyError(`Key is empty, too big, or wrong size: ${message}`, { cause: error });
|
|
309
327
|
}
|
|
310
|
-
/**
|
|
311
|
-
*closeEnv(
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
328
|
+
/** Join native shutdown even when the caller is cancelled; failed handles cannot be reused. */
|
|
329
|
+
*closeEnv() {
|
|
330
|
+
if (!this.closing && this.root) {
|
|
331
|
+
const root = this.root;
|
|
332
|
+
// lmdb-js disables reads/writes before completion. A rejection cannot prove
|
|
333
|
+
// whether the environment is usable or fully closed; retain it as failed.
|
|
334
|
+
this.closing = new Promise((resolve, reject) => {
|
|
335
|
+
// In 3.5.3 the callback runs after doClose, including outstanding reads.
|
|
336
|
+
// The returned Promise alone can resolve before that deferred branch.
|
|
337
|
+
const native = root;
|
|
338
|
+
native.close(resolve).catch(reject);
|
|
339
|
+
}).then(() => {
|
|
340
|
+
this.root = null;
|
|
341
|
+
this.pathManager.opened = false;
|
|
342
|
+
});
|
|
343
|
+
}
|
|
344
|
+
const pending = this.closing;
|
|
345
|
+
if (pending) {
|
|
346
|
+
yield* call(function* () {
|
|
347
|
+
// Register joining before the async leaf. Effection reports a failing
|
|
348
|
+
// ensure as destruction failure, including when its task is halted.
|
|
349
|
+
yield* ensure(() => call(() => pending));
|
|
350
|
+
yield* call(() => pending);
|
|
351
|
+
});
|
|
352
|
+
this.closing = null;
|
|
353
|
+
}
|
|
327
354
|
}
|
|
328
355
|
/**
|
|
329
356
|
* Reopen the LMDB environment at the resolved path.
|
|
@@ -333,19 +360,9 @@ export class LMDBer {
|
|
|
333
360
|
* and stamps the default version marker on newly-created writable envs.
|
|
334
361
|
*/
|
|
335
362
|
*reopen(options = {}) {
|
|
363
|
+
yield* this.closeEnv();
|
|
336
364
|
const readonly = options.readonly ?? this.readonly;
|
|
337
365
|
this.readonly = readonly;
|
|
338
|
-
// Close existing database if open (prevents double-free when reopening)
|
|
339
|
-
if (this.env) {
|
|
340
|
-
try {
|
|
341
|
-
yield* this.closeEnv(this.env);
|
|
342
|
-
}
|
|
343
|
-
catch (error) {
|
|
344
|
-
// Ignore close errors (database might already be closed)
|
|
345
|
-
this.logger.warn(`Warning: Error closing existing LMDB environment: ${error}`);
|
|
346
|
-
}
|
|
347
|
-
this.env = null;
|
|
348
|
-
}
|
|
349
366
|
// Reopen path manager (now an Effection operation)
|
|
350
367
|
yield* this.pathManager.reopen(options);
|
|
351
368
|
if (!this.pathManager.path) {
|
|
@@ -358,16 +375,42 @@ export class LMDBer {
|
|
|
358
375
|
// For readonly mode, database files must exist
|
|
359
376
|
if (readonly && !dbExists) {
|
|
360
377
|
this.logger.error(`Cannot open readonly database: database files do not exist at ${dbPath}`);
|
|
361
|
-
this.
|
|
378
|
+
this.root = null;
|
|
362
379
|
return false;
|
|
363
380
|
}
|
|
364
|
-
|
|
381
|
+
if (options.mapSize !== undefined)
|
|
382
|
+
this.configuredMapSize = options.mapSize;
|
|
383
|
+
this.existingOnly = false;
|
|
384
|
+
this.openEnvironment(dbPath, dbExists);
|
|
385
|
+
// KERIpy parity: stamp version metadata on newly-created DBs and temp DBs.
|
|
386
|
+
if (this.opened && !readonly && (!dbExists || this.temp)) {
|
|
387
|
+
this.setVer(DEFAULT_DB_VERSION);
|
|
388
|
+
}
|
|
389
|
+
return this.opened;
|
|
390
|
+
}
|
|
391
|
+
/**
|
|
392
|
+
* Open a resolved existing environment without path creation or version writes.
|
|
393
|
+
* All subsequent named-table bindings refuse creation, including writable ones.
|
|
394
|
+
*/
|
|
395
|
+
*openExisting(path) {
|
|
396
|
+
if (this.root || this.closing || this.temp) {
|
|
397
|
+
throw new DatabaseOperationError("Existing-store opening requires a closed, persistent LMDBer");
|
|
398
|
+
}
|
|
399
|
+
const data = yield* this.pathManager.statFileOp(`${path}/data.mdb`);
|
|
400
|
+
if (!data.isFile) {
|
|
401
|
+
throw new DatabaseOperationError(`Existing database not found at ${path}`);
|
|
402
|
+
}
|
|
403
|
+
this.existingOnly = true;
|
|
404
|
+
this.openEnvironment(path, true);
|
|
405
|
+
this.pathManager.path = path;
|
|
406
|
+
this.pathManager.opened = true;
|
|
407
|
+
}
|
|
408
|
+
/** Open the native environment with the shared binary and map-size contract. */
|
|
409
|
+
openEnvironment(dbPath, dbExists) {
|
|
410
|
+
// Prefer the configured option, then env, then default.
|
|
365
411
|
// When data.mdb already exists, raise to at least the stored map size so
|
|
366
412
|
// KERIpy databases opened with KERI_BASER_MAP_SIZE=10GiB (etc.) do not abort
|
|
367
413
|
// under an undersized lmdb-js virtual mapping.
|
|
368
|
-
if (options.mapSize !== undefined) {
|
|
369
|
-
this.configuredMapSize = options.mapSize;
|
|
370
|
-
}
|
|
371
414
|
const dataMdbPath = dbExists ? `${dbPath}/data.mdb` : null;
|
|
372
415
|
const effectiveMapSize = resolveLmdbMapSize({
|
|
373
416
|
optionMapSize: this.configuredMapSize,
|
|
@@ -379,29 +422,25 @@ export class LMDBer {
|
|
|
379
422
|
});
|
|
380
423
|
const dbConfig = {
|
|
381
424
|
path: dbPath, // Use directory path (Node.js lmdb should handle this)
|
|
425
|
+
noSubdir: false, // A dotted directory name must not select LMDB's single-file layout.
|
|
382
426
|
maxDbs: this.defaults.maxNamedDBs,
|
|
383
427
|
mapSize: effectiveMapSize,
|
|
384
|
-
readOnly: readonly,
|
|
428
|
+
readOnly: this.readonly,
|
|
385
429
|
compression: false, // Disable compression for compatibility
|
|
386
430
|
encoding: "binary", // to mimic KERIpy behavior
|
|
387
431
|
keyEncoding: "binary", // to mimic KERIpy behavior
|
|
388
432
|
};
|
|
389
|
-
this.logger.debug(`Opening LMDB at: ${dbPath} (readonly: ${readonly}, mapSize: ${effectiveMapSize})`);
|
|
433
|
+
this.logger.debug(`Opening LMDB at: ${dbPath} (readonly: ${this.readonly}, mapSize: ${effectiveMapSize})`);
|
|
390
434
|
// Open LMDB environment
|
|
391
435
|
// LMDB's open() will create data.mdb and lock.mdb if they don't exist
|
|
392
436
|
try {
|
|
393
437
|
// do sync because wrapping synchronous native operations in action() can cause
|
|
394
438
|
// memory management issues with native bindings (double-free errors)
|
|
395
|
-
this.
|
|
439
|
+
this.root = open(dbConfig);
|
|
396
440
|
this.logger.debug(`LMDB environment opened successfully`);
|
|
397
|
-
// KERIpy parity: stamp version metadata on newly-created DBs and temp DBs.
|
|
398
|
-
if (this.opened && !readonly && (!dbExists || this.temp)) {
|
|
399
|
-
this.setVer(DEFAULT_DB_VERSION);
|
|
400
|
-
}
|
|
401
|
-
return this.opened;
|
|
402
441
|
}
|
|
403
442
|
catch (error) {
|
|
404
|
-
this.
|
|
443
|
+
this.root = null;
|
|
405
444
|
const message = error instanceof Error ? error.message : String(error);
|
|
406
445
|
throw new DatabaseOperationError(`Failed to open LMDB environment: ${message}`, { cause: error });
|
|
407
446
|
}
|
|
@@ -417,25 +456,15 @@ export class LMDBer {
|
|
|
417
456
|
return pathStat.isFile ?? false;
|
|
418
457
|
}
|
|
419
458
|
/**
|
|
420
|
-
* Close the
|
|
421
|
-
*
|
|
422
|
-
*
|
|
423
|
-
* timers before optional path cleanup, so test/resource teardown does not
|
|
424
|
-
* leak across later work.
|
|
459
|
+
* Close the environment before path cleanup. Observable binding failures
|
|
460
|
+
* propagate and permanently prevent this wrapper from reusing or deleting it.
|
|
461
|
+
* Repeated closure of a known-closed environment is harmless.
|
|
425
462
|
*/
|
|
426
463
|
*close(clear = false) {
|
|
427
|
-
if (this.
|
|
428
|
-
|
|
429
|
-
yield* this.closeEnv(this.env);
|
|
430
|
-
yield* this.quiesceEnvTimers(); // lmdb-js uses internal teardown timers to manage post-close; this lets them finish
|
|
431
|
-
}
|
|
432
|
-
catch (error) {
|
|
433
|
-
// Intentional recovery: close errors are non-fatal during shutdown paths.
|
|
434
|
-
this.logger.warn(`Error closing LMDB: ${error}`);
|
|
435
|
-
}
|
|
436
|
-
this.env = null;
|
|
464
|
+
if (clear && this.existingOnly) {
|
|
465
|
+
throw new DatabaseOperationError("Existing-store maintenance cannot clear its environment");
|
|
437
466
|
}
|
|
438
|
-
|
|
467
|
+
yield* this.closeEnv();
|
|
439
468
|
yield* this.pathManager.close(clear);
|
|
440
469
|
return true;
|
|
441
470
|
}
|
|
@@ -477,11 +506,21 @@ export class LMDBer {
|
|
|
477
506
|
*/
|
|
478
507
|
openDB(name, dupsort = false) {
|
|
479
508
|
const env = this.requireEnv();
|
|
480
|
-
|
|
509
|
+
// lmdb-js 3.5.3 supports create:false in open.js even though its public
|
|
510
|
+
// DatabaseOptions declaration omits it. Keep that native detail here.
|
|
511
|
+
const options = {
|
|
481
512
|
keyEncoding: "binary",
|
|
482
513
|
encoding: "binary", // Use binary encoding for values (raw bytes) to match KERIpy
|
|
483
514
|
dupSort: dupsort,
|
|
484
|
-
|
|
515
|
+
create: !this.existingOnly,
|
|
516
|
+
};
|
|
517
|
+
const table = env.openDB(name, options);
|
|
518
|
+
// The native API returns undefined for an absent non-creating binding,
|
|
519
|
+
// despite declaring a non-null result. Maintenance must reject it; ordinary
|
|
520
|
+
// readonly Baser bindings already tolerate tables absent from Python layouts.
|
|
521
|
+
if (this.existingOnly && !table)
|
|
522
|
+
throw new DatabaseOperationError(`Database not found: ${name}`);
|
|
523
|
+
return table;
|
|
485
524
|
}
|
|
486
525
|
/*
|
|
487
526
|
* Plain key/value family (`dupsort=false` parity surface)
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { Cigar, Dater, Diger, Prefixer, Seqner, Siger, Verfer } from "cesr-ts";
|
|
2
2
|
import { TransIdxSigGroup } from "../core/dispatch.js";
|
|
3
|
-
import { dropEscrow } from "../core/kever-decisions.js";
|
|
3
|
+
import { dropEscrow } from "../core/kel/kever-decisions.js";
|
|
4
|
+
import { consoleLogger } from "../core/logger.js";
|
|
4
5
|
import { makeNowIso8601, timestampMicros } from "../time/mod.js";
|
|
5
6
|
import { CatCesrIoSetSuber, CesrIoSetSuber, CesrSuber, SerderSuber } from "./subing.js";
|
|
6
7
|
function hexToFixedBytes(hex, size) {
|
|
@@ -137,6 +138,8 @@ export class Broker {
|
|
|
137
138
|
* propagate and leave that row eligible for retry. Kept rows and insertions behind
|
|
138
139
|
* the checkpoint return next pass; new rows beyond the horizon cannot extend it.
|
|
139
140
|
* Removing an index retains artifacts that another dependency family may own.
|
|
141
|
+
* Terminal drops are reported only after the index removal succeeds; dependency
|
|
142
|
+
* migration must return accept for the relinquished family, rather than drop.
|
|
140
143
|
*/
|
|
141
144
|
retryStateNotices(typ, processReply, { maxRows = 64, now = makeNowIso8601() } = {}) {
|
|
142
145
|
if (!/^[a-z-]+$/.test(typ) || !Number.isSafeInteger(maxRows) || maxRows < 1 || maxRows > 1024) {
|
|
@@ -147,58 +150,78 @@ export class Broker {
|
|
|
147
150
|
throw new Error("Invalid Broker retry time.");
|
|
148
151
|
const encode = (value) => new TextEncoder().encode(value);
|
|
149
152
|
const decode = (value) => new TextDecoder("utf-8", { fatal: true }).decode(value);
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
153
|
+
try {
|
|
154
|
+
let scan = this.retryScans.get(typ);
|
|
155
|
+
if (!scan) {
|
|
156
|
+
const start = encode(`${typ}.`), ceiling = encode(`${typ}/`);
|
|
157
|
+
let tail;
|
|
158
|
+
for (const key of this.escrowdb.sdb.getKeys({ start: ceiling, end: start, reverse: true, limit: 1 })) {
|
|
159
|
+
tail = key.slice();
|
|
160
|
+
}
|
|
161
|
+
if (!tail)
|
|
162
|
+
return { processed: 0, done: true };
|
|
163
|
+
scan = { start, end: encode(`${decode(tail)}\0`) };
|
|
164
|
+
this.retryScans.set(typ, scan);
|
|
156
165
|
}
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
this.retryScans.set(typ, scan);
|
|
161
|
-
}
|
|
162
|
-
const rows = [];
|
|
163
|
-
for (const key of this.escrowdb.sdb.getKeys({ start: scan.start, end: scan.end, limit: maxRows })) {
|
|
164
|
-
rows.push(key.slice());
|
|
165
|
-
}
|
|
166
|
-
for (const key of rows) {
|
|
167
|
-
const parts = decode(key).split(".");
|
|
168
|
-
if (parts.length !== 4 || parts[0] !== typ || !parts[1] || !parts[2]
|
|
169
|
-
|| parts.some((part) => part.includes("\0")) || !/^[0-9a-f]{32}$/.test(parts[3])) {
|
|
170
|
-
throw new Error("Corrupt Broker retry key.");
|
|
166
|
+
const rows = [];
|
|
167
|
+
for (const key of this.escrowdb.sdb.getKeys({ start: scan.start, end: scan.end, limit: maxRows })) {
|
|
168
|
+
rows.push(key.slice());
|
|
171
169
|
}
|
|
172
|
-
const
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
170
|
+
for (const key of rows) {
|
|
171
|
+
const parts = decode(key).split(".");
|
|
172
|
+
if (parts.length !== 4 || parts[0] !== typ || !parts[1] || !parts[2]
|
|
173
|
+
|| parts.some((part) => part.includes("\0")) || !/^[0-9a-f]{32}$/.test(parts[3])) {
|
|
174
|
+
throw new Error("Corrupt Broker retry key.");
|
|
175
|
+
}
|
|
176
|
+
const raw = this.db.getVal(this.escrowdb.sdb, key);
|
|
177
|
+
if (!raw || raw.length > 128)
|
|
178
|
+
throw new Error("Corrupt Broker retry digest row.");
|
|
179
|
+
const diger = new Diger({ qb64b: raw });
|
|
180
|
+
const dater = this.daterdb.get([diger.qb64]), serder = this.serderdb.get([diger.qb64]);
|
|
181
|
+
const tsgs = this.fetchTsgs(diger), couples = this.cigardb.get([diger.qb64]);
|
|
182
|
+
if (!dater || !serder || (!tsgs.length && !couples.length) || !serder.route) {
|
|
183
|
+
throw new Error("Corrupt Broker retry artifacts.");
|
|
184
|
+
}
|
|
185
|
+
const stamp = timestampMicros(dater.dts);
|
|
186
|
+
if (stamp === null)
|
|
187
|
+
throw new Error("Corrupt Broker retry timestamp.");
|
|
188
|
+
const decision = when - stamp > BigInt(ttl) ? dropEscrow("stale") : processReply({
|
|
189
|
+
aid: parts[2],
|
|
190
|
+
diger,
|
|
191
|
+
serder,
|
|
192
|
+
route: serder.route,
|
|
193
|
+
tsgs,
|
|
194
|
+
cigars: couples.map(([verfer, cigar]) => new Cigar(cigar, verfer)),
|
|
195
|
+
});
|
|
196
|
+
if (decision.kind === "accept" || decision.kind === "drop") {
|
|
197
|
+
const removed = this.escrowdb.rem(parts.slice(0, 3), diger);
|
|
198
|
+
if (removed && decision.kind === "drop") {
|
|
199
|
+
consoleLogger.warn("Broker ejected transaction-state notice from escrow", {
|
|
200
|
+
family: typ,
|
|
201
|
+
said: diger.qb64,
|
|
202
|
+
pre: parts[1],
|
|
203
|
+
aid: parts[2],
|
|
204
|
+
route: serder.route,
|
|
205
|
+
reason: decision.reason,
|
|
206
|
+
detail: decision.message,
|
|
207
|
+
...(decision.cause !== undefined ? { cause: decision.cause } : {}),
|
|
208
|
+
});
|
|
209
|
+
}
|
|
210
|
+
}
|
|
211
|
+
else if (decision.kind !== "keep")
|
|
212
|
+
throw new Error("Invalid Broker retry decision.");
|
|
213
|
+
scan.start = encode(`${decode(key)}\0`);
|
|
180
214
|
}
|
|
181
|
-
const
|
|
182
|
-
if (
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
aid: parts[2],
|
|
186
|
-
diger,
|
|
187
|
-
serder,
|
|
188
|
-
route: serder.route,
|
|
189
|
-
tsgs,
|
|
190
|
-
cigars: couples.map(([verfer, cigar]) => new Cigar(cigar, verfer)),
|
|
191
|
-
});
|
|
192
|
-
if (decision.kind === "accept" || decision.kind === "drop")
|
|
193
|
-
this.escrowdb.rem(parts.slice(0, 3), diger);
|
|
194
|
-
else if (decision.kind !== "keep")
|
|
195
|
-
throw new Error("Invalid Broker retry decision.");
|
|
196
|
-
scan.start = encode(`${decode(key)}\0`);
|
|
215
|
+
const done = rows.length < maxRows;
|
|
216
|
+
if (done)
|
|
217
|
+
this.retryScans.delete(typ);
|
|
218
|
+
return { processed: rows.length, done };
|
|
197
219
|
}
|
|
198
|
-
|
|
199
|
-
|
|
220
|
+
catch (error) {
|
|
221
|
+
// Restart after failure so earlier kept rows can use evidence recovered before the fault.
|
|
200
222
|
this.retryScans.delete(typ);
|
|
201
|
-
|
|
223
|
+
throw error;
|
|
224
|
+
}
|
|
202
225
|
}
|
|
203
226
|
/**
|
|
204
227
|
* Persist one escrowed transaction-state notice and its attachments.
|
|
@@ -218,7 +241,8 @@ export class Broker {
|
|
|
218
241
|
this.daterdb.put(keys, dater);
|
|
219
242
|
this.serderdb.put(keys, serder);
|
|
220
243
|
for (const group of tsgs) {
|
|
221
|
-
|
|
244
|
+
// Both Python references key equivalent ordinal encodings by the same numeric value.
|
|
245
|
+
this.tigerdb.put([diger.qb64, group.pre, group.sn.toString(16).padStart(32, "0"), group.said], group.sigers);
|
|
222
246
|
}
|
|
223
247
|
for (const cigar of cigars) {
|
|
224
248
|
if (!cigar.verfer) {
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
/** KERIpy enst. wire storage and finite nested evidence hydration. */
|
|
2
|
+
import { b, collectPayload, concatBytes, Counter, nestedPayload, parseBytes, t, Vrsn_2_0, } from "cesr-ts";
|
|
3
|
+
import { suffix, unsuffix } from "../core/keys.js";
|
|
4
|
+
/** Read one physical row and close the LMDB key cursor before any caller suspension. */
|
|
5
|
+
function nextRow(db, table, said, ordinal) {
|
|
6
|
+
for (const key of table.sdb.getKeys({ start: suffix(b(said), ordinal) })) {
|
|
7
|
+
const [owner, index] = unsuffix(key);
|
|
8
|
+
if (t(owner) !== said)
|
|
9
|
+
return null;
|
|
10
|
+
const wire = db.getVal(table.sdb, key);
|
|
11
|
+
if (!wire)
|
|
12
|
+
throw new Error("Stored nested row disappeared");
|
|
13
|
+
return { wire, next: index + 1 };
|
|
14
|
+
}
|
|
15
|
+
return null;
|
|
16
|
+
}
|
|
17
|
+
/** Test row presence without hydrating a potentially large wire value. */
|
|
18
|
+
export function hasNests(db, said, ordinal = 0) {
|
|
19
|
+
for (const key of db.enst.sdb.getKeys({ start: suffix(b(said), ordinal) }))
|
|
20
|
+
return t(unsuffix(key)[0]) === said;
|
|
21
|
+
return false;
|
|
22
|
+
}
|
|
23
|
+
/** Serialize resident children before the caller enters its synchronous evidence writer. */
|
|
24
|
+
export async function prepareNests(nests, signal) {
|
|
25
|
+
const wires = [];
|
|
26
|
+
for (const child of nests)
|
|
27
|
+
wires.push(await collectPayload(nestedPayload(child, Vrsn_2_0), signal));
|
|
28
|
+
return wires;
|
|
29
|
+
}
|
|
30
|
+
/** Publish ordinary KERIpy nested wire rows inside the caller's exchange transaction. */
|
|
31
|
+
export function publishNests(db, said, wires) {
|
|
32
|
+
if (!wires.length) {
|
|
33
|
+
db.enst.rem([said]);
|
|
34
|
+
return;
|
|
35
|
+
}
|
|
36
|
+
if (!db.enst.pin([said], wires.map((wire) => t(wire))))
|
|
37
|
+
throw new Error("Nested evidence write failed");
|
|
38
|
+
}
|
|
39
|
+
/** Hydrate each stored wrapper through the finite decoder without parser-owned files. */
|
|
40
|
+
export function loadNests(db, said) {
|
|
41
|
+
const nests = [];
|
|
42
|
+
let ordinal = 0;
|
|
43
|
+
for (;;) {
|
|
44
|
+
const row = nextRow(db, db.enst, said, ordinal);
|
|
45
|
+
if (!row)
|
|
46
|
+
break;
|
|
47
|
+
ordinal = row.next;
|
|
48
|
+
const frames = parseBytes(concatBytes(Counter.makeGVC(Vrsn_2_0), row.wire));
|
|
49
|
+
if (frames.length !== 1)
|
|
50
|
+
throw new Error("Stored nested row must contain exactly one child substream");
|
|
51
|
+
nests.push(frames[0]);
|
|
52
|
+
}
|
|
53
|
+
return nests;
|
|
54
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { RawRecord } from "../../core/records.js";
|
|
2
|
+
/** Private metadata; the ordinary KERIpy exchange tables retain their wire schema. */
|
|
3
|
+
export class ExchangeRecord extends RawRecord {
|
|
4
|
+
}
|
|
5
|
+
/** Python exrs.; keys are (Grant SAID, node SAID), never a credential-validity index. */
|
|
6
|
+
export class ExchangeRegistryStateRecord extends RawRecord {
|
|
7
|
+
}
|
|
@@ -2,15 +2,16 @@
|
|
|
2
2
|
* Database module exports
|
|
3
3
|
*/
|
|
4
4
|
export * from "../acdc/regbasing.js";
|
|
5
|
-
export { openRegistry, RegistryRecord as AcdcRegistryRecord, RegistryStore, } from "../acdc/registering.js";
|
|
5
|
+
export { openRegistry, publicOpeningAttachment, RegistryRecord as AcdcRegistryRecord, RegistryStore, } from "../acdc/registering.js";
|
|
6
6
|
export * from "./basing.js";
|
|
7
7
|
export * from "./core/index.js";
|
|
8
8
|
export * from "./escrowing.js";
|
|
9
|
+
export { loadNests } from "./exchange/exchange-nests.js";
|
|
10
|
+
export { ExchangeRegistryStateRecord } from "./exchange/exchange-records.js";
|
|
9
11
|
export * from "./keeping.js";
|
|
10
12
|
export * from "./koming.js";
|
|
11
|
-
export * from "./mailboxing.js";
|
|
13
|
+
export * from "./mailbox/mailboxing.js";
|
|
12
14
|
export * from "./noting.js";
|
|
13
|
-
export { PayloadArchive } from "./payload-archive.js";
|
|
14
|
-
export { PayloadStore } from "./payload-store.js";
|
|
15
15
|
export * from "./reger.js";
|
|
16
|
+
export { UnsupportedTelReplayError } from "./replay/tel-replay.js";
|
|
16
17
|
export * from "./subing.js";
|