@interop/wallet-core 0.107.1 → 0.108.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.
Files changed (107) hide show
  1. package/README.md +21 -19
  2. package/dist/clientAnnex/establish.d.ts +6 -5
  3. package/dist/clientAnnex/establish.d.ts.map +1 -1
  4. package/dist/clientAnnex/establish.js +9 -8
  5. package/dist/clientAnnex/establish.js.map +1 -1
  6. package/dist/clientAnnex/forget.d.ts +5 -5
  7. package/dist/clientAnnex/forget.d.ts.map +1 -1
  8. package/dist/clientAnnex/forget.js +1 -1
  9. package/dist/clientAnnex/forget.js.map +1 -1
  10. package/dist/clientAnnex/forgetLast.d.ts +8 -8
  11. package/dist/clientAnnex/forgetLast.d.ts.map +1 -1
  12. package/dist/clientAnnex/forgetLast.js +2 -2
  13. package/dist/clientAnnex/forgetLast.js.map +1 -1
  14. package/dist/clientAnnex/gc.d.ts.map +1 -1
  15. package/dist/clientAnnex/gc.js +4 -1
  16. package/dist/clientAnnex/gc.js.map +1 -1
  17. package/dist/clientAnnex/heal.d.ts +16 -14
  18. package/dist/clientAnnex/heal.d.ts.map +1 -1
  19. package/dist/clientAnnex/heal.js +9 -9
  20. package/dist/clientAnnex/heal.js.map +1 -1
  21. package/dist/clientAnnex/ladderAnchored.d.ts +35 -27
  22. package/dist/clientAnnex/ladderAnchored.d.ts.map +1 -1
  23. package/dist/clientAnnex/ladderAnchored.js +26 -37
  24. package/dist/clientAnnex/ladderAnchored.js.map +1 -1
  25. package/dist/clientAnnex/log.d.ts +31 -31
  26. package/dist/clientAnnex/log.d.ts.map +1 -1
  27. package/dist/clientAnnex/log.js +28 -28
  28. package/dist/clientAnnex/log.js.map +1 -1
  29. package/dist/clientAnnex/recoveryLadderAnchored.d.ts +4 -3
  30. package/dist/clientAnnex/recoveryLadderAnchored.d.ts.map +1 -1
  31. package/dist/clientAnnex/recoveryLadderAnchored.js +1 -1
  32. package/dist/clientAnnex/selfEnroll.d.ts +3 -3
  33. package/dist/clientAnnex/selfEnroll.d.ts.map +1 -1
  34. package/dist/clientAnnex/selfEnroll.js +1 -1
  35. package/dist/clients/revocation.d.ts +2 -2
  36. package/dist/clients/revocation.d.ts.map +1 -1
  37. package/dist/clients/revocation.js.map +1 -1
  38. package/dist/connections/entry.d.ts +100 -9
  39. package/dist/connections/entry.d.ts.map +1 -1
  40. package/dist/connections/entry.js +104 -12
  41. package/dist/connections/entry.js.map +1 -1
  42. package/dist/connections/grants.d.ts.map +1 -1
  43. package/dist/connections/grants.js +3 -5
  44. package/dist/connections/grants.js.map +1 -1
  45. package/dist/connections/index.d.ts +9 -5
  46. package/dist/connections/index.d.ts.map +1 -1
  47. package/dist/connections/index.js +7 -4
  48. package/dist/connections/index.js.map +1 -1
  49. package/dist/connections/replicas.d.ts +227 -0
  50. package/dist/connections/replicas.d.ts.map +1 -0
  51. package/dist/connections/replicas.js +539 -0
  52. package/dist/connections/replicas.js.map +1 -0
  53. package/dist/connections/upsert.d.ts +75 -1
  54. package/dist/connections/upsert.d.ts.map +1 -1
  55. package/dist/connections/upsert.js +62 -34
  56. package/dist/connections/upsert.js.map +1 -1
  57. package/dist/recovery/continuation.d.ts +3 -9
  58. package/dist/recovery/continuation.d.ts.map +1 -1
  59. package/dist/recovery/continuation.js +1 -3
  60. package/dist/recovery/continuation.js.map +1 -1
  61. package/dist/recovery/index.d.ts +2 -1
  62. package/dist/recovery/index.d.ts.map +1 -1
  63. package/dist/recovery/recoveryWebvh.d.ts +21 -15
  64. package/dist/recovery/recoveryWebvh.d.ts.map +1 -1
  65. package/dist/recovery/recoveryWebvh.js +12 -7
  66. package/dist/recovery/recoveryWebvh.js.map +1 -1
  67. package/dist/testing/accountBuilder.d.ts.map +1 -1
  68. package/dist/testing/accountBuilder.js +1 -3
  69. package/dist/testing/accountBuilder.js.map +1 -1
  70. package/dist/unlock/index.d.ts +2 -1
  71. package/dist/unlock/index.d.ts.map +1 -1
  72. package/dist/unlock/retire.d.ts +7 -5
  73. package/dist/unlock/retire.d.ts.map +1 -1
  74. package/dist/unlock/retire.js +5 -4
  75. package/dist/unlock/retire.js.map +1 -1
  76. package/dist/unlock/standingWebvh.d.ts +24 -15
  77. package/dist/unlock/standingWebvh.d.ts.map +1 -1
  78. package/dist/unlock/standingWebvh.js +32 -19
  79. package/dist/unlock/standingWebvh.js.map +1 -1
  80. package/dist/webvh/accountEntry.d.ts +39 -50
  81. package/dist/webvh/accountEntry.d.ts.map +1 -1
  82. package/dist/webvh/accountEntry.js +133 -55
  83. package/dist/webvh/accountEntry.js.map +1 -1
  84. package/dist/webvh/delegatedLogStore.d.ts +4 -11
  85. package/dist/webvh/delegatedLogStore.d.ts.map +1 -1
  86. package/dist/webvh/delegatedLogStore.js +1 -1
  87. package/dist/webvh/delegatedLogStore.js.map +1 -1
  88. package/dist/webvh/didWebProjection.d.ts +30 -49
  89. package/dist/webvh/didWebProjection.d.ts.map +1 -1
  90. package/dist/webvh/didWebProjection.js +9 -56
  91. package/dist/webvh/didWebProjection.js.map +1 -1
  92. package/dist/webvh/didWebvh.d.ts +13 -8
  93. package/dist/webvh/didWebvh.d.ts.map +1 -1
  94. package/dist/webvh/didWebvh.js +11 -7
  95. package/dist/webvh/didWebvh.js.map +1 -1
  96. package/dist/webvh/enrollClient.d.ts +5 -3
  97. package/dist/webvh/enrollClient.d.ts.map +1 -1
  98. package/dist/webvh/enrollClient.js +12 -10
  99. package/dist/webvh/enrollClient.js.map +1 -1
  100. package/dist/webvh/index.d.ts +1 -1
  101. package/dist/webvh/index.d.ts.map +1 -1
  102. package/dist/webvh/index.js.map +1 -1
  103. package/dist/webvh/revokeClient.d.ts +10 -4
  104. package/dist/webvh/revokeClient.d.ts.map +1 -1
  105. package/dist/webvh/revokeClient.js +22 -22
  106. package/dist/webvh/revokeClient.js.map +1 -1
  107. package/package.json +5 -5
