@interop/wallet-core 0.52.1 → 0.54.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/clientAnnex/credentialAnchoredGenesis.d.ts +24 -10
- package/dist/clientAnnex/credentialAnchoredGenesis.d.ts.map +1 -1
- package/dist/clientAnnex/credentialAnchoredGenesis.js +42 -13
- package/dist/clientAnnex/credentialAnchoredGenesis.js.map +1 -1
- package/dist/clientAnnex/forgetLast.d.ts +18 -10
- package/dist/clientAnnex/forgetLast.d.ts.map +1 -1
- package/dist/clientAnnex/forgetLast.js +29 -9
- package/dist/clientAnnex/forgetLast.js.map +1 -1
- package/dist/clientAnnex/index.d.ts +1 -1
- package/dist/clientAnnex/index.d.ts.map +1 -1
- package/dist/clientAnnex/index.js +1 -1
- package/dist/clientAnnex/index.js.map +1 -1
- package/dist/clientAnnex/ladderAnchored.d.ts +125 -5
- package/dist/clientAnnex/ladderAnchored.d.ts.map +1 -1
- package/dist/clientAnnex/ladderAnchored.js +180 -12
- package/dist/clientAnnex/ladderAnchored.js.map +1 -1
- package/dist/clientAnnex/recoveryLadderAnchored.d.ts +11 -0
- package/dist/clientAnnex/recoveryLadderAnchored.d.ts.map +1 -1
- package/dist/clientAnnex/recoveryLadderAnchored.js +45 -5
- package/dist/clientAnnex/recoveryLadderAnchored.js.map +1 -1
- package/dist/clientAnnex/selfEnroll.d.ts +61 -2
- package/dist/clientAnnex/selfEnroll.d.ts.map +1 -1
- package/dist/clientAnnex/selfEnroll.js +72 -8
- package/dist/clientAnnex/selfEnroll.js.map +1 -1
- package/dist/clients/rosterPolicy.d.ts.map +1 -1
- package/dist/clients/rosterPolicy.js +10 -7
- package/dist/clients/rosterPolicy.js.map +1 -1
- package/dist/descriptors/logSource.d.ts +5 -2
- package/dist/descriptors/logSource.d.ts.map +1 -1
- package/dist/descriptors/logSource.js +5 -2
- package/dist/descriptors/logSource.js.map +1 -1
- package/dist/index.d.ts +7 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +6 -0
- package/dist/index.js.map +1 -1
- package/dist/keys/clientKeyRecord.d.ts +68 -1
- package/dist/keys/clientKeyRecord.d.ts.map +1 -1
- package/dist/keys/clientKeyRecord.js +155 -20
- package/dist/keys/clientKeyRecord.js.map +1 -1
- package/dist/keys/index.d.ts +2 -2
- package/dist/keys/index.d.ts.map +1 -1
- package/dist/keys/index.js +1 -1
- package/dist/keys/index.js.map +1 -1
- package/dist/keys/rosterLogStore.d.ts.map +1 -1
- package/dist/keys/rosterLogStore.js +15 -0
- package/dist/keys/rosterLogStore.js.map +1 -1
- package/dist/log.d.ts +49 -0
- package/dist/log.d.ts.map +1 -0
- package/dist/log.js +53 -0
- package/dist/log.js.map +1 -0
- package/dist/recovery/recoveryDelegation.d.ts +6 -2
- package/dist/recovery/recoveryDelegation.d.ts.map +1 -1
- package/dist/recovery/recoveryDelegation.js +31 -5
- package/dist/recovery/recoveryDelegation.js.map +1 -1
- package/dist/recovery/recoveryWebvh.d.ts +75 -6
- package/dist/recovery/recoveryWebvh.d.ts.map +1 -1
- package/dist/recovery/recoveryWebvh.js +121 -16
- package/dist/recovery/recoveryWebvh.js.map +1 -1
- package/dist/request/capabilityRequest.d.ts +9 -1
- package/dist/request/capabilityRequest.d.ts.map +1 -1
- package/dist/request/capabilityRequest.js +13 -2
- package/dist/request/capabilityRequest.js.map +1 -1
- package/dist/request/classify.d.ts +37 -1
- package/dist/request/classify.d.ts.map +1 -1
- package/dist/request/classify.js +61 -2
- package/dist/request/classify.js.map +1 -1
- package/dist/request/ephemeralExchange.d.ts +0 -18
- package/dist/request/ephemeralExchange.d.ts.map +1 -1
- package/dist/request/ephemeralExchange.js +3 -2
- package/dist/request/ephemeralExchange.js.map +1 -1
- package/dist/request/interactionUrl.d.ts.map +1 -1
- package/dist/request/interactionUrl.js +4 -2
- package/dist/request/interactionUrl.js.map +1 -1
- package/dist/request/parse.d.ts +0 -10
- package/dist/request/parse.d.ts.map +1 -1
- package/dist/request/parse.js +15 -1
- package/dist/request/parse.js.map +1 -1
- package/dist/request/processRequest.d.ts.map +1 -1
- package/dist/request/processRequest.js +2 -1
- package/dist/request/processRequest.js.map +1 -1
- package/dist/request/types.d.ts +23 -2
- package/dist/request/types.d.ts.map +1 -1
- package/dist/resourceLog/controller.d.ts.map +1 -1
- package/dist/resourceLog/controller.js +3 -2
- package/dist/resourceLog/controller.js.map +1 -1
- package/dist/resourceLog/license.d.ts +17 -3
- package/dist/resourceLog/license.d.ts.map +1 -1
- package/dist/resourceLog/license.js +24 -2
- package/dist/resourceLog/license.js.map +1 -1
- package/dist/space/activity.d.ts +48 -1
- package/dist/space/activity.d.ts.map +1 -1
- package/dist/space/activity.js +52 -4
- package/dist/space/activity.js.map +1 -1
- package/dist/space/index.d.ts +1 -1
- package/dist/space/index.d.ts.map +1 -1
- package/dist/space/index.js +1 -1
- package/dist/space/index.js.map +1 -1
- package/dist/sync/pull.d.ts +0 -22
- package/dist/sync/pull.d.ts.map +1 -1
- package/dist/sync/pull.js +30 -2
- package/dist/sync/pull.js.map +1 -1
- package/dist/unlock/index.d.ts +1 -1
- package/dist/unlock/index.d.ts.map +1 -1
- package/dist/unlock/index.js +1 -1
- package/dist/unlock/index.js.map +1 -1
- package/dist/unlock/standingWebvh.d.ts +10 -0
- package/dist/unlock/standingWebvh.d.ts.map +1 -1
- package/dist/unlock/standingWebvh.js +10 -2
- package/dist/unlock/standingWebvh.js.map +1 -1
- package/dist/unlock/unlockRecord.d.ts +37 -0
- package/dist/unlock/unlockRecord.d.ts.map +1 -1
- package/dist/unlock/unlockRecord.js +53 -0
- package/dist/unlock/unlockRecord.js.map +1 -1
- package/dist/webvh/didWebvh.d.ts +53 -2
- package/dist/webvh/didWebvh.d.ts.map +1 -1
- package/dist/webvh/didWebvh.js +72 -20
- package/dist/webvh/didWebvh.js.map +1 -1
- package/dist/webvh/index.d.ts +1 -1
- package/dist/webvh/index.d.ts.map +1 -1
- package/dist/webvh/index.js +1 -1
- package/dist/webvh/index.js.map +1 -1
- package/package.json +7 -5
|
@@ -12,19 +12,24 @@
|
|
|
12
12
|
* resolution of the orphan-Space tear): re-derivable from the unlock
|
|
13
13
|
* record's ladder seed, so a tab death here strands nothing a later
|
|
14
14
|
* login cannot finish or unwind.
|
|
15
|
-
* 2. The
|
|
15
|
+
* 2. The optional KMS key map (`provideDidWebKeys`), acquired only once the
|
|
16
|
+
* Space exists -- the durable ceremony's stage, verbatim: a KMS-keeping
|
|
17
|
+
* wallet creates the keystore under the ladder VM's bare did:key and
|
|
18
|
+
* writes keys.json and did.json into the Space here. Best-effort: a throw
|
|
19
|
+
* is collected and the genesis proceeds keystore-less; a later login's
|
|
20
|
+
* heal supplies the missing convenience key.
|
|
21
|
+
* 3. The ladder-anchored did:webvh genesis
|
|
16
22
|
* (`ensureLadderAnchoredDidWebvh`): the entry signed by ladder rung 0, `updateKeys` = [rung 0], `nextKeyHashes`
|
|
17
23
|
* = [hash(rung 0), hash(rung 1)], the ladder VM and the credential's
|
|
18
|
-
* `keyAgreement` inventory folded in,
|
|
19
|
-
*
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
* 3. The user-key roster genesis, wrapped to the CREDENTIAL's standing
|
|
24
|
+
* `keyAgreement` inventory folded in -- plus, when stage 2 delivered a key
|
|
25
|
+
* map, the KMS-held authentication VM under `authentication` only --
|
|
26
|
+
* `portable` unchanged.
|
|
27
|
+
* 4. The user-key roster genesis, wrapped to the CREDENTIAL's standing
|
|
23
28
|
* key-agreement key -- the only recipient a ladder-anchored account has
|
|
24
29
|
* -- with the entry proof signed by the ladder VM (the ceremony-tail
|
|
25
30
|
* license's first-entry shape). The account is credential-recoverable
|
|
26
31
|
* from the moment this lands.
|
|
27
|
-
*
|
|
32
|
+
* 5. Epoch[0] on every encrypted roster collection -- gated twice, unlike
|
|
28
33
|
* the durable flow. The roster stage must have landed, AND the roster's
|
|
29
34
|
* current epoch must BE the `userKey` this run was handed: the user key
|
|
30
35
|
* here exists only in this tab's memory, so installing collection epochs
|
|
@@ -39,7 +44,7 @@
|
|
|
39
44
|
* that recovers the roster's real key is the one installer. With both
|
|
40
45
|
* gates the tear heal is always clean: no roster means no epochs, and a
|
|
41
46
|
* fresh user key re-runs both.
|
|
42
|
-
*
|
|
47
|
+
* 6. Space-controller promotion, last -- every earlier stage ran under the
|
|
43
48
|
* bootstrap did:key the Space's stored controller authorizes.
|
|
44
49
|
*
|
|
45
50
|
* Idempotent end to end on the durable flow's convention; the did:webvh
|
|
@@ -49,7 +54,7 @@
|
|
|
49
54
|
import { type RecipientPublicKey } from '@interop/was-client/edv';
|
|
50
55
|
import type { WasClient } from '@interop/was-client';
|
|
51
56
|
import type { EncryptionDescriptorStore } from '@interop/was-client/edv';
|
|
52
|
-
import type { WebvhIdStore } from '../webvh/didWebvh.js';
|
|
57
|
+
import type { DidWebKeyMapV2, WebvhIdStore } from '../webvh/didWebvh.js';
|
|
53
58
|
import type { UnlockKeyAgreementPublication } from '../unlock/standingWebvh.js';
|
|
54
59
|
import { type UserKey } from '../keys/index.js';
|
|
55
60
|
import type { ResourceLogPinStore } from '@interop/vh-resource-log';
|
|
@@ -93,6 +98,14 @@ export declare function mintCredentialAnchoredAccountKeySet(): Promise<{
|
|
|
93
98
|
* @param options.rosterStoreFor {Function} `({ did }) =>
|
|
94
99
|
* EncryptionDescriptorStore` -- the user-key roster's store once the DID is
|
|
95
100
|
* known, with a LADDER-signed `ResourceLogSigner` (the first-entry shape)
|
|
101
|
+
* @param [options.provideDidWebKeys] {Function} `() =>
|
|
102
|
+
* Promise<DidWebKeyMapV2 | undefined>` -- the KMS key-map acquisition (a
|
|
103
|
+
* wallet that keeps a KMS runs its did:web provisioning here, after the
|
|
104
|
+
* Space exists, under the ladder VM's bare did:key); absent or resolving
|
|
105
|
+
* `undefined`, the genesis is ladder-and-credential-only and no `keys.json`
|
|
106
|
+
* is ever written. A throw is collected, not fatal: the genesis proceeds
|
|
107
|
+
* keystore-less and a later login heals the document with the convenience
|
|
108
|
+
* key
|
|
96
109
|
* @param [options.expectedDid] {string} the account DID, when the caller
|
|
97
110
|
* holds a pointer that already names one (a heal re-run); a fresh signup
|
|
98
111
|
* and a fresh-terminal heal legitimately hold none
|
|
@@ -105,7 +118,7 @@ export declare function mintCredentialAnchoredAccountKeySet(): Promise<{
|
|
|
105
118
|
* re-bind) passes `false` and promotes after that write
|
|
106
119
|
* @returns {Promise<AccountGenesisResult>}
|
|
107
120
|
*/
|
|
108
|
-
export declare function ensureCredentialAnchoredAccountGenesis({ was, wasServerUrl, spaceId, ladderSeed, keyAgreement, standingRecipient, userKey, idStore, rosterStoreFor, expectedDid, accountLogPinStore, onDidPublished, promoteController }: {
|
|
121
|
+
export declare function ensureCredentialAnchoredAccountGenesis({ was, wasServerUrl, spaceId, ladderSeed, keyAgreement, standingRecipient, userKey, idStore, rosterStoreFor, provideDidWebKeys, expectedDid, accountLogPinStore, onDidPublished, promoteController }: {
|
|
109
122
|
was: WasClient;
|
|
110
123
|
wasServerUrl: string;
|
|
111
124
|
spaceId: string;
|
|
@@ -117,6 +130,7 @@ export declare function ensureCredentialAnchoredAccountGenesis({ was, wasServerU
|
|
|
117
130
|
rosterStoreFor: (options: {
|
|
118
131
|
did: string;
|
|
119
132
|
}) => EncryptionDescriptorStore;
|
|
133
|
+
provideDidWebKeys?: () => Promise<DidWebKeyMapV2 | undefined>;
|
|
120
134
|
expectedDid?: string;
|
|
121
135
|
accountLogPinStore?: ResourceLogPinStore;
|
|
122
136
|
onDidPublished?: (published: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"credentialAnchoredGenesis.d.ts","sourceRoot":"","sources":["../../src/clientAnnex/credentialAnchoredGenesis.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH
|
|
1
|
+
{"version":3,"file":"credentialAnchoredGenesis.d.ts","sourceRoot":"","sources":["../../src/clientAnnex/credentialAnchoredGenesis.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;;;;;;;;;;;;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OAAO,EAAE;QAAE,GAAG,EAAE,MAAM,CAAA;KAAE,KAAK,yBAAyB,CAAA;IACvE,iBAAiB,CAAC,EAAE,MAAM,OAAO,CAAC,cAAc,GAAG,SAAS,CAAC,CAAA;IAC7D,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,kBAAkB,CAAC,EAAE,mBAAmB,CAAA;IACxC,cAAc,CAAC,EAAE,CAAC,SAAS,EAAE;QAAE,GAAG,EAAE,MAAM,CAAA;KAAE,KAAK,OAAO,CAAC,IAAI,CAAC,CAAA;IAC9D,iBAAiB,CAAC,EAAE,OAAO,CAAA;CAC5B,GAAG,OAAO,CAAC,oBAAoB,CAAC,CA0GhC"}
|
|
@@ -12,19 +12,24 @@
|
|
|
12
12
|
* resolution of the orphan-Space tear): re-derivable from the unlock
|
|
13
13
|
* record's ladder seed, so a tab death here strands nothing a later
|
|
14
14
|
* login cannot finish or unwind.
|
|
15
|
-
* 2. The
|
|
15
|
+
* 2. The optional KMS key map (`provideDidWebKeys`), acquired only once the
|
|
16
|
+
* Space exists -- the durable ceremony's stage, verbatim: a KMS-keeping
|
|
17
|
+
* wallet creates the keystore under the ladder VM's bare did:key and
|
|
18
|
+
* writes keys.json and did.json into the Space here. Best-effort: a throw
|
|
19
|
+
* is collected and the genesis proceeds keystore-less; a later login's
|
|
20
|
+
* heal supplies the missing convenience key.
|
|
21
|
+
* 3. The ladder-anchored did:webvh genesis
|
|
16
22
|
* (`ensureLadderAnchoredDidWebvh`): the entry signed by ladder rung 0, `updateKeys` = [rung 0], `nextKeyHashes`
|
|
17
23
|
* = [hash(rung 0), hash(rung 1)], the ladder VM and the credential's
|
|
18
|
-
* `keyAgreement` inventory folded in,
|
|
19
|
-
*
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
* 3. The user-key roster genesis, wrapped to the CREDENTIAL's standing
|
|
24
|
+
* `keyAgreement` inventory folded in -- plus, when stage 2 delivered a key
|
|
25
|
+
* map, the KMS-held authentication VM under `authentication` only --
|
|
26
|
+
* `portable` unchanged.
|
|
27
|
+
* 4. The user-key roster genesis, wrapped to the CREDENTIAL's standing
|
|
23
28
|
* key-agreement key -- the only recipient a ladder-anchored account has
|
|
24
29
|
* -- with the entry proof signed by the ladder VM (the ceremony-tail
|
|
25
30
|
* license's first-entry shape). The account is credential-recoverable
|
|
26
31
|
* from the moment this lands.
|
|
27
|
-
*
|
|
32
|
+
* 5. Epoch[0] on every encrypted roster collection -- gated twice, unlike
|
|
28
33
|
* the durable flow. The roster stage must have landed, AND the roster's
|
|
29
34
|
* current epoch must BE the `userKey` this run was handed: the user key
|
|
30
35
|
* here exists only in this tab's memory, so installing collection epochs
|
|
@@ -39,7 +44,7 @@
|
|
|
39
44
|
* that recovers the roster's real key is the one installer. With both
|
|
40
45
|
* gates the tear heal is always clean: no roster means no epochs, and a
|
|
41
46
|
* fresh user key re-runs both.
|
|
42
|
-
*
|
|
47
|
+
* 6. Space-controller promotion, last -- every earlier stage ran under the
|
|
43
48
|
* bootstrap did:key the Space's stored controller authorizes.
|
|
44
49
|
*
|
|
45
50
|
* Idempotent end to end on the durable flow's convention; the did:webvh
|
|
@@ -90,6 +95,14 @@ export async function mintCredentialAnchoredAccountKeySet() {
|
|
|
90
95
|
* @param options.rosterStoreFor {Function} `({ did }) =>
|
|
91
96
|
* EncryptionDescriptorStore` -- the user-key roster's store once the DID is
|
|
92
97
|
* known, with a LADDER-signed `ResourceLogSigner` (the first-entry shape)
|
|
98
|
+
* @param [options.provideDidWebKeys] {Function} `() =>
|
|
99
|
+
* Promise<DidWebKeyMapV2 | undefined>` -- the KMS key-map acquisition (a
|
|
100
|
+
* wallet that keeps a KMS runs its did:web provisioning here, after the
|
|
101
|
+
* Space exists, under the ladder VM's bare did:key); absent or resolving
|
|
102
|
+
* `undefined`, the genesis is ladder-and-credential-only and no `keys.json`
|
|
103
|
+
* is ever written. A throw is collected, not fatal: the genesis proceeds
|
|
104
|
+
* keystore-less and a later login heals the document with the convenience
|
|
105
|
+
* key
|
|
93
106
|
* @param [options.expectedDid] {string} the account DID, when the caller
|
|
94
107
|
* holds a pointer that already names one (a heal re-run); a fresh signup
|
|
95
108
|
* and a fresh-terminal heal legitimately hold none
|
|
@@ -102,7 +115,7 @@ export async function mintCredentialAnchoredAccountKeySet() {
|
|
|
102
115
|
* re-bind) passes `false` and promotes after that write
|
|
103
116
|
* @returns {Promise<AccountGenesisResult>}
|
|
104
117
|
*/
|
|
105
|
-
export async function ensureCredentialAnchoredAccountGenesis({ was, wasServerUrl, spaceId, ladderSeed, keyAgreement, standingRecipient, userKey, idStore, rosterStoreFor, expectedDid, accountLogPinStore, onDidPublished, promoteController = true }) {
|
|
118
|
+
export async function ensureCredentialAnchoredAccountGenesis({ was, wasServerUrl, spaceId, ladderSeed, keyAgreement, standingRecipient, userKey, idStore, rosterStoreFor, provideDidWebKeys, expectedDid, accountLogPinStore, onDidPublished, promoteController = true }) {
|
|
106
119
|
const failed = [];
|
|
107
120
|
const bootstrap = await ladderVmAgent({ ladderSeed });
|
|
108
121
|
// 1. The Space and its collection roster, create-if-absent under the
|
|
@@ -114,19 +127,35 @@ export async function ensureCredentialAnchoredAccountGenesis({ was, wasServerUrl
|
|
|
114
127
|
catch (err) {
|
|
115
128
|
throw new AccountGenesisSpaceError({ spaceId, cause: err });
|
|
116
129
|
}
|
|
117
|
-
// 2. The
|
|
130
|
+
// 2. The optional KMS key map, acquired only once the Space exists (a
|
|
131
|
+
// KMS-keeping wallet creates the keystore under the ladder VM's bare
|
|
132
|
+
// did:key and writes keys.json and did.json into the Space here). A throw
|
|
133
|
+
// degrades to the ladder-and-credential-only genesis rather than aborting:
|
|
134
|
+
// every later ceremony anchors in the ladder, and a later login heals the
|
|
135
|
+
// document with the convenience key.
|
|
136
|
+
let didWebKeys;
|
|
137
|
+
if (provideDidWebKeys) {
|
|
138
|
+
try {
|
|
139
|
+
didWebKeys = await provideDidWebKeys();
|
|
140
|
+
}
|
|
141
|
+
catch (err) {
|
|
142
|
+
failed.push({ stage: 'didWebKeys', error: err });
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
// 3. The ladder-anchored did:webvh genesis -- probe, adopt
|
|
118
146
|
// (ladder-attributed), or create-and-publish. Fatal on failure, like the durable stage.
|
|
119
147
|
const { did } = await ensureLadderAnchoredDidWebvh({
|
|
120
148
|
idStore,
|
|
121
149
|
wasServerUrl,
|
|
122
150
|
spaceId,
|
|
151
|
+
...(didWebKeys ? { didWebKeys } : {}),
|
|
123
152
|
ladderSeed,
|
|
124
153
|
keyAgreement,
|
|
125
154
|
...(expectedDid !== undefined ? { expectedDid } : {}),
|
|
126
155
|
...(accountLogPinStore ? { pinStore: accountLogPinStore } : {})
|
|
127
156
|
});
|
|
128
157
|
await onDidPublished?.({ did });
|
|
129
|
-
//
|
|
158
|
+
// 4. The roster genesis: epoch[0] IS the user key, wrapped once, to the
|
|
130
159
|
// credential's standing key-agreement key. The store's ladder-signed
|
|
131
160
|
// genesis append is the ceremony-tail license's first-entry shape.
|
|
132
161
|
let rosterDescriptor;
|
|
@@ -145,7 +174,7 @@ export async function ensureCredentialAnchoredAccountGenesis({ was, wasServerUrl
|
|
|
145
174
|
catch (err) {
|
|
146
175
|
failed.push({ stage: 'roster', error: err });
|
|
147
176
|
}
|
|
148
|
-
//
|
|
177
|
+
// 5. Epoch[0] on every encrypted roster collection, only behind a landed
|
|
149
178
|
// roster whose current epoch IS this run's user key (see the module doc:
|
|
150
179
|
// the user key is memory-only here, and an adopted roster keyed to another
|
|
151
180
|
// run's key would have the collections installed under a throwaway).
|
|
@@ -167,7 +196,7 @@ export async function ensureCredentialAnchoredAccountGenesis({ was, wasServerUrl
|
|
|
167
196
|
: {};
|
|
168
197
|
}
|
|
169
198
|
}
|
|
170
|
-
//
|
|
199
|
+
// 6. The controller promotion, last. The bootstrap client IS the bare
|
|
171
200
|
// did:key client, so it serves the heal branch too.
|
|
172
201
|
let promotion;
|
|
173
202
|
if (promoteController) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"credentialAnchoredGenesis.js","sourceRoot":"","sources":["../../src/clientAnnex/credentialAnchoredGenesis.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH
|
|
1
|
+
{"version":3,"file":"credentialAnchoredGenesis.js","sourceRoot":"","sources":["../../src/clientAnnex/credentialAnchoredGenesis.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiDG;AACH,OAAO,EACL,cAAc,EAEf,MAAM,yBAAyB,CAAA;AAIhC,OAAO,EAAE,oBAAoB,EAAE,MAAM,mBAAmB,CAAA;AACxD,OAAO,EAAE,aAAa,EAAE,MAAM,WAAW,CAAA;AAEzC,OAAO,EAAE,4BAA4B,EAAE,MAAM,qBAAqB,CAAA;AAElE,OAAO,EACL,uBAAuB,EACvB,WAAW,EAGZ,MAAM,kBAAkB,CAAA;AAEzB,OAAO,EACL,wBAAwB,EACxB,6BAA6B,EAC7B,WAAW,EAEZ,MAAM,8BAA8B,CAAA;AAErC;;;;;;;;GAQG;AACH,MAAM,CAAC,KAAK,UAAU,mCAAmC;IAIvD,OAAO,EAAE,OAAO,EAAE,WAAW,EAAE,EAAE,OAAO,EAAE,MAAM,WAAW,EAAE,EAAE,CAAA;AACjE,CAAC;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6CG;AACH,MAAM,CAAC,KAAK,UAAU,sCAAsC,CAAC,EAC3D,GAAG,EACH,YAAY,EACZ,OAAO,EACP,UAAU,EACV,YAAY,EACZ,iBAAiB,EACjB,OAAO,EACP,OAAO,EACP,cAAc,EACd,iBAAiB,EACjB,WAAW,EACX,kBAAkB,EAClB,cAAc,EACd,iBAAiB,GAAG,IAAI,EAgBzB;IACC,MAAM,MAAM,GAAmC,EAAE,CAAA;IACjD,MAAM,SAAS,GAAG,MAAM,aAAa,CAAC,EAAE,UAAU,EAAE,CAAC,CAAA;IAErD,qEAA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,CAAA;QACV,CAAC;IACH,CAAC;IAED,sEAAsE;IACtE,oDAAoD;IACpD,IAAI,SAA4C,CAAA;IAChD,IAAI,iBAAiB,EAAE,CAAC;QACtB,IAAI,CAAC;YACH,SAAS,GAAG,MAAM,6BAA6B,CAAC;gBAC9C,GAAG;gBACH,WAAW,EAAE,GAAG;gBAChB,OAAO;gBACP,GAAG;aACJ,CAAC,CAAA;QACJ,CAAC;QAAC,OAAO,GAAG,EAAE,CAAC;YACb,MAAM,CAAC,IAAI,CAAC,EAAE,KAAK,EAAE,WAAW,EAAE,KAAK,EAAE,GAAG,EAAE,CAAC,CAAA;QACjD,CAAC;IACH,CAAC;IAED,OAAO;QACL,GAAG;QACH,GAAG,CAAC,gBAAgB,CAAC,CAAC,CAAC,EAAE,gBAAgB,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;QACjD,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;QAC7B,GAAG,CAAC,aAAa,CAAC,CAAC,CAAC,EAAE,aAAa,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;QAC3C,GAAG,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,SAAS,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;QACnC,MAAM;KACP,CAAA;AACH,CAAC"}
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
* this client's wrap in ONE append (the license's one-shot shape), read
|
|
23
23
|
* back through the credential's standing wrap. Because the append's
|
|
24
24
|
* signer is the ladder VM -- a key the post-removal document still lists
|
|
25
|
-
* -- the roster log needs no seal
|
|
25
|
+
* -- the roster log needs no seal repair afterwards, which matters on
|
|
26
26
|
* an account where no enrolled client's login sweep will ever run again.
|
|
27
27
|
* 3. **The collection fan-out**, still under this client's invocation
|
|
28
28
|
* authority: every encrypted collection re-epochs onto the fresh key.
|
|
@@ -51,10 +51,11 @@
|
|
|
51
51
|
* management zcaps are granted to the account DID, which only an enrolled
|
|
52
52
|
* client can invoke) -- which is why the stage must run before the
|
|
53
53
|
* removal entry. The pass walks every entry and reports each one's fate,
|
|
54
|
-
* but the ceremony does not carry
|
|
55
|
-
* entry refuses the removal entry
|
|
56
|
-
* naming the records the pass
|
|
57
|
-
* nothing could ever re-sign that
|
|
54
|
+
* but the ceremony does not carry an unsettled entry past this point: a
|
|
55
|
+
* `failed` or `pending-entry` outcome refuses the removal entry
|
|
56
|
+
* ({@link RecordRemintFailedError}, naming the records the pass left
|
|
57
|
+
* unreached), since after the removal nothing could ever re-sign that
|
|
58
|
+
* record's bridge. The client stays
|
|
58
59
|
* enrolled, and a re-run reaches the entry again.
|
|
59
60
|
* 6. **The record re-bind seam** (`onBeforeRemoval`, required): the caller
|
|
60
61
|
* re-signs the LOGIN credential's bridge and `delegatedClients` sibling
|
|
@@ -165,10 +166,16 @@ export interface LastDurableClientForgetResult {
|
|
|
165
166
|
rosterDescriptor?: CollectionEncryption;
|
|
166
167
|
}
|
|
167
168
|
/**
|
|
168
|
-
* The record re-mint stage could not
|
|
169
|
-
* record, so the removal entry was refused: `failed` names the entries
|
|
170
|
-
* re-mint threw (each carrying its cause)
|
|
171
|
-
*
|
|
169
|
+
* The record re-mint stage could not settle every other unlock method's
|
|
170
|
+
* record, so the removal entry was refused: `failed` names the entries the
|
|
171
|
+
* pass left unreached -- those whose re-mint threw (each carrying its cause)
|
|
172
|
+
* and those it skipped as pending-shaped (the entry's identity members name
|
|
173
|
+
* a credential other than the one its record is sealed to) -- and
|
|
174
|
+
* `unlockMethods` is the whole stage report. A pending-shaped entry blocks
|
|
175
|
+
* for the same reason a failed one does: its bridge is left signed by the
|
|
176
|
+
* key the removal entry strikes, and on a client-less account no login will
|
|
177
|
+
* ever heal it. The mender is a durable login, which is exactly what the
|
|
178
|
+
* removal would end. The forgotten client is still enrolled and every stage
|
|
172
179
|
* before this one has landed, so a re-run resumes at the re-mint. Matched
|
|
173
180
|
* on `name` (the errors cross app-injected seams that may resolve to another
|
|
174
181
|
* copy of this package).
|
|
@@ -248,7 +255,8 @@ export declare class RecordRemintFailedError extends Error {
|
|
|
248
255
|
* re-seals through their management zcaps, invoked as the still-standing
|
|
249
256
|
* client. Omitted, the stage is skipped and the result carries no
|
|
250
257
|
* `unlockMethods` report -- the residue decision 0004's amendment stated.
|
|
251
|
-
* Supplied, an entry the pass could not re-mint
|
|
258
|
+
* Supplied, an entry the pass could not re-mint -- or skipped as
|
|
259
|
+
* pending-shaped -- refuses the removal entry
|
|
252
260
|
* (`RecordRemintFailedError`)
|
|
253
261
|
* @param options.onBeforeRemoval {Function}
|
|
254
262
|
* `({ did, doc, log }) => Promise<void>` -- the record re-bind seam: runs
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"forgetLast.d.ts","sourceRoot":"","sources":["../../src/clientAnnex/forgetLast.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH
|
|
1
|
+
{"version":3,"file":"forgetLast.d.ts","sourceRoot":"","sources":["../../src/clientAnnex/forgetLast.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwFG;AACH,OAAO,KAAK,EAAU,MAAM,EAAE,MAAM,2BAA2B,CAAA;AAC/D,OAAO,KAAK,EAAE,gBAAgB,EAAE,KAAK,EAAE,MAAM,8BAA8B,CAAA;AAC3E,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAA;AAChD,OAAO,KAAK,EAAE,oBAAoB,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAA;AAC/E,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,yBAAyB,CAAA;AAIxE,OAAO,EAEL,KAAK,iBAAiB,EACvB,MAAM,0BAA0B,CAAA;AAEjC,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAA;AAEnE,OAAO,EAKL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AAE,OAAO,CAAA;IACjB,aAAa,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IAC7B,gBAAgB,CAAC,EAAE,CAAC,OAAO,EAAE;QAC3B,OAAO,EAAE,OAAO,CAAA;QAChB,aAAa,EAAE,MAAM,CAAA;QACrB,UAAU,EAAE,oBAAoB,CAAA;KACjC,KAAK,OAAO,CAAC,IAAI,CAAC,CAAA;IACnB,WAAW,EAAE,kBAAkB,CAAA;IAC/B,KAAK,EAAE;QACL,QAAQ,EAAE,CAAC,OAAO,EAAE;YAClB,OAAO,EAAE,MAAM,CAAA;YACf,YAAY,EAAE,MAAM,CAAA;SACrB,KAAK,qBAAqB,CAAA;QAC3B,MAAM,EAAE,CAAC,UAAU,EAAE,cAAc,KAAK,OAAO,CAAC,IAAI,CAAC,CAAA;QACrD,YAAY,EAAE,MAAM,CAAA;QACpB,cAAc,EAAE,MAAM,CAAA;QACtB,QAAQ,CAAC,EAAE,mBAAmB,CAAA;KAC/B,CAAA;IACD,aAAa,CAAC,EAAE,wBAAwB,CAAA;IACxC,eAAe,EAAE,CAAC,SAAS,EAAE;QAC3B,GAAG,EAAE,MAAM,CAAA;QACX,GAAG,EAAE,MAAM,CAAA;QACX,GAAG,EAAE,MAAM,CAAA;KACZ,KAAK,OAAO,CAAC,IAAI,CAAC,CAAA;IACnB,GAAG,CAAC,EAAE,MAAM,CAAA;CACb,GAAG,OAAO,CAAC,6BAA6B,CAAC,CAgMzC"}
|
|
@@ -12,10 +12,28 @@ import { ladderVmAgent, ladderVmZcapClient } from './zcap.js';
|
|
|
12
12
|
import { forgetLastWebvhClient, installLadderVmWebvh } from './ladderAnchored.js';
|
|
13
13
|
import { clientAnnexDidParts, clientAnnexLogPinId, delegatedClientsDelegationMinter, delegatedClientsPointer, ensureGenerationDelegationCurrent, generationDelegationHistory, mintGenerationDelegation, revokeTreatingAlreadyRevokedAsSuccess } from './log.js';
|
|
14
14
|
/**
|
|
15
|
-
* The
|
|
16
|
-
*
|
|
17
|
-
* re-
|
|
18
|
-
*
|
|
15
|
+
* The re-mint outcomes that withhold the removal entry: a record the pass
|
|
16
|
+
* could not reach, and a pending-shaped entry it deliberately did not write
|
|
17
|
+
* (re-minting one would seal a half-retired credential a fresh bridge into
|
|
18
|
+
* the standing credential's record). Both leave a bridge the removal entry
|
|
19
|
+
* would rot for good on an account that will never see a durable login
|
|
20
|
+
* again.
|
|
21
|
+
*/
|
|
22
|
+
const REMINT_BLOCKING_OUTCOMES = [
|
|
23
|
+
'failed',
|
|
24
|
+
'pending-entry'
|
|
25
|
+
];
|
|
26
|
+
/**
|
|
27
|
+
* The record re-mint stage could not settle every other unlock method's
|
|
28
|
+
* record, so the removal entry was refused: `failed` names the entries the
|
|
29
|
+
* pass left unreached -- those whose re-mint threw (each carrying its cause)
|
|
30
|
+
* and those it skipped as pending-shaped (the entry's identity members name
|
|
31
|
+
* a credential other than the one its record is sealed to) -- and
|
|
32
|
+
* `unlockMethods` is the whole stage report. A pending-shaped entry blocks
|
|
33
|
+
* for the same reason a failed one does: its bridge is left signed by the
|
|
34
|
+
* key the removal entry strikes, and on a client-less account no login will
|
|
35
|
+
* ever heal it. The mender is a durable login, which is exactly what the
|
|
36
|
+
* removal would end. The forgotten client is still enrolled and every stage
|
|
19
37
|
* before this one has landed, so a re-run resumes at the re-mint. Matched
|
|
20
38
|
* on `name` (the errors cross app-injected seams that may resolve to another
|
|
21
39
|
* copy of this package).
|
|
@@ -24,8 +42,8 @@ export class RecordRemintFailedError extends Error {
|
|
|
24
42
|
failed;
|
|
25
43
|
unlockMethods;
|
|
26
44
|
constructor({ unlockMethods }) {
|
|
27
|
-
const failed = unlockMethods.outcomes.filter(outcome => outcome.outcome
|
|
28
|
-
super('did:webvh: the last-client forget could not
|
|
45
|
+
const failed = unlockMethods.outcomes.filter(outcome => REMINT_BLOCKING_OUTCOMES.includes(outcome.outcome));
|
|
46
|
+
super('did:webvh: the last-client forget could not settle the record of ' +
|
|
29
47
|
`${failed.length} other unlock method(s) (` +
|
|
30
48
|
failed.map(outcome => `"${outcome.label}"`).join(', ') +
|
|
31
49
|
'); the removal entry was not published. The client stays enrolled; ' +
|
|
@@ -103,7 +121,8 @@ export class RecordRemintFailedError extends Error {
|
|
|
103
121
|
* re-seals through their management zcaps, invoked as the still-standing
|
|
104
122
|
* client. Omitted, the stage is skipped and the result carries no
|
|
105
123
|
* `unlockMethods` report -- the residue decision 0004's amendment stated.
|
|
106
|
-
* Supplied, an entry the pass could not re-mint
|
|
124
|
+
* Supplied, an entry the pass could not re-mint -- or skipped as
|
|
125
|
+
* pending-shaped -- refuses the removal entry
|
|
107
126
|
* (`RecordRemintFailedError`)
|
|
108
127
|
* @param options.onBeforeRemoval {Function}
|
|
109
128
|
* `({ did, doc, log }) => Promise<void>` -- the record re-bind seam: runs
|
|
@@ -247,11 +266,12 @@ export async function forgetLastDurableClient({ logStore, pinStore, ladderSeed,
|
|
|
247
266
|
now
|
|
248
267
|
});
|
|
249
268
|
// The one pass that will ever reach these records on a client-less
|
|
250
|
-
// account: a record it could not re-seal
|
|
269
|
+
// account: a record it could not re-seal -- or deliberately did not
|
|
270
|
+
// write, the pending-shaped entry -- would be left with a bridge the
|
|
251
271
|
// removal entry rots for good, so the removal is refused instead. The
|
|
252
272
|
// stages already landed are idempotent and the client still stands, so
|
|
253
273
|
// the re-run resumes here.
|
|
254
|
-
if (remint.outcomes.some(outcome => outcome.outcome
|
|
274
|
+
if (remint.outcomes.some(outcome => REMINT_BLOCKING_OUTCOMES.includes(outcome.outcome))) {
|
|
255
275
|
throw new RecordRemintFailedError({ unlockMethods: remint });
|
|
256
276
|
}
|
|
257
277
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"forgetLast.js","sourceRoot":"","sources":["../../src/clientAnnex/forgetLast.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"forgetLast.js","sourceRoot":"","sources":["../../src/clientAnnex/forgetLast.ts"],"names":[],"mappings":"AAiGA,OAAO,EAAE,g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,EAAE,KAAK,CAAC,OAAO;QACtB,gBAAgB,EAAE,KAAK,CAAC,gBAAgB;QACxC,UAAU,EAAE,YAAY;QACxB,YAAY;QACZ,oBAAoB,EAAE,KAAK,CAAC,oBAAoB;QAChD,WAAW,EAAE,KAAK,CAAC,WAAW;QAC9B,8BAA8B,EAAE,gCAAgC,CAAC;YAC/D,GAAG;YACH,UAAU,EAAE,YAAY;YACxB,YAAY,EAAE,KAAK,CAAC,OAAO,CAAC,IAAI;SACjC,CAAC;QACF,qBAAqB,EAAE,CAAC,2BAA2B,CAAC;QACpD,GAAG;KACJ,CAAC,CAAA;AACJ,CAAC"}
|
|
@@ -48,7 +48,7 @@ export type { ClientAnnexWriteStore } from './log.js';
|
|
|
48
48
|
export { clientAnnexGcDue, delegatedClientsPointerEstablishedAt, GENERATION_GC_PERIOD_MS, GENERATION_QUIET_BOUND_MS, GENERATION_QUIET_GRACE_MS, generationQuiet, runClientAnnexGc, swapClientAnnexGeneration } from './gc.js';
|
|
49
49
|
export type { ClientAnnexGcReport, ClientAnnexGcSwapOutcome } from './gc.js';
|
|
50
50
|
export { ladderVmAgent, ladderVmZcapClient } from './zcap.js';
|
|
51
|
-
export { createLadderAnchoredAccountLog, ensureLadderAnchoredDidWebvh, forgetLastWebvhClient, forgetWebvhClient, installLadderVmWebvh, LastDurableClientForgetError, selfEnrollWebvhClient } from './ladderAnchored.js';
|
|
51
|
+
export { BuiltOnHeadNotReachedError, createLadderAnchoredAccountLog, ensureLadderAnchoredDidWebvh, forgetLastWebvhClient, forgetWebvhClient, installLadderVmWebvh, LastDurableClientForgetError, selfEnrollWebvhClient } from './ladderAnchored.js';
|
|
52
52
|
export { selfEnrollClientCore } from './selfEnroll.js';
|
|
53
53
|
export { forgetDurableClient } from './forget.js';
|
|
54
54
|
export type { DurableClientForgetResult } from './forget.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/clientAnnex/index.ts"],"names":[],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EACL,8BAA8B,EAC9B,4BAA4B,EAC5B,qBAAqB,EACrB,iBAAiB,EACjB,oBAAoB,EACpB,4BAA4B,EAC5B,qBAAqB,EACtB,MAAM,qBAAqB,CAAA;AAE5B,OAAO,EAAE,oBAAoB,EAAE,MAAM,iBAAiB,CAAA;AAEtD,OAAO,EAAE,mBAAmB,EAAE,MAAM,aAAa,CAAA;AACjD,YAAY,EAAE,yBAAyB,EAAE,MAAM,aAAa,CAAA;AAE5D,OAAO,EACL,uBAAuB,EACvB,uBAAuB,EACxB,MAAM,iBAAiB,CAAA;AACxB,YAAY,EACV,8BAA8B,EAC9B,6BAA6B,EAC7B,wBAAwB,EACzB,MAAM,iBAAiB,CAAA;AAExB,OAAO,EACL,sCAAsC,EACtC,mCAAmC,EACpC,MAAM,gCAAgC,CAAA;AAEvC,OAAO,EAAE,0BAA0B,EAAE,MAAM,6BAA6B,CAAA;AAOxE,OAAO,EACL,4BAA4B,EAC5B,wBAAwB,EACzB,MAAM,sBAAsB,CAAA"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/clientAnnex/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuCG;AACH,OAAO,EACL,wBAAwB,EACxB,mBAAmB,EACnB,eAAe,EACf,mBAAmB,EACnB,kBAAkB,EAClB,eAAe,EACf,sBAAsB,EACtB,UAAU,EACV,cAAc,EACd,oBAAoB,EACpB,YAAY,EACb,MAAM,aAAa,CAAA;AACpB,YAAY,EACV,UAAU,EACV,eAAe,EACf,uBAAuB,EACxB,MAAM,aAAa,CAAA;AAEpB,OAAO,EACL,kBAAkB,EAClB,iBAAiB,EACjB,uBAAuB,EACvB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,+BAA+B,EAC/B,qBAAqB,EACrB,oBAAoB,EACpB,oCAAoC,EACpC,mCAAmC,EACnC,8BAA8B,EAC9B,gCAAgC,EACh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O,EAAE,0BAA0B,EAAE,MAAM,6BAA6B,CAAA;AAOxE,OAAO,EACL,4BAA4B,EAC5B,wBAAwB,EACzB,MAAM,sBAAsB,CAAA"}
|
|
@@ -45,7 +45,7 @@ export { attributeLadderInventory, attributeLadderRung, clientAnnexRung, clientA
|
|
|
45
45
|
export { assertGenerationId, clampGrantExpires, CLIENT_ANNEX_SPACE_TYPE, clientAnnexDidParts, clientAnnexLogPinId, clientAnnexLogStore, ClientAnnexRungUncommittedError, commitClientAnnexRung, createClientAnnexLog, DELEGATED_CLIENTS_DELEGATION_ACTIONS, DELEGATED_CLIENTS_DELEGATION_TTL_MS, DELEGATED_CLIENTS_SERVICE_TYPE, delegatedClientsDelegationMinter, delegatedClientsDelegationSpaceId, delegatedClientsPointer, delegatedClientsServiceEntry, embeddedGenerationDelegation, enrollClientAnnexTransientClient, enrollTransientClient, ensureClientAnnexSpace, ensureGenerationDelegationCurrent, GENERATION_DELEGATION_ACTIONS, GENERATION_DELEGATION_SERVICE_TYPE, GENERATION_DELEGATION_TTL_MS, GENERATION_ID_PREFIX, generationDelegationHistory, generationDelegationServiceEntry, mintClientAnnexGeneration, mintCredentialClientAnnexGeneration, mintDelegatedClientsDelegation, mintGenerationDelegation, mintGenerationId, retireClientAnnexRung, revokeTreatingAlreadyRevokedAsSuccess, servicesPointedAtClientAnnex, setDelegatedClientsPointer } from './log.js';
|
|
46
46
|
export { clientAnnexGcDue, delegatedClientsPointerEstablishedAt, GENERATION_GC_PERIOD_MS, GENERATION_QUIET_BOUND_MS, GENERATION_QUIET_GRACE_MS, generationQuiet, runClientAnnexGc, swapClientAnnexGeneration } from './gc.js';
|
|
47
47
|
export { ladderVmAgent, ladderVmZcapClient } from './zcap.js';
|
|
48
|
-
export { createLadderAnchoredAccountLog, ensureLadderAnchoredDidWebvh, forgetLastWebvhClient, forgetWebvhClient, installLadderVmWebvh, LastDurableClientForgetError, selfEnrollWebvhClient } from './ladderAnchored.js';
|
|
48
|
+
export { BuiltOnHeadNotReachedError, createLadderAnchoredAccountLog, ensureLadderAnchoredDidWebvh, forgetLastWebvhClient, forgetWebvhClient, installLadderVmWebvh, LastDurableClientForgetError, selfEnrollWebvhClient } from './ladderAnchored.js';
|
|
49
49
|
export { selfEnrollClientCore } from './selfEnroll.js';
|
|
50
50
|
export { forgetDurableClient } from './forget.js';
|
|
51
51
|
export { forgetLastDurableClient, RecordRemintFailedError } from './forgetLast.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/clientAnnex/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuCG;AACH,OAAO,EACL,wBAAwB,EACxB,mBAAmB,EACnB,eAAe,EACf,mBAAmB,EACnB,kBAAkB,EAClB,eAAe,EACf,sBAAsB,EACtB,UAAU,EACV,cAAc,EACd,oBAAoB,EACpB,YAAY,EACb,MAAM,aAAa,CAAA;AAOpB,OAAO,EACL,kBAAkB,EAClB,iBAAiB,EACjB,uBAAuB,EACvB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,+BAA+B,EAC/B,qBAAqB,EACrB,oBAAoB,EACpB,oCAAoC,EACpC,mCAAmC,EACnC,8BAA8B,EAC9B,gCAAgC,EAChC,iCAAiC,EACjC,uBAAuB,EACvB,4BAA4B,EAC5B,4BAA4B,EAC5B,gCAAgC,EAChC,qBAAqB,EACrB,sBAAsB,EACtB,iCAAiC,EACjC,6BAA6B,EAC7B,kCAAkC,EAClC,4BAA4B,EAC5B,oBAAoB,EACpB,2BAA2B,EAC3B,gCAAgC,EAChC,yBAAyB,EACzB,mCAAmC,EACnC,8BAA8B,EAC9B,wBAAwB,EACxB,gBAAgB,EAChB,qBAAqB,EACrB,qCAAqC,EACrC,4BAA4B,EAC5B,0BAA0B,EAC3B,MAAM,UAAU,CAAA;AAGjB,OAAO,EACL,gBAAgB,EAChB,oCAAoC,EACpC,uBAAuB,EACvB,yBAAyB,EACzB,yBAAyB,EACzB,eAAe,EACf,gBAAgB,EAChB,yBAAyB,EAC1B,MAAM,SAAS,CAAA;AAGhB,OAAO,EAAE,aAAa,EAAE,kBAAkB,EAAE,MAAM,WAAW,CAAA;AAE7D,OAAO,EACL,8BAA8B,EAC9B,4BAA4B,EAC5B,qBAAqB,EACrB,iBAAiB,EACjB,oBAAoB,EACpB,4BAA4B,EAC5B,qBAAqB,EACtB,MAAM,qBAAqB,CAAA;AAE5B,OAAO,EAAE,oBAAoB,EAAE,MAAM,iBAAiB,CAAA;AAEtD,OAAO,EAAE,mBAAmB,EAAE,MAAM,aAAa,CAAA;AAGjD,OAAO,EACL,uBAAuB,EACvB,uBAAuB,EACxB,MAAM,iBAAiB,CAAA;AAOxB,OAAO,EACL,sCAAsC,EACtC,mCAAmC,EACpC,MAAM,gCAAgC,CAAA;AAEvC,OAAO,EAAE,0BAA0B,EAAE,MAAM,6BAA6B,CAAA;AAExE,4EAA4E;AAC5E,qEAAqE;AACrE,6EAA6E;AAC7E,4EAA4E;AAC5E,wBAAwB;AACxB,OAAO,EACL,4BAA4B,EAC5B,wBAAwB,EACzB,MAAM,sBAAsB,CAAA"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/clientAnnex/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuCG;AACH,OAAO,EACL,wBAAwB,EACxB,mBAAmB,EACnB,eAAe,EACf,mBAAmB,EACnB,kBAAkB,EAClB,eAAe,EACf,sBAAsB,EACtB,UAAU,EACV,cAAc,EACd,oBAAoB,EACpB,YAAY,EACb,MAAM,aAAa,CAAA;AAOpB,OAAO,EACL,kBAAkB,EAClB,iBAAiB,EACjB,uBAAuB,EACvB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,+BAA+B,EAC/B,qBAAqB,EACrB,oBAAoB,EACpB,oCAAoC,EACpC,m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