@@ -1,5 +1,6 @@
1
1
  import type { DIDDoc, DIDLog, UpdateDIDInterface, UpdateDIDResult } from '@interop/did-method-webvh';
2
2
  import type { ClientWebvhUpdateKeys, PublishedWebvhLog, WebvhIdStore } from './didWebvh.js';
3
+ import type { DidWebProjectionStore } from './didWebProjection.js';
3
4
  import type { BuiltOnHead } from './builtOnHead.js';
4
5
  import type { LadderRung } from './ladderDerivation.js';
5
6
  import type { LadderRungState } from './ladder.js';
@@ -30,9 +31,12 @@ export type AccountEntrySigner = AccountLogSigner | {
30
31
  };
31
32
  /**
32
33
  * The store an account-log entry is read and published through: the public
33
- * log read and the `did.jsonl` PUT. A subset of {@link WebvhIdStore}, so both
34
- * a controller-invoking client's store and a credential's bridge-backed
35
- * unlock-log store satisfy it.
34
+ * log read and the `did.jsonl` PUT. A subset of {@link WebvhIdStore}, so a
35
+ * controller-invoking client's store, a credential's bridge-delegated store
36
+ * (`delegatedWebvhLogStore`), and an app's remote-store class all satisfy
37
+ * it. It says nothing about the `did:web` projection: a write there takes a
38
+ * {@link DidWebProjectionStore} the caller hands in separately, and no arm of
39
+ * {@link signAccountEntry} asks this store for one.
36
40
  */
37
41
  export type AccountLogStore = Pick<WebvhIdStore, 'getIdResourceRaw' | 'putIdResource' | 'pin'>;
38
42
  /**
@@ -117,8 +121,15 @@ export declare function accountEntryHead({ outcome }: {
117
121
  * `did.jsonl` PUT
118
122
  * @param options.signer {AccountEntrySigner} who signs this entry
119
123
  * @param options.build {function}
120
- * `({ published, rung, state }) => AccountEntryFields | undefined` -- the
121
- * entry's own members, or `undefined` to decline
124
+ * `({ published, rung, state, concludeUnchanged }) => AccountEntryFields |
125
+ * undefined` -- the entry's own members, or `undefined` to decline.
126
+ * `concludeUnchanged()` is the idempotent path's conclusion, bound to this
127
+ * call's projection store and timing: it republishes the projection from
128
+ * the read under the `'after'` timing alone (healing a lag a torn earlier
129
+ * run's thrown post-entry PUT left behind) and writes nothing under
130
+ * `'before'`, since the entry an earlier run landed may have ended the
131
+ * store's authority. A ceremony whose build finds its entry already landed
132
+ * awaits it and declines
122
133
  * @param [options.skip] {function} `(published) => boolean` -- run on the
123
134
  * read, before any attribution; `true` returns `skipped` with nothing
124
135
  * published
@@ -141,30 +152,35 @@ export declare function accountEntryHead({ outcome }: {
141
152
  * when `did.jsonl` is absent
142
153
  * @param [options.verb] {string} what the caller is doing, for the client
143
154
  * arm's pending-rotation refusal message (e.g. `'revoking a client'`)
144
- * @param [options.logOnly] {boolean} publish `did.jsonl` without its
145
- * `did:web` projection. Defaults per arm: `true` on the ladder arm, whose
146
- * bridge reaches `did.jsonl` alone, and `false` on the enrolled arm, which
147
- * invokes as the controller. A ladder-signed entry written through a
148
- * root-invoking store (the establishment's stage 3) passes `false` to
149
- * republish the projection beside the entry; the committed arm states it,
150
- * since which store it signs through is the caller's
151
- * @param [options.beforePublish] {function} `({ updated }) => Promise<void>`
152
- * -- run on the built entry, AFTER `updateDID` and BEFORE the conditional
153
- * publish. The seam exists for the `did:web` projection: a ladder-signed
154
- * entry writes `did.jsonl` alone, so a ceremony whose entry removes
155
- * inventory has to publish the post-entry projection while the authority it
156
- * is about to end can still write it. A throw propagates and nothing is
157
- * published. It runs once per attempt, so a conflict retry invokes it again
158
- * and it must be idempotent
155
+ * @param [options.projectionStore] {DidWebProjectionStore} a store whose
156
+ * authority reaches `did.json`. Given, the post-entry `did:web` projection
157
+ * (`updateDID`'s own `webDoc`) is PUT through it and through nothing else;
158
+ * omitted, no projection is written on any arm and the next
159
+ * `ensureDidWebProjection` is the mender. An enrolled client passes its
160
+ * controller-invoking store, a transient visit its generation-delegated
161
+ * store, and a caller holding the bridge delegation alone omits it
162
+ * @param [options.removesInventory] {boolean} whether this entry strikes
163
+ * a member of the document's inventory (default `false`). It decides the
164
+ * projection's timing. A ladder-signed removal PUTs the projection after
165
+ * `updateDID` and before the conditional publish, since the entry may end
166
+ * the authority the store invokes under, and a failed PUT is warned and
167
+ * the entry publishes anyway; that write runs once per attempt, so a
168
+ * conflict retry PUTs it again. Every other entry PUTs it after `did.jsonl`
169
+ * lands, and a failed PUT throws
159
170
  * @returns {Promise<AccountEntryOutcome>}
160
171
  */
161
- export declare function signAccountEntry({ idStore, signer, build, skip, published: alreadyRead, expectedDid, builtOnHead, missingMessage, verb, logOnly, beforePublish }: {
172
+ export declare function signAccountEntry({ idStore, signer, build, skip, published: alreadyRead, expectedDid, builtOnHead, missingMessage, verb, projectionStore, removesInventory }: {
162
173
  idStore: AccountLogStore;
163
174
  signer: AccountEntrySigner;
164
175
  build: (context: {
165
176
  published: PublishedWebvhLog;
166
177
  rung?: LadderRung;
167
178
  state?: LadderRungState;
179
+ concludeUnchanged: () => Promise<{
180
+ did: string;
181
+ doc: DIDDoc;
182
+ log: DIDLog;
183
+ }>;
168
184
  }) => AccountEntryFields | undefined | Promise<AccountEntryFields | undefined>;
169
185
  skip?: (published: PublishedWebvhLog) => boolean | Promise<boolean>;
170
186
  published?: PublishedWebvhLog;
@@ -172,34 +188,7 @@ export declare function signAccountEntry({ idStore, signer, build, skip, publish
172
188
  builtOnHead?: BuiltOnHead;
173
189
  missingMessage?: string;
174
190
  verb?: string;
175
- logOnly?: boolean;
176
- beforePublish?: (built: {
177
- updated: UpdateDIDResult;
178
- }) => Promise<void>;
191
+ projectionStore?: DidWebProjectionStore;
192
+ removesInventory?: boolean;
179
193
  }): Promise<AccountEntryOutcome>;
180
- /**
181
- * The head a ceremony concludes on when its entry turns out to be
182
- * unnecessary -- the client is already enrolled, the removal already landed.
183
- * There is nothing to publish either way; what differs is the `did:web`
184
- * projection. The enrolled arm invokes as the account's controller, so it
185
- * republishes the projection and heals a lag a torn earlier run of the same
186
- * ceremony left behind. The ladder arm's bridge reaches `did.jsonl` alone, so
187
- * it takes the read verbatim and leaves the projection to
188
- * `ensureDidWebProjection`.
189
- *
190
- * @param options {object}
191
- * @param options.idStore {WebvhIdStore}
192
- * @param options.signer {AccountLogSigner} the arm the ceremony acts as
193
- * @param options.published {PublishedWebvhLog} the read the build stood on
194
- * @returns {Promise<{ did: string, doc: DIDDoc, log: DIDLog }>}
195
- */
196
- export declare function concludeUnchangedAccountEntry({ idStore, signer, published }: {
197
- idStore: WebvhIdStore;
198
- signer: AccountLogSigner;
199
- published: PublishedWebvhLog;
200
- }): Promise<{
201
- did: string;
202
- doc: DIDDoc;
203
- log: DIDLog;
204
- }>;
205
194
  //# sourceMappingURL=accountEntry.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"accountEntry.d.ts","sourceRoot":"","sources":["../../src/webvh/accountEntry.ts"],"names":[],"mappings":"AA0DA,OAAO,KAAK,EACV,MAAM,EACN,MAAM,EACN,kBAAkB,EAClB,eAAe,EAChB,MAAM,2BAA2B,CAAA;AAWlC,OAAO,KAAK,EACV,qBAAqB,EACrB,iBAAiB,EACjB,YAAY,EACb,MAAM,eAAe,CAAA;AAMtB,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAA;AACnD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAA;AAEvD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,aAAa,CAAA;AAElD;;;;;;;GAOG;AACH,MAAM,MAAM,gBAAgB,GACxB;IAAE,IAAI,EAAE,UAAU,CAAC;IAAC,UAAU,EAAE,qBAAqB,CAAA;CAAE,GACvD;IAAE,IAAI,EAAE,QAAQ,CAAC;IAAC,UAAU,EAAE,UAAU,CAAA;CAAE,CAAA;AAE9C;;;;;GAKG;AACH,MAAM,MAAM,kBAAkB,GAC5B,gBAAgB,GAAG;IAAE,IAAI,EAAE,WAAW,CAAC;IAAC,UAAU,EAAE,UAAU,CAAA;CAAE,CAAA;AAElE;;;;;GAKG;AACH,MAAM,MAAM,eAAe,GAAG,IAAI,CAChC,YAAY,EACZ,kBAAkB,GAAG,eAAe,GAAG,KAAK,CAC7C,CAAA;AAED;;;;;;;;;;GAUG;AACH,MAAM,WAAW,kBAAmB,SAAQ,IAAI,CAC9C,kBAAkB,EAClB,KAAK,GAAG,QAAQ,GAAG,gBAAgB,CACpC;IACC;;;;;;OAMG;IACH,YAAY,CAAC,EAAE,MAAM,EAAE,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AAgB,CAAC,EAAE,OAAO,CAAA;CAC3B,GAAG,OAAO,CAAC,mBAAmB,CAAC,CAiJ/B"}
@@ -10,17 +10,31 @@
10
10
  * body accepts:
11
11
  *
12
12
  * - **client** -- an enrolled client's did:webvh update keys. The active key
13
- * is derived from the seed, the published log must authorize it, the
14
- * carry-over commitments must hold, and the entry publishes `did.jsonl`
15
- * beside its `did:web` projection (the client invokes as the controller, so
16
- * it may write both).
13
+ * is derived from the seed, the published log must authorize it, and the
14
+ * carry-over commitments must hold.
17
15
  * - **ladder** -- a standing credential's ladder seed, signing through the
18
16
  * record's bridge delegation. The rung is attributed from the published log
19
17
  * ({@link attributeLadderRung}, fail-closed), the acting rung reveals itself
20
- * in the entry it signs, the rung's own hash is kept committed beside the
21
- * build's own commit hashes in `decisions/0007` order, and the entry
22
- * publishes `did.jsonl` alone -- the bridge's whole reach. The projection is
23
- * the ceremony's own pre-entry PUT, or the next visit's ensure.
18
+ * in the entry it signs, and the rung's own hash is kept committed beside
19
+ * the build's own commit hashes in `decisions/0007` order.
20
+ *
21
+ * Neither arm writes the `did:web` projection through the log store. The
22
+ * entry publishes `did.jsonl` through `idStore` on every arm, and `did.json`
23
+ * is written only through a `projectionStore` the caller hands in, which is
24
+ * how a bridge-delegated store (a PUT on `did.jsonl` alone) and a
25
+ * controller-invoking one satisfy the same seam. The projection has two
26
+ * timings and one failure rule each (`projectionTiming`): AFTER the entry,
27
+ * the default, it is a derived cache of the entry that just landed, and a
28
+ * failed PUT throws past the pivot so a re-run republishes it from the
29
+ * idempotent path ({@link concludeUnchangedAccountEntry}); BEFORE the entry,
30
+ * for a ceremony whose entry ends the authority that writes it, a failed PUT
31
+ * warns and the entry publishes anyway, since a projection the next visit's
32
+ * ensure mends is a smaller residue than a struck key the log still lists.
33
+ * Which timing an entry takes is the seam's own decision, from the signer arm
34
+ * and the caller's `removesInventory`: a ladder-signed removal writes before,
35
+ * every other entry after. The idempotent path (`build`'s `concludeUnchanged`)
36
+ * republishes only under the AFTER timing, since under BEFORE the store's
37
+ * authority may already have ended at the entry an earlier run landed.
24
38
  *
25
39
  * A third arm is the seam's alone ({@link AccountEntrySigner}):
26
40
  *
@@ -57,10 +71,27 @@
57
71
  */
58
72
  import { updateDID } from '@interop/did-method-webvh';
59
73
  import { deriveNextKeyHash } from '@interop/did-method-webvh';
74
+ import { log } from '../log.js';
60
75
  import { assertCarryOverCommitments, assertPublishedLogDid, concludeWithPublishedLog, putLogResource, readPublishedLogOrThrow, updateKeyMultibase, updateKeySigner } from './didWebvh.js';
61
76
  import { putDidWebProjection } from './didWebProjection.js';
62
77
  import { assertBuiltOnHeadReached, assertBuiltOnHeadShape } from './builtOnHead.js';
63
78
  import { attributeLadderRung } from './ladder.js';
79
+ /**
80
+ * The timing rule, applied in this one place. `'before'` only for a
81
+ * ladder-signed entry that removes inventory, since that entry may strike the
82
+ * ladder VM or the client the projection store invokes as. Every other entry
83
+ * takes `'after'`, the enrolled arm's included: a client cannot remove
84
+ * itself, so its authority survives what it signs.
85
+ *
86
+ * @param options {object}
87
+ * @param options.signer {AccountEntrySigner} the arm the ceremony acts as
88
+ * @param options.removesInventory {boolean} whether the entry strikes a
89
+ * member of the document's inventory
90
+ * @returns {ProjectionTiming}
91
+ */
92
+ function projectionTimingOf({ signer, removesInventory }) {
93
+ return removesInventory && signer.kind === 'ladder' ? 'before' : 'after';
94
+ }
64
95
  /**
65
96
  * The head an entry leaves standing, assembled from what the entry's own
66
97
  * `updateDID` already resolved plus the publish's validator when an entry was
@@ -111,8 +142,15 @@ export function accountEntryHead({ outcome }) {
111
142
  * `did.jsonl` PUT
112
143
  * @param options.signer {AccountEntrySigner} who signs this entry
113
144
  * @param options.build {function}
114
- * `({ published, rung, state }) => AccountEntryFields | undefined` -- the
115
- * entry's own members, or `undefined` to decline
145
+ * `({ published, rung, state, concludeUnchanged }) => AccountEntryFields |
146
+ * undefined` -- the entry's own members, or `undefined` to decline.
147
+ * `concludeUnchanged()` is the idempotent path's conclusion, bound to this
148
+ * call's projection store and timing: it republishes the projection from
149
+ * the read under the `'after'` timing alone (healing a lag a torn earlier
150
+ * run's thrown post-entry PUT left behind) and writes nothing under
151
+ * `'before'`, since the entry an earlier run landed may have ended the
152
+ * store's authority. A ceremony whose build finds its entry already landed
153
+ * awaits it and declines
116
154
  * @param [options.skip] {function} `(published) => boolean` -- run on the
117
155
  * read, before any attribution; `true` returns `skipped` with nothing
118
156
  * published
@@ -135,24 +173,25 @@ export function accountEntryHead({ outcome }) {
135
173
  * when `did.jsonl` is absent
136
174
  * @param [options.verb] {string} what the caller is doing, for the client
137
175
  * arm's pending-rotation refusal message (e.g. `'revoking a client'`)
138
- * @param [options.logOnly] {boolean} publish `did.jsonl` without its
139
- * `did:web` projection. Defaults per arm: `true` on the ladder arm, whose
140
- * bridge reaches `did.jsonl` alone, and `false` on the enrolled arm, which
141
- * invokes as the controller. A ladder-signed entry written through a
142
- * root-invoking store (the establishment's stage 3) passes `false` to
143
- * republish the projection beside the entry; the committed arm states it,
144
- * since which store it signs through is the caller's
145
- * @param [options.beforePublish] {function} `({ updated }) => Promise<void>`
146
- * -- run on the built entry, AFTER `updateDID` and BEFORE the conditional
147
- * publish. The seam exists for the `did:web` projection: a ladder-signed
148
- * entry writes `did.jsonl` alone, so a ceremony whose entry removes
149
- * inventory has to publish the post-entry projection while the authority it
150
- * is about to end can still write it. A throw propagates and nothing is
151
- * published. It runs once per attempt, so a conflict retry invokes it again
152
- * and it must be idempotent
176
+ * @param [options.projectionStore] {DidWebProjectionStore} a store whose
177
+ * authority reaches `did.json`. Given, the post-entry `did:web` projection
178
+ * (`updateDID`'s own `webDoc`) is PUT through it and through nothing else;
179
+ * omitted, no projection is written on any arm and the next
180
+ * `ensureDidWebProjection` is the mender. An enrolled client passes its
181
+ * controller-invoking store, a transient visit its generation-delegated
182
+ * store, and a caller holding the bridge delegation alone omits it
183
+ * @param [options.removesInventory] {boolean} whether this entry strikes
184
+ * a member of the document's inventory (default `false`). It decides the
185
+ * projection's timing. A ladder-signed removal PUTs the projection after
186
+ * `updateDID` and before the conditional publish, since the entry may end
187
+ * the authority the store invokes under, and a failed PUT is warned and
188
+ * the entry publishes anyway; that write runs once per attempt, so a
189
+ * conflict retry PUTs it again. Every other entry PUTs it after `did.jsonl`
190
+ * lands, and a failed PUT throws
153
191
  * @returns {Promise<AccountEntryOutcome>}
154
192
  */
155
- export async function signAccountEntry({ idStore, signer, build, skip, published: alreadyRead, expectedDid, builtOnHead, missingMessage, verb = 'extending the account log', logOnly = signer.kind === 'ladder', beforePublish }) {
193
+ export async function signAccountEntry({ idStore, signer, build, skip, published: alreadyRead, expectedDid, builtOnHead, missingMessage, verb = 'extending the account log', projectionStore, removesInventory = false }) {
194
+ const projectionTiming = projectionTimingOf({ signer, removesInventory });
156
195
  // A resume skips nothing on the strength of a marker it cannot compare:
157
196
  // refused before any read, rather than resuming unguarded.
158
197
  if (builtOnHead !== undefined) {
@@ -194,7 +233,15 @@ export async function signAccountEntry({ idStore, signer, build, skip, published
194
233
  const ladderParts = attributed === undefined
195
234
  ? {}
196
235
  : { rung: attributed.rung, rungHash: rungHash, state: attributed.state };
197
- const entry = await build({ published, ...ladderParts });
236
+ const entry = await build({
237
+ published,
238
+ ...ladderParts,
239
+ concludeUnchanged: () => concludeUnchangedAccountEntry({
240
+ projectionStore,
241
+ projectionTiming,
242
+ published
243
+ })
244
+ });
198
245
  if (!entry) {
199
246
  return { skipped: false, published, ...ladderParts };
200
247
  }
@@ -262,12 +309,12 @@ export async function signAccountEntry({ idStore, signer, build, skip, published
262
309
  updateKeys: signedUpdateKeys,
263
310
  nextKeyHashes: signedHashes
264
311
  });
265
- await beforePublish?.({ updated });
266
312
  const written = await publishAccountEntry({
267
313
  idStore,
268
314
  updated,
269
315
  ifMatch: published.etag,
270
- logOnly
316
+ projectionStore,
317
+ projectionTiming
271
318
  });
272
319
  return {
273
320
  skipped: false,
@@ -280,56 +327,87 @@ export async function signAccountEntry({ idStore, signer, build, skip, published
280
327
  /**
281
328
  * The publish tail: `did.jsonl` under the caller's compare-and-swap token
282
329
  * (which advances the store's pin, for both arms, so a host rolling the log
283
- * back straight afterwards is refused on the next read), then its `did:web`
284
- * projection where the signer may write one.
330
+ * back straight afterwards is refused on the next read), with the `did:web`
331
+ * projection PUT through the projection store alone, before or after the
332
+ * log per the timing. The log store is never asked for the projection.
333
+ *
334
+ * The two failure rules live here and nowhere else. After the pivot the PUT
335
+ * throws: the entry stands, and the ceremony's re-run republishes the
336
+ * projection through its idempotent path. Before the pivot the PUT is
337
+ * best-effort, and the direction is deliberate: a projection published before
338
+ * an entry that then fails under-lists a key the log still carries, which a
339
+ * `did:web` verifier reads as less authority rather than more, while
340
+ * withholding the entry over a failed projection would leave the struck key
341
+ * standing in the log itself. The residue either way is a projection the next
342
+ * `ensureDidWebProjection` mends.
285
343
  *
286
344
  * @param options {object}
287
345
  * @param options.idStore {AccountLogStore}
288
346
  * @param options.updated {object} the `updateDID` result
289
347
  * @param [options.ifMatch] {string} the ETag of the read this entry was
290
348
  * built on
291
- * @param options.logOnly {boolean} skip the projection PUT
349
+ * @param [options.projectionStore] {DidWebProjectionStore} the one store the
350
+ * projection is written through; omitted, no projection is written
351
+ * @param options.projectionTiming {ProjectionTiming}
292
352
  * @returns {Promise<{ etag?: string }>} the LOG's new validator
293
353
  */
294
- async function publishAccountEntry({ idStore, updated, ifMatch, logOnly }) {
295
- if (!logOnly && !updated.webDoc) {
296
- throw new Error('did:webvh: updateDID returned no webDoc despite the did:web alsoKnownAs.');
354
+ async function publishAccountEntry({ idStore, updated, ifMatch, projectionStore, projectionTiming }) {
355
+ // One projection write, shared by both timings; only the failure rule
356
+ // around it differs.
357
+ const putProjection = async (store) => {
358
+ if (!updated.webDoc) {
359
+ // Every entry is built with `alsoKnownAsWeb`, so this is a defect
360
+ // rather than a state.
361
+ throw new Error('did:webvh: updateDID returned no webDoc despite the did:web ' +
362
+ 'alsoKnownAs.');
363
+ }
364
+ await putDidWebProjection({ store, webDoc: updated.webDoc });
365
+ };
366
+ if (projectionStore !== undefined && projectionTiming === 'before') {
367
+ try {
368
+ await putProjection(projectionStore);
369
+ }
370
+ catch (err) {
371
+ log.warn('did:webvh: the pre-entry did:web projection PUT failed.', {
372
+ err
373
+ });
374
+ }
297
375
  }
298
376
  const written = await putLogResource({
299
377
  store: idStore,
300
378
  log: updated.log,
301
379
  ...(ifMatch !== undefined ? { ifMatch } : {})
302
380
  });
303
- if (!logOnly) {
304
- await putDidWebProjection({
305
- store: idStore,
306
- webDoc: updated.webDoc
307
- });
381
+ if (projectionStore !== undefined && projectionTiming === 'after') {
382
+ await putProjection(projectionStore);
308
383
  }
309
384
  return written;
310
385
  }
311
386
  /**
312
387
  * The head a ceremony concludes on when its entry turns out to be
313
- * unnecessary -- the client is already enrolled, the removal already landed.
314
- * There is nothing to publish either way; what differs is the `did:web`
315
- * projection. The enrolled arm invokes as the account's controller, so it
316
- * republishes the projection and heals a lag a torn earlier run of the same
317
- * ceremony left behind. The ladder arm's bridge reaches `did.jsonl` alone, so
318
- * it takes the read verbatim and leaves the projection to
319
- * `ensureDidWebProjection`.
388
+ * unnecessary -- the client is already enrolled, the removal already landed,
389
+ * the pointer already set. `build` reaches it as `concludeUnchanged`, bound
390
+ * to the seam call's own store and timing. There is nothing to publish either
391
+ * way; what differs is the `did:web` projection. The projection is republished
392
+ * from the resolved log through the store under the `'after'` timing, which
393
+ * heals a lag a torn earlier run of the same ceremony left behind (a
394
+ * post-entry PUT that threw after the log landed). Under the `'before'`
395
+ * timing nothing is written: the entry an earlier run landed may have ended
396
+ * the authority the store invokes under, so the PUT could only be refused.
397
+ * Without a store the read is taken verbatim. Either way the projection is
398
+ * otherwise left to `ensureDidWebProjection`.
320
399
  *
321
400
  * @param options {object}
322
- * @param options.idStore {WebvhIdStore}
323
- * @param options.signer {AccountLogSigner} the arm the ceremony acts as
401
+ * @param [options.projectionStore] {DidWebProjectionStore} the store the
402
+ * projection is republished through; omitted, nothing is written
403
+ * @param options.projectionTiming {ProjectionTiming} the timing the entry
404
+ * would have taken; `'before'` writes nothing here
324
405
  * @param options.published {PublishedWebvhLog} the read the build stood on
325
406
  * @returns {Promise<{ did: string, doc: DIDDoc, log: DIDLog }>}
326
407
  */
327
- export async function concludeUnchangedAccountEntry({ idStore, signer, published }) {
328
- if (signer.kind === 'enrolled') {
329
- return {
330
- ...(await concludeWithPublishedLog({ idStore, published })),
331
- log: published.log
332
- };
408
+ async function concludeUnchangedAccountEntry({ projectionStore, projectionTiming, published }) {
409
+ if (projectionStore !== undefined && projectionTiming === 'after') {
410
+ await concludeWithPublishedLog({ idStore: projectionStore, published });
333
411
  }
334
412
  return { did: published.did, doc: published.doc, log: published.log };
335
413
  }
@@ -1 +1 @@
1
- {"version":3,"file":"accountEntry.js","sourceRoot":"","sources":["../../src/webvh/accountEntry.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqDG;AACH,OAAO,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAA;AAOrD,OAAO,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAA;AAC7D,OAAO,EACL,0BAA0B,EAC1B,qBAAqB,EACrB,wBAAwB,EACxB,cAAc,EACd,uBAAuB,EACvB,kBAAkB,EAClB,eAAe,EAChB,MAAM,eAAe,CAAA;AAMtB,OAAO,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAA;AAC3D,OAAO,EACL,wBAAwB,EACxB,sBAAsB,EACvB,MAAM,kBAAkB,CAAA;AAGzB,OAAO,EAAE,mBAAmB,EAAE,MAAM,aAAa,CAAA;AAwFjD;;;;;;;;;;;;GAYG;AACH,MAAM,UAAU,gBAAgB,CAAC,EAC/B,OAAO,EAGR;IACC,MAAM,EAAE,OAAO,EAAE,GAAG,OAAO,CAAA;IAC3B,IAAI,CAAC,OAAO,EAAE,CAAC;QACb,OAAO,OAAO,CAAC,SAAS,CAAA;IAC1B,CAAC;IACD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and-publish seam
6
- * ({@link DelegatedWebvhLogStore}) served through a pre-minted delegation
6
+ * ({@link AccountLogStore}) served through a pre-minted delegation
7
7
  * rather than controller authority. Two credential-held bridges write
8
8
  * through it: the unlock record's `did.jsonl` bridge into the account log
9
9
  * (world-readable, so its reads stay unauthenticated), and the client
@@ -35,14 +35,7 @@ import type { IZcap } from '@interop/data-integrity-core';
35
35
  import type { ZcapClient } from '@interop/ezcap';
36
36
  import type { ResourceLogPinStore } from '@interop/vh-resource-log';
37
37
  import { type ServiceDescription } from '@interop/was-client';
38
- import type { WebvhIdStore } from './didWebvh.js';
39
- /**
40
- * The narrow store shape a delegated bridge serves: the log read plus the
41
- * conditional `did.jsonl` publish. A subset of {@link WebvhIdStore}, so it
42
- * satisfies the ceremony seams (`UnlockLogStore`, `RecoveryLogStore`, and the
43
- * annex ceremonies) structurally.
44
- */
45
- export type DelegatedWebvhLogStore = Pick<WebvhIdStore, 'getIdResourceRaw' | 'putIdResource' | 'pin'>;
38
+ import type { AccountLogStore } from './accountEntry.js';
46
39
  /**
47
40
  * Builds a delegated log store over one collection of one Space.
48
41
  *
@@ -69,7 +62,7 @@ export type DelegatedWebvhLogStore = Pick<WebvhIdStore, 'getIdResourceRaw' | 'pu
69
62
  * @param [options.serviceDescription] {ServiceDescription} the server's
70
63
  * service description a client the caller already holds discovered
71
64
  * (`(await was.service()).description`), so this one skips discovery
72
- * @returns {DelegatedWebvhLogStore}
65
+ * @returns {AccountLogStore}
73
66
  */
74
67
  export declare function delegatedWebvhLogStore({ host, spaceId, collectionId, delegation, zcapClient, pinStore, serviceDescription }: {
75
68
  host: string;
@@ -79,5 +72,5 @@ export declare function delegatedWebvhLogStore({ host, spaceId, collectionId, de
79
72
  zcapClient: ZcapClient;
80
73
  pinStore: ResourceLogPinStore;
81
74
  serviceDescription?: ServiceDescription;
82
- }): DelegatedWebvhLogStore;
75
+ }): AccountLogStore;
83
76
  //# sourceMappingURL=delegatedLogStore.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"delegatedLogStore.d.ts","sourceRoot":"","sources":["../../src/webvh/delegatedLogStore.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AACH,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,8BAA8B,CAAA;AACzD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAA;AAChD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAA;AACnE,OAAO,EAGL,KAAK,kBAAkB,EACxB,MAAM,qBAAqB,CAAA;AAG5B,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,eAAe,CAAA;AAGjD;;;;;GAKG;AACH,MAAM,MAAM,sBAAsB,GAAG,IAAI,CACvC,YAAY,EACZ,kBAAkB,GAAG,eAAe,GAAG,KAAK,CAC7C,CAAA;AAkCD;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,wBAAgB,sBAAsB,CAAC,EACrC,IAAI,EACJ,OAAO,EACP,YAAY,EACZ,UAAU,EACV,UAAU,EACV,QAAQ,EACR,kBAAkB,EACnB,EAAE;IACD,IAAI,EAAE,MAAM,CAAA;IACZ,OAAO,EAAE,MAAM,CAAA;IACf,YAAY,EAAE,MAAM,CAAA;IACpB,UAAU,EAAE,KAAK,CAAA;IACjB,UAAU,EAAE,UAAU,CAAA;IACtB,QAAQ,EAAE,mBAAmB,CAAA;IAC7B,kBAAkB,CAAC,EAAE,kBAAkB,CAAA;CACxC,GAAG,sBAAsB,CAwGzB"}
1
+ {"version":3,"file":"delegatedLogStore.d.ts","sourceRoot":"","sources":["../../src/webvh/delegatedLogStore.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AACH,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,8BAA8B,CAAA;AACzD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAA;AAChD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAA;AACnE,OAAO,EAGL,KAAK,kBAAkB,EACxB,MAAM,qBAAqB,CAAA;AAG5B,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAA;AAmCxD;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,wBAAgB,sBAAsB,CAAC,EACrC,IAAI,EACJ,OAAO,EACP,YAAY,EACZ,UAAU,EACV,UAAU,EACV,QAAQ,EACR,kBAAkB,EACnB,EAAE;IACD,IAAI,EAAE,MAAM,CAAA;IACZ,OAAO,EAAE,MAAM,CAAA;IACf,YAAY,EAAE,MAAM,CAAA;IACpB,UAAU,EAAE,KAAK,CAAA;IACjB,UAAU,EAAE,UAAU,CAAA;IACtB,QAAQ,EAAE,mBAAmB,CAAA;IAC7B,kBAAkB,CAAC,EAAE,kBAAkB,CAAA;CACxC,GAAG,eAAe,CAwGlB"}
@@ -50,7 +50,7 @@ function collectionIsPublic({ collectionId }) {
50
50
  * @param [options.serviceDescription] {ServiceDescription} the server's
51
51
  * service description a client the caller already holds discovered
52
52
  * (`(await was.service()).description`), so this one skips discovery
53
- * @returns {DelegatedWebvhLogStore}
53
+ * @returns {AccountLogStore}
54
54
  */
55
55
  export function delegatedWebvhLogStore({ host, spaceId, collectionId, delegation, zcapClient, pinStore, serviceDescription }) {
56
56
  const publicRead = collectionIsPublic({ collectionId });
@@ -1 +1 @@
1
- {"version":3,"file":"delegatedLogStore.js","sourceRoot":"","sources":["../../src/webvh/delegatedLogStore.ts"],"names":[],"mappings":"AAoCA,OAAO,EACL,uBAAuB,EACvB,SAAS,EAEV,MAAM,qBAAqB,CAAA;AAC5B,OAAO,EAAE,YAAY,EAAE,KAAK,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAA;AAC1E,OAAO,EAAE,6BAA6B,EAAE,MAAM,yBAAyB,CAAA;AAEvE,OAAO,EAAE,gBAAgB,EAAE,MAAM,gBAAgB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