@interop/wallet-core 0.68.0 → 0.70.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 (261) hide show
  1. package/README.md +31 -41
  2. package/dist/clientAnnex/credentialAnchoredGenesis.d.ts +12 -1
  3. package/dist/clientAnnex/credentialAnchoredGenesis.d.ts.map +1 -1
  4. package/dist/clientAnnex/credentialAnchoredGenesis.js +9 -2
  5. package/dist/clientAnnex/credentialAnchoredGenesis.js.map +1 -1
  6. package/dist/clientAnnex/establish.d.ts +10 -0
  7. package/dist/clientAnnex/establish.d.ts.map +1 -1
  8. package/dist/clientAnnex/establish.js +14 -2
  9. package/dist/clientAnnex/establish.js.map +1 -1
  10. package/dist/clientAnnex/ladder.d.ts +103 -57
  11. package/dist/clientAnnex/ladder.d.ts.map +1 -1
  12. package/dist/clientAnnex/ladder.js +254 -335
  13. package/dist/clientAnnex/ladder.js.map +1 -1
  14. package/dist/clientAnnex/ladderAnchored.d.ts.map +1 -1
  15. package/dist/clientAnnex/ladderAnchored.js +10 -5
  16. package/dist/clientAnnex/ladderAnchored.js.map +1 -1
  17. package/dist/clientAnnex/mend.d.ts +19 -4
  18. package/dist/clientAnnex/mend.d.ts.map +1 -1
  19. package/dist/clientAnnex/mend.js +83 -35
  20. package/dist/clientAnnex/mend.js.map +1 -1
  21. package/dist/clientAnnex/recoveryLadderAnchored.d.ts +3 -15
  22. package/dist/clientAnnex/recoveryLadderAnchored.d.ts.map +1 -1
  23. package/dist/clientAnnex/recoveryLadderAnchored.js +22 -3
  24. package/dist/clientAnnex/recoveryLadderAnchored.js.map +1 -1
  25. package/dist/clientAnnex/rosterDeliveredEpochs.d.ts +13 -14
  26. package/dist/clientAnnex/rosterDeliveredEpochs.d.ts.map +1 -1
  27. package/dist/clientAnnex/rosterDeliveredEpochs.js +12 -12
  28. package/dist/clientAnnex/rosterDeliveredEpochs.js.map +1 -1
  29. package/dist/clients/grantState.d.ts +67 -0
  30. package/dist/clients/grantState.d.ts.map +1 -0
  31. package/dist/clients/grantState.js +72 -0
  32. package/dist/clients/grantState.js.map +1 -0
  33. package/dist/clients/index.d.ts +7 -0
  34. package/dist/clients/index.d.ts.map +1 -1
  35. package/dist/clients/index.js +6 -0
  36. package/dist/clients/index.js.map +1 -1
  37. package/dist/descriptors/index.d.ts +21 -46
  38. package/dist/descriptors/index.d.ts.map +1 -1
  39. package/dist/descriptors/index.js +21 -45
  40. package/dist/descriptors/index.js.map +1 -1
  41. package/dist/descriptors/logSource.d.ts +45 -56
  42. package/dist/descriptors/logSource.d.ts.map +1 -1
  43. package/dist/descriptors/logSource.js +64 -74
  44. package/dist/descriptors/logSource.js.map +1 -1
  45. package/dist/enrollment/connectCode.d.ts +4 -3
  46. package/dist/enrollment/connectCode.d.ts.map +1 -1
  47. package/dist/enrollment/connectCode.js +4 -3
  48. package/dist/enrollment/connectCode.js.map +1 -1
  49. package/dist/enrollment/index.d.ts +2 -2
  50. package/dist/enrollment/index.js +2 -2
  51. package/dist/enrollment/onboardingInvite.d.ts +1 -1
  52. package/dist/enrollment/onboardingInvite.js +1 -1
  53. package/dist/enrollment/onboardingResponse.js +1 -1
  54. package/dist/genesis/accountGenesis.d.ts +13 -1
  55. package/dist/genesis/accountGenesis.d.ts.map +1 -1
  56. package/dist/genesis/accountGenesis.js +11 -2
  57. package/dist/genesis/accountGenesis.js.map +1 -1
  58. package/dist/identity/index.d.ts +1 -1
  59. package/dist/identity/index.js +1 -1
  60. package/dist/index.d.ts +4 -8
  61. package/dist/index.d.ts.map +1 -1
  62. package/dist/index.js +4 -8
  63. package/dist/index.js.map +1 -1
  64. package/dist/keyring/kdf.d.ts +33 -19
  65. package/dist/keyring/kdf.d.ts.map +1 -1
  66. package/dist/keyring/kdf.js +36 -25
  67. package/dist/keyring/kdf.js.map +1 -1
  68. package/dist/keys/collectionLogStore.d.ts +73 -0
  69. package/dist/keys/collectionLogStore.d.ts.map +1 -0
  70. package/dist/keys/collectionLogStore.js +60 -0
  71. package/dist/keys/collectionLogStore.js.map +1 -0
  72. package/dist/keys/index.d.ts +18 -6
  73. package/dist/keys/index.d.ts.map +1 -1
  74. package/dist/keys/index.js +18 -6
  75. package/dist/keys/index.js.map +1 -1
  76. package/dist/keys/rosterLogStore.d.ts +44 -6
  77. package/dist/keys/rosterLogStore.d.ts.map +1 -1
  78. package/dist/keys/rosterLogStore.js +51 -238
  79. package/dist/keys/rosterLogStore.js.map +1 -1
  80. package/dist/keys/rosterStore.d.ts.map +1 -1
  81. package/dist/keys/rosterStore.js +2 -1
  82. package/dist/keys/rosterStore.js.map +1 -1
  83. package/dist/keys/spaceEpochs.d.ts +67 -34
  84. package/dist/keys/spaceEpochs.d.ts.map +1 -1
  85. package/dist/keys/spaceEpochs.js +80 -30
  86. package/dist/keys/spaceEpochs.js.map +1 -1
  87. package/dist/keys/userKeyCascade.d.ts +26 -1
  88. package/dist/keys/userKeyCascade.d.ts.map +1 -1
  89. package/dist/keys/userKeyCascade.js +29 -2
  90. package/dist/keys/userKeyCascade.js.map +1 -1
  91. package/dist/keys/userKeyRoster.d.ts +5 -0
  92. package/dist/keys/userKeyRoster.d.ts.map +1 -1
  93. package/dist/keys/userKeyRoster.js +5 -0
  94. package/dist/keys/userKeyRoster.js.map +1 -1
  95. package/dist/keys/userKeyRosterCascade.d.ts +54 -16
  96. package/dist/keys/userKeyRosterCascade.d.ts.map +1 -1
  97. package/dist/keys/userKeyRosterCascade.js +50 -22
  98. package/dist/keys/userKeyRosterCascade.js.map +1 -1
  99. package/dist/recovery/continuation.d.ts +5 -4
  100. package/dist/recovery/continuation.d.ts.map +1 -1
  101. package/dist/recovery/continuation.js +14 -13
  102. package/dist/recovery/continuation.js.map +1 -1
  103. package/dist/resourceLog/controller.d.ts +18 -6
  104. package/dist/resourceLog/controller.d.ts.map +1 -1
  105. package/dist/resourceLog/controller.js +5 -3
  106. package/dist/resourceLog/controller.js.map +1 -1
  107. package/dist/resourceLog/document.d.ts +10 -2
  108. package/dist/resourceLog/document.d.ts.map +1 -1
  109. package/dist/resourceLog/document.js +1 -2
  110. package/dist/resourceLog/document.js.map +1 -1
  111. package/dist/resourceLog/errors.d.ts +17 -43
  112. package/dist/resourceLog/errors.d.ts.map +1 -1
  113. package/dist/resourceLog/errors.js +17 -50
  114. package/dist/resourceLog/errors.js.map +1 -1
  115. package/dist/resourceLog/index.d.ts +4 -1
  116. package/dist/resourceLog/index.d.ts.map +1 -1
  117. package/dist/resourceLog/index.js +4 -1
  118. package/dist/resourceLog/index.js.map +1 -1
  119. package/dist/resourceLog/logClass.d.ts +69 -0
  120. package/dist/resourceLog/logClass.d.ts.map +1 -0
  121. package/dist/resourceLog/logClass.js +43 -0
  122. package/dist/resourceLog/logClass.js.map +1 -0
  123. package/dist/space/collections.d.ts +22 -2
  124. package/dist/space/collections.d.ts.map +1 -1
  125. package/dist/space/collections.js +18 -0
  126. package/dist/space/collections.js.map +1 -1
  127. package/dist/space/index.d.ts +8 -5
  128. package/dist/space/index.d.ts.map +1 -1
  129. package/dist/space/index.js +8 -5
  130. package/dist/space/index.js.map +1 -1
  131. package/dist/space/provisioning.d.ts +16 -6
  132. package/dist/space/provisioning.d.ts.map +1 -1
  133. package/dist/space/provisioning.js +11 -7
  134. package/dist/space/provisioning.js.map +1 -1
  135. package/dist/space/wasLink.d.ts +13 -2
  136. package/dist/space/wasLink.d.ts.map +1 -1
  137. package/dist/space/wasLink.js +28 -2
  138. package/dist/space/wasLink.js.map +1 -1
  139. package/dist/sync/engine.d.ts +4 -2
  140. package/dist/sync/engine.d.ts.map +1 -1
  141. package/dist/sync/engine.js.map +1 -1
  142. package/dist/sync/index.d.ts +9 -6
  143. package/dist/sync/index.d.ts.map +1 -1
  144. package/dist/sync/index.js +8 -5
  145. package/dist/sync/index.js.map +1 -1
  146. package/dist/sync/push.d.ts +0 -29
  147. package/dist/sync/push.d.ts.map +1 -1
  148. package/dist/sync/push.js +30 -28
  149. package/dist/sync/push.js.map +1 -1
  150. package/dist/sync/types.d.ts +39 -21
  151. package/dist/sync/types.d.ts.map +1 -1
  152. package/dist/sync/types.js +13 -7
  153. package/dist/sync/types.js.map +1 -1
  154. package/dist/unlock/index.d.ts +1 -1
  155. package/dist/unlock/index.d.ts.map +1 -1
  156. package/dist/unlock/index.js.map +1 -1
  157. package/dist/unlock/retire.d.ts +8 -1
  158. package/dist/unlock/retire.d.ts.map +1 -1
  159. package/dist/unlock/retire.js +8 -1
  160. package/dist/unlock/retire.js.map +1 -1
  161. package/dist/unlock/standingWebvh.d.ts +81 -19
  162. package/dist/unlock/standingWebvh.d.ts.map +1 -1
  163. package/dist/unlock/standingWebvh.js +170 -30
  164. package/dist/unlock/standingWebvh.js.map +1 -1
  165. package/dist/webvh/did.d.ts +2 -4
  166. package/dist/webvh/did.d.ts.map +1 -1
  167. package/dist/webvh/did.js +2 -4
  168. package/dist/webvh/did.js.map +1 -1
  169. package/dist/webvh/didWebvh.d.ts +3 -2
  170. package/dist/webvh/didWebvh.d.ts.map +1 -1
  171. package/dist/webvh/didWebvh.js +2 -1
  172. package/dist/webvh/didWebvh.js.map +1 -1
  173. package/dist/webvh/revokeClient.d.ts +13 -7
  174. package/dist/webvh/revokeClient.d.ts.map +1 -1
  175. package/dist/webvh/revokeClient.js +14 -7
  176. package/dist/webvh/revokeClient.js.map +1 -1
  177. package/package.json +4 -19
  178. package/dist/descriptors/acquire.d.ts +0 -122
  179. package/dist/descriptors/acquire.d.ts.map +0 -1
  180. package/dist/descriptors/acquire.js +0 -100
  181. package/dist/descriptors/acquire.js.map +0 -1
  182. package/dist/descriptors/cipher.d.ts +0 -71
  183. package/dist/descriptors/cipher.d.ts.map +0 -1
  184. package/dist/descriptors/cipher.js +0 -109
  185. package/dist/descriptors/cipher.js.map +0 -1
  186. package/dist/descriptors/errors.d.ts +0 -44
  187. package/dist/descriptors/errors.d.ts.map +0 -1
  188. package/dist/descriptors/errors.js +0 -46
  189. package/dist/descriptors/errors.js.map +0 -1
  190. package/dist/descriptors/refresh.d.ts +0 -62
  191. package/dist/descriptors/refresh.d.ts.map +0 -1
  192. package/dist/descriptors/refresh.js +0 -69
  193. package/dist/descriptors/refresh.js.map +0 -1
  194. package/dist/request/appKey.d.ts +0 -295
  195. package/dist/request/appKey.d.ts.map +0 -1
  196. package/dist/request/appKey.js +0 -516
  197. package/dist/request/appKey.js.map +0 -1
  198. package/dist/request/capabilityRequest.d.ts +0 -41
  199. package/dist/request/capabilityRequest.d.ts.map +0 -1
  200. package/dist/request/capabilityRequest.js +0 -46
  201. package/dist/request/capabilityRequest.js.map +0 -1
  202. package/dist/request/classify.d.ts +0 -226
  203. package/dist/request/classify.d.ts.map +0 -1
  204. package/dist/request/classify.js +0 -416
  205. package/dist/request/classify.js.map +0 -1
  206. package/dist/request/composeVp.d.ts +0 -52
  207. package/dist/request/composeVp.d.ts.map +0 -1
  208. package/dist/request/composeVp.js +0 -176
  209. package/dist/request/composeVp.js.map +0 -1
  210. package/dist/request/ephemeralExchange.d.ts +0 -100
  211. package/dist/request/ephemeralExchange.d.ts.map +0 -1
  212. package/dist/request/ephemeralExchange.js +0 -230
  213. package/dist/request/ephemeralExchange.js.map +0 -1
  214. package/dist/request/exchangeClient.d.ts +0 -142
  215. package/dist/request/exchangeClient.d.ts.map +0 -1
  216. package/dist/request/exchangeClient.js +0 -241
  217. package/dist/request/exchangeClient.js.map +0 -1
  218. package/dist/request/index.d.ts +0 -59
  219. package/dist/request/index.d.ts.map +0 -1
  220. package/dist/request/index.js +0 -59
  221. package/dist/request/index.js.map +0 -1
  222. package/dist/request/interactionRequest.d.ts +0 -23
  223. package/dist/request/interactionRequest.d.ts.map +0 -1
  224. package/dist/request/interactionRequest.js +0 -46
  225. package/dist/request/interactionRequest.js.map +0 -1
  226. package/dist/request/interactionUrl.d.ts +0 -42
  227. package/dist/request/interactionUrl.d.ts.map +0 -1
  228. package/dist/request/interactionUrl.js +0 -104
  229. package/dist/request/interactionUrl.js.map +0 -1
  230. package/dist/request/matching.d.ts +0 -95
  231. package/dist/request/matching.d.ts.map +0 -1
  232. package/dist/request/matching.js +0 -205
  233. package/dist/request/matching.js.map +0 -1
  234. package/dist/request/onboarding.d.ts +0 -94
  235. package/dist/request/onboarding.d.ts.map +0 -1
  236. package/dist/request/onboarding.js +0 -167
  237. package/dist/request/onboarding.js.map +0 -1
  238. package/dist/request/parse.d.ts +0 -63
  239. package/dist/request/parse.d.ts.map +0 -1
  240. package/dist/request/parse.js +0 -153
  241. package/dist/request/parse.js.map +0 -1
  242. package/dist/request/presentationSuite.d.ts +0 -71
  243. package/dist/request/presentationSuite.d.ts.map +0 -1
  244. package/dist/request/presentationSuite.js +0 -143
  245. package/dist/request/presentationSuite.js.map +0 -1
  246. package/dist/request/processRequest.d.ts +0 -45
  247. package/dist/request/processRequest.d.ts.map +0 -1
  248. package/dist/request/processRequest.js +0 -147
  249. package/dist/request/processRequest.js.map +0 -1
  250. package/dist/request/queryPredicates.d.ts +0 -98
  251. package/dist/request/queryPredicates.d.ts.map +0 -1
  252. package/dist/request/queryPredicates.js +0 -107
  253. package/dist/request/queryPredicates.js.map +0 -1
  254. package/dist/request/types.d.ts +0 -257
  255. package/dist/request/types.d.ts.map +0 -1
  256. package/dist/request/types.js +0 -2
  257. package/dist/request/types.js.map +0 -1
  258. package/dist/request/walletInput.d.ts +0 -93
  259. package/dist/request/walletInput.d.ts.map +0 -1
  260. package/dist/request/walletInput.js +0 -179
  261. package/dist/request/walletInput.js.map +0 -1
@@ -5,13 +5,19 @@
5
5
  * Types for the WAS replication engine core.
6
6
  *
7
7
  * The wire contract and port seam (`Json`, `SyncCheckpoint`, `WireDoc`,
8
- * `MasterState`, `WasSyncPort`, `DocCipher`, and the `WasSyncConflictError` /
9
- * `WasSyncNotFoundError` / `UnknownEpochError` signals) come from
10
- * `@interop/was-client/sync` and are re-exported here so a single import gives
11
- * a consumer both the wire types and the replica-side seams. The predicates
12
- * that CLASSIFY those signals ship from `@interop/was-client/sync` too, beside
13
- * the classes that assign the names they match; `push.ts` and `remint.ts`
14
- * import them from there.
8
+ * `MasterState`, `WriteAck`, `WasSyncPort`, `DocCipher`, and the
9
+ * `WasSyncConflictError` / `WasSyncNotFoundError` / `UnknownEpochError`
10
+ * signals) come from `@interop/was-client/sync` and are re-exported here so a
11
+ * single import gives a consumer both the wire types and the replica-side
12
+ * seams. The predicates that CLASSIFY those signals ship from
13
+ * `@interop/was-client/sync` too, beside the classes that assign the names
14
+ * they match; `push.ts` and `remint.ts` import them from there.
15
+ *
16
+ * The server's `ETag` is opaque (it embeds a per-record generation marker
17
+ * ahead of the content `version`, so it can no longer be rebuilt from a bare
18
+ * revision number). `MasterState.etag` / `WireDoc.etag` / `WriteAck.etag`
19
+ * carry it verbatim; a store that persists synced rows MUST keep the string
20
+ * alongside `version` and echo it back as a later write's `ifMatch`.
15
21
  *
16
22
  * The local-persistence seam (`SyncStore`, `SyncedRow`, `ProjectionAction`,
17
23
  * `ResolveConflict`) is the replica's side of the contract: it stands in for a
@@ -25,13 +31,16 @@
25
31
  * Native, against a fake port and an in-memory store.
26
32
  */
27
33
  export { UnknownEpochError, WasSyncConflictError, WasSyncNotFoundError } from '@interop/was-client/sync';
28
- export type { Json, SyncCheckpoint, WireDoc, MasterState, WasSyncPort, DocCipher } from '@interop/was-client/sync';
34
+ export type { Json, SyncCheckpoint, WireDoc, MasterState, WriteAck, WasSyncPort, DocCipher } from '@interop/was-client/sync';
29
35
  import type { Json, MasterState, SyncCheckpoint, WireDoc } from '@interop/was-client/sync';
30
36
  /**
31
37
  * A dirty local synced-docs row awaiting push. `data` is the stored body (the
32
38
  * EDV envelope on an encrypted collection, or the plaintext JSON on a plaintext
33
39
  * one), `null` for a tombstone. `version` is the last server-acked content
34
- * revision (`0` = never acked, so a create).
40
+ * revision (`0` = never acked, so a create); `etag` is the opaque `ETag`
41
+ * validator that revision was acked (or pulled) under, echoed back verbatim as
42
+ * a later write's `ifMatch` -- absent when the row has never been acked, or
43
+ * against a backend that does not version resources.
35
44
  *
36
45
  * `revision` is the store's own local revision token for the row: any opaque
37
46
  * value the store bumps on EVERY local write (a counter, a hash of the stored
@@ -44,6 +53,7 @@ import type { Json, MasterState, SyncCheckpoint, WireDoc } from '@interop/was-cl
44
53
  export interface SyncedRow {
45
54
  id: string;
46
55
  version: number;
56
+ etag?: string;
47
57
  updatedAt: string;
48
58
  deleted: boolean;
49
59
  data: Json | null;
@@ -101,7 +111,10 @@ export interface SyncStore {
101
111
  * Applies one pulled page in a single exclusive transaction: reconcile each
102
112
  * document against the local row (per the pull-apply conflict table), write
103
113
  * the matching projection action, and advance the checkpoint. `projections`
104
- * is keyed by document id.
114
+ * is keyed by document id. Each document's `etag` (and `metaEtag`, on a
115
+ * collection that syncs metadata) MUST be recorded onto its row alongside
116
+ * `version` -- it is the validator a later local write echoes back as
117
+ * `ifMatch`.
105
118
  */
106
119
  applyPulledPage(options: {
107
120
  documents: WireDoc[];
@@ -109,30 +122,33 @@ export interface SyncStore {
109
122
  projections: Map<string, ProjectionAction>;
110
123
  }): Promise<void>;
111
124
  /**
112
- * Marks a pushed create/update as acked: record the server `version` when
113
- * provided (the `204` ETag), and clear dirty -- but ONLY if the row's current
125
+ * Marks a pushed create/update as acked: record the server `version` and the
126
+ * opaque `etag` validator it lives behind (the write's {@link WriteAck}) when
127
+ * provided, and clear dirty -- but ONLY if the row's current
114
128
  * {@link SyncedRow.revision} still equals the `revision` that was pushed. A
115
129
  * local write that landed while the write was in flight leaves a newer token,
116
- * and that row MUST stay dirty (with the acked `version` still recorded, so
117
- * the re-push's `If-Match` is current) so the rerun cycle pushes it. When
118
- * `revision` is `undefined` -- a store that does not track a revision token --
119
- * dirty is cleared unconditionally.
130
+ * and that row MUST stay dirty (with the acked `version` / `etag` still
131
+ * recorded, so the re-push's `ifMatch` is current) so the rerun cycle pushes
132
+ * it. When `revision` is `undefined` -- a store that does not track a
133
+ * revision token -- dirty is cleared unconditionally.
120
134
  */
121
135
  markPushed(options: {
122
136
  id: string;
123
137
  version?: number;
138
+ etag?: string;
124
139
  revision?: string | number;
125
140
  }): Promise<void>;
126
141
  /**
127
142
  * Marks a pushed delete as settled: keep the tombstone, record the server
128
- * `version` when provided, and clear dirty under the same revision condition
129
- * as {@link SyncStore.markPushed} -- a row rewritten locally mid-flight stays
130
- * dirty and keeps its local state rather than being forced to a clean
131
- * tombstone.
143
+ * `version` / `etag` when provided, and clear dirty under the same revision
144
+ * condition as {@link SyncStore.markPushed} -- a row rewritten locally
145
+ * mid-flight stays dirty and keeps its local state rather than being forced
146
+ * to a clean tombstone.
132
147
  */
133
148
  markDeletedPushed(options: {
134
149
  id: string;
135
150
  version?: number;
151
+ etag?: string;
136
152
  revision?: string | number;
137
153
  }): Promise<void>;
138
154
  /**
@@ -140,7 +156,9 @@ export interface SyncStore {
140
156
  * contract's RxDB-derived naming) for a row whose push hit a `412`, applying
141
157
  * `projection` in the same transaction. `latest === null` means the server
142
158
  * has a tombstone (or the resource is absent): record the tombstone and
143
- * delete the projection.
159
+ * delete the projection. A non-null `latest` carries its own `etag`, which
160
+ * the store MUST record onto the row alongside `version` -- it is the
161
+ * validator the row's next push echoes back as `ifMatch`.
144
162
  */
145
163
  adoptLatest(options: {
146
164
  id: string;
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/sync/types.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,OAAO,EACL,iBAAiB,EACjB,oBAAoB,EACpB,oBAAoB,EACrB,MAAM,0BAA0B,CAAA;AACjC,YAAY,EACV,IAAI,EACJ,cAAc,EACd,OAAO,EACP,WAAW,EACX,WAAW,EACX,SAAS,EACV,MAAM,0BAA0B,CAAA;AAEjC,OAAO,KAAK,EACV,IAAI,EACJ,WAAW,EACX,cAAc,EACd,OAAO,EACR,MAAM,0BAA0B,CAAA;AAEjC;;;;;;;;;;;;;GAaG;AACH,MAAM,WAAW,SAAS;IACxB,EAAE,EAAE,MAAM,CAAA;IACV,OAAO,E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;IAEjB;;;;;;OAMG;IACH,iBAAiB,CAAC,OAAO,EAAE;QACzB,EAAE,EAAE,MAAM,CAAA;QACV,OAAO,CAAC,EAAE,MAAM,CAAA;QAChB,IAAI,CAAC,EAAE,MAAM,CAAA;QACb,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,CAAA;KAC3B,GAAG,OAAO,CAAC,IAAI,CAAC,CAAA;IAEjB;;;;;;;;OAQG;IACH,WAAW,CAAC,OAAO,EAAE;QACnB,EAAE,EAAE,MAAM,CAAA;QACV,MAAM,EAAE,WAAW,GAAG,IAAI,CAAA;QAC1B,UAAU,EAAE,gBAAgB,CAAA;KAC7B,GAAG,OAAO,CAAC,IAAI,CAAC,CAAA;IAEjB;;;;;;;;;;;;;;;;;;;;;;;;;OAyBG;IACH,cAAc,CAAC,CAAC,OAAO,EAAE;QACvB,EAAE,EAAE,MAAM,CAAA;QACV,KAAK,EAAE,MAAM,CAAA;QACb,QAAQ,EAAE,IAAI,CAAA;QACd,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,CAAA;KAC3B,GAAG,OAAO,CAAC;QAAE,OAAO,EAAE,OAAO,CAAA;KAAE,CAAC,CAAA;CAClC"}
@@ -5,13 +5,19 @@
5
5
  * Types for the WAS replication engine core.
6
6
  *
7
7
  * The wire contract and port seam (`Json`, `SyncCheckpoint`, `WireDoc`,
8
- * `MasterState`, `WasSyncPort`, `DocCipher`, and the `WasSyncConflictError` /
9
- * `WasSyncNotFoundError` / `UnknownEpochError` signals) come from
10
- * `@interop/was-client/sync` and are re-exported here so a single import gives
11
- * a consumer both the wire types and the replica-side seams. The predicates
12
- * that CLASSIFY those signals ship from `@interop/was-client/sync` too, beside
13
- * the classes that assign the names they match; `push.ts` and `remint.ts`
14
- * import them from there.
8
+ * `MasterState`, `WriteAck`, `WasSyncPort`, `DocCipher`, and the
9
+ * `WasSyncConflictError` / `WasSyncNotFoundError` / `UnknownEpochError`
10
+ * signals) come from `@interop/was-client/sync` and are re-exported here so a
11
+ * single import gives a consumer both the wire types and the replica-side
12
+ * seams. The predicates that CLASSIFY those signals ship from
13
+ * `@interop/was-client/sync` too, beside the classes that assign the names
14
+ * they match; `push.ts` and `remint.ts` import them from there.
15
+ *
16
+ * The server's `ETag` is opaque (it embeds a per-record generation marker
17
+ * ahead of the content `version`, so it can no longer be rebuilt from a bare
18
+ * revision number). `MasterState.etag` / `WireDoc.etag` / `WriteAck.etag`
19
+ * carry it verbatim; a store that persists synced rows MUST keep the string
20
+ * alongside `version` and echo it back as a later write's `ifMatch`.
15
21
  *
16
22
  * The local-persistence seam (`SyncStore`, `SyncedRow`, `ProjectionAction`,
17
23
  * `ResolveConflict`) is the replica's side of the contract: it stands in for a
@@ -1 +1 @@
1
- {"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/sync/types.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,OAAO,EACL,iBAAiB,EACjB,oBAAoB,EACpB,oBAAoB,EACrB,MAAM,0BAA0B,CAAA"}
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/sync/types.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AACH,OAAO,EACL,iBAAiB,EACjB,oBAAoB,EACpB,oBAAoB,EACrB,MAAM,0BAA0B,CAAA"}
@@ -40,7 +40,7 @@ export type { StandingUnlockClient, UnlockClientIdentity } from './standingClien
40
40
  export { computeUnlockBinding, LADDER_SEED_BYTES, recordSealedRecipientKeys, remintUnlockRecordDelegations, UnlockBindingError, unlockRecordBinding, unlockRecordSealedTo, unwrapUnlockRecord, wrapUnlockRecord } from './unlockRecord.js';
41
41
  export type { SealedRecordMember, SignedUnlockRecord, UnlockRecordContents, UnlockRecordProofState } from './unlockRecord.js';
42
42
  export { assertLadderVmClaimed, ladderVmClaimOf, preflightUnlockCredentialRetirement, publishUnlockKey, removeUnlockKey, UnclaimedLadderVmRetirementError, unlockKeyVerificationMethod, unlockKeyVmId } from './standingWebvh.js';
43
- export type { LadderVmRemovalReport, StandingUnlockKeys, UnlockKeyAgreementPublication, UnlockLogStore } from './standingWebvh.js';
43
+ export type { CredentialKeyAgreementMethod, LadderVmRemovalReport, StandingUnlockKeys, UnlockKeyAgreementPublication, UnlockLogStore } from './standingWebvh.js';
44
44
  export { retireUnlockCredential } from './retire.js';
45
45
  export type { ClientAnnexInventoryRetirement, UnlockCredentialRetirementResult } from './retire.js';
46
46
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/unlock/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH,OAAO,EACL,4BAA4B,EAC5B,oBAAoB,EACpB,4BAA4B,EAC7B,MAAM,qBAAqB,CAAA;AAC5B,YAAY,EACV,oBAAoB,EACpB,oBAAoB,EACrB,MAAM,qBAAqB,CAAA;AAE5B,OAAO,EACL,oBAAoB,EACpB,iBAAiB,EACjB,yBAAyB,EACzB,6BAA6B,EAC7B,kBAAkB,EAClB,mBAAmB,EACnB,oBAAoB,EACpB,kBAAkB,EAClB,gBAAgB,EACjB,MAAM,mBAAmB,CAAA;AAC1B,YAAY,EACV,kBAAkB,EAClB,kBAAkB,EAClB,oBAAoB,EACpB,sBAAsB,EACvB,MAAM,mBAAmB,CAAA;AAE1B,OAAO,EACL,qBAAqB,EACrB,eAAe,EACf,mCAAmC,EACnC,gBAAgB,EAChB,eAAe,EACf,gCAAgC,EAChC,2BAA2B,EAC3B,aAAa,EACd,MAAM,oBAAoB,CAAA;AAC3B,YAAY,EACV,qBAAqB,EACrB,kBAAkB,EAClB,6BAA6B,EAC7B,cAAc,EACf,MAAM,oBAAoB,CAAA;AAE3B,OAAO,EAAE,sBAAsB,EAAE,MAAM,aAAa,CAAA;AACpD,YAAY,EACV,8BAA8B,EAC9B,gCAAgC,EACjC,MAAM,aAAa,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/unlock/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH,OAAO,EACL,4BAA4B,EAC5B,oBAAoB,EACpB,4BAA4B,EAC7B,MAAM,qBAAqB,CAAA;AAC5B,YAAY,EACV,oBAAoB,EACpB,oBAAoB,EACrB,MAAM,qBAAqB,CAAA;AAE5B,OAAO,EACL,oBAAoB,EACpB,iBAAiB,EACjB,yBAAyB,EACzB,6BAA6B,EAC7B,kBAAkB,EAClB,mBAAmB,EACnB,oBAAoB,EACpB,kBAAkB,EAClB,gBAAgB,EACjB,MAAM,mBAAmB,CAAA;AAC1B,YAAY,EACV,kBAAkB,EAClB,kBAAkB,EAClB,oBAAoB,EACpB,sBAAsB,EACvB,MAAM,mBAAmB,CAAA;AAE1B,OAAO,EACL,qBAAqB,EACrB,eAAe,EACf,mCAAmC,EACnC,gBAAgB,EAChB,eAAe,EACf,gCAAgC,EAChC,2BAA2B,EAC3B,aAAa,EACd,MAAM,oBAAoB,CAAA;AAC3B,YAAY,EACV,4BAA4B,EAC5B,qBAAqB,EACrB,kBAAkB,EAClB,6BAA6B,EAC7B,cAAc,EACf,MAAM,oBAAoB,CAAA;AAE3B,OAAO,EAAE,sBAAsB,EAAE,MAAM,aAAa,CAAA;AACpD,YAAY,EACV,8BAA8B,EAC9B,gCAAgC,EACjC,MAAM,aAAa,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/unlock/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH,OAAO,EACL,4BAA4B,EAC5B,oBAAoB,EACpB,4BAA4B,EAC7B,MAAM,qBAAqB,CAAA;AAM5B,OAAO,EACL,oBAAoB,EACpB,iBAAiB,EACjB,yBAAyB,EACzB,6BAA6B,EAC7B,kBAAkB,EAClB,mBAAmB,EACnB,oBAAoB,EACpB,kBAAkB,EAClB,gBAAgB,EACjB,MAAM,mBAAmB,CAAA;AAQ1B,OAAO,EACL,qBAAqB,EACrB,eAAe,EACf,mCAAmC,EACnC,gBAAgB,EAChB,eAAe,EACf,gCAAgC,EAChC,2BAA2B,EAC3B,aAAa,EACd,MAAM,oBAAoB,CAAA;AAQ3B,OAAO,EAAE,sBAAsB,EAAE,MAAM,aAAa,CAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/unlock/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH,OAAO,EACL,4BAA4B,EAC5B,oBAAoB,EACpB,4BAA4B,EAC7B,MAAM,qBAAqB,CAAA;AAM5B,OAAO,EACL,oBAAoB,EACpB,iBAAiB,EACjB,yBAAyB,EACzB,6BAA6B,EAC7B,kBAAkB,EAClB,mBAAmB,EACnB,oBAAoB,EACpB,kBAAkB,EAClB,gBAAgB,EACjB,MAAM,mBAAmB,CAAA;AAQ1B,OAAO,EACL,qBAAqB,EACrB,eAAe,EACf,mCAAmC,EACnC,gBAAgB,EAChB,eAAe,EACf,gCAAgC,EAChC,2BAA2B,EAC3B,aAAa,EACd,MAAM,oBAAoB,CAAA;AAS3B,OAAO,EAAE,sBAAsB,EAAE,MAAM,aAAa,CAAA"}
@@ -166,7 +166,14 @@ export interface ClientAnnexInventoryRetirement {
166
166
  * @param [options.onUserKeyAdopted] {Function} persists a rotated key:
167
167
  * called with `{ userKey, latestEpochId, descriptor }` after the roster read
168
168
  * and BEFORE the fan-out. The key and the epoch pin must persist atomically
169
- * @param options.collections {CascadeCollections} the fan-out's work
169
+ * @param options.collections {CascadeCollections} the fan-out's work. Every
170
+ * collection store it hands back appends to that collection's governing
171
+ * log, anchored at the POST-EDIT document, so its signer must be a key that
172
+ * document still lists under `assertionMethod`. On a passphrase change that
173
+ * is the NEW credential's ladder VM, never the retiring credential's, whose
174
+ * ladder VM this ceremony's own inventory edit strikes; sign with the
175
+ * retiring one and every collection append is refused, leaving the
176
+ * collections keyed to the retired user key generation
170
177
  * @param [options.retireClientAnnexInventory] {Function} `({ document }) =>
171
178
  * Promise<ClientAnnexInventoryRetirement>` -- the annex reach (stage 1b in
172
179
  * the module doc), run against the post-edit document; a throw is caught
@@ -1 +1 @@
1
- {"version":3,"file":"retire.d.ts","sourceRoot":"","sources":["../../src/unlock/retire.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkFG;AACH,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAA;AACpE,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,qBAAqB,CAAA;AAC/D,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,yBAAyB,CAAA;AACxE,OAAO,EAEL,KAAK,kBAAkB,EACvB,KAAK,gBAAgB,EACrB,KAAK,OAAO,EACZ,KAAK,oBAAoB,EAC1B,MAAM,kBAAkB,CAAA;AACzB,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AACrD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAA;AAChE,OAAO,EAEL,KAAK,qBAAqB,EAC1B,KAAK,kBAAkB,EACxB,MAAM,oBAAoB,CAAA;AAE3B;;;;;;;;;GASG;AACH,MAAM,WAAW,gCAAgC;IAC/C,OAAO,EAAE,OAAO,CAAA;IAChB,QAAQ,EAAE,qBAAqB,CAAA;IAC/B,UAAU,CAAC,EAAE,gBAAgB,CAAA;IAC7B,WAAW,EAAE,oBAAoB,CAAA;IACjC,QAAQ,EAAE,MAAM,CAAA;IAChB,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,gBAAgB,CAAC,EAAE,oB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E,MAAM,CAAA;KACjB,KAAK,OAAO,CAAC,8BAA8B,CAAC,CAAA;IAC7C,iBAAiB,CAAC,EAAE,CAAC,QAAQ,EAAE;QAAE,OAAO,EAAE,OAAO,CAAA;KAAE,KAAK,OAAO,CAAC,IAAI,CAAC,CAAA;CACtE,GAAG,OAAO,CAAC,gCAAgC,CAAC,CAoE5C"}
@@ -42,7 +42,14 @@ import { removeUnlockKey } from './standingWebvh.js';
42
42
  * @param [options.onUserKeyAdopted] {Function} persists a rotated key:
43
43
  * called with `{ userKey, latestEpochId, descriptor }` after the roster read
44
44
  * and BEFORE the fan-out. The key and the epoch pin must persist atomically
45
- * @param options.collections {CascadeCollections} the fan-out's work
45
+ * @param options.collections {CascadeCollections} the fan-out's work. Every
46
+ * collection store it hands back appends to that collection's governing
47
+ * log, anchored at the POST-EDIT document, so its signer must be a key that
48
+ * document still lists under `assertionMethod`. On a passphrase change that
49
+ * is the NEW credential's ladder VM, never the retiring credential's, whose
50
+ * ladder VM this ceremony's own inventory edit strikes; sign with the
51
+ * retiring one and every collection append is refused, leaving the
52
+ * collections keyed to the retired user key generation
46
53
  * @param [options.retireClientAnnexInventory] {Function} `({ document }) =>
47
54
  * Promise<ClientAnnexInventoryRetirement>` -- the annex reach (stage 1b in
48
55
  * the module doc), run against the post-edit document; a throw is caught
@@ -1 +1 @@
1
- {"version":3,"file":"retire.js","sourceRoot":"","sources":["../../src/unlock/retire.ts"],"names":[],"mappings":"AAyFA,OAAO,EACL,gCAAgC,EAKjC,MAAM,kBAAkB,CAAA;AAGzB,OAAO,EACL,eAAe,EAGhB,MAAM,oBAAoB,CAAA;AAqC3B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmDG;AACH,MAAM,CAAC,KAAK,UAAU,sBAAsB,CAAC,EAC3C,OAAO,EACP,MAAM,EACN,UAAU,EACV,UAAU,EACV,eAAe,EACf,WAAW,EACX,IAAI,EACJ,WAAW,EACX,OAAO,EACP,q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AC,CAAC,EAAE,WAAW,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;KACxC,CAAA;AACH,CAAC"}
@@ -109,11 +109,32 @@ export declare function unlockKeyVmId({ did, keyAgreement }: {
109
109
  }): string;
110
110
  /**
111
111
  * What of a standing credential's ladder currently stands in the published
112
- * log, resolved with the recorded update key as ANCHOR and the credential's
113
- * own key-agreement id as the attribution's second arm. The removal edit uses
114
- * it to know what to strike; the retirement ceremony uses it one stage
115
- * earlier, to name the ladder VM it is about to strike to the pass that
116
- * re-mints whatever that VM signed for other credentials.
112
+ * log, resolved from the two anchors a ceremony holds and cross-checked
113
+ * between them. The registry's recorded update key (`updateKeyMultibase`,
114
+ * rung 0 at bind time or a later rung a self-enrollment advanced it to) is
115
+ * one anchor; the credential's own `keyAgreement` member names the other,
116
+ * its rung-0 commitment (`ladderCommitment`, read by
117
+ * {@link credentialLadderAnchor}). Either one alone can be wrong for this
118
+ * credential -- a registry entry recording another ladder's key, a member a
119
+ * foreign update-key holder restated -- and a walk that trusts one strikes
120
+ * whatever ladder that anchor names. The removal edit uses the result to
121
+ * know what to strike; the retirement ceremony uses it one stage earlier,
122
+ * to name the ladder VM it is about to strike to the pass that re-mints
123
+ * whatever that VM signed for other credentials.
124
+ *
125
+ * Seedless, both walks run when the member names an anchor. The
126
+ * member-anchored walk starts at rung 0 and needs no backward recovery, so
127
+ * it is the complete reading; the registry-anchored walk may start at a
128
+ * later rung and recover the earlier ones from the log's positional rules,
129
+ * which leaves it at best equal and in one reachable history (WC-158)
130
+ * short of the member's. So the registry-anchored inventory must be
131
+ * contained in the member-anchored one, and the member-anchored one is what
132
+ * is returned. Anything else -- the two anchors naming different ladders --
133
+ * refuses with {@link LadderAttributionError}. A member naming no anchor
134
+ * (a split bind torn before its authority entry, a member without the
135
+ * property) leaves the registry walk to answer alone, as before. With the
136
+ * ladder seed in hand the cross-check is direct: the seed's rung-0 hash must
137
+ * be the member's named anchor, and the seeded walk is returned.
117
138
  *
118
139
  * It lives here rather than in the ceremony because this module is the one
119
140
  * base-side holder of the annex attribution helpers (the pinned lint
@@ -264,6 +285,22 @@ export declare function preflightUnlockCredentialRetirement({ idStore, unlockKey
264
285
  ladderVmIds: string[];
265
286
  document: DIDDoc;
266
287
  }>;
288
+ /**
289
+ * The write-side shape of a credential-class `keyAgreement` member, the
290
+ * twin of the read side's `ResolvedKeyAgreementMethod`: a `VerificationMethod`
291
+ * carrying the key verbatim (`publicKeyMultibase`) or its hash commitment
292
+ * (`publicKeyCommitment`), and always the ladder's rung-0 commitment. Every
293
+ * bind site builds one through {@link unlockKeyVerificationMethod}, so the
294
+ * permanent property is typed where it is written rather than cast in.
295
+ */
296
+ export type CredentialKeyAgreementMethod = VerificationMethod & {
297
+ controller: string;
298
+ ladderCommitment: string;
299
+ } & ({
300
+ publicKeyMultibase: string;
301
+ } | {
302
+ publicKeyCommitment: string;
303
+ });
267
304
  /**
268
305
  * The credential's `keyAgreement` verification method: an ordinary unmarked
269
306
  * entry carrying either the key verbatim (a `Multikey` with
@@ -275,15 +312,26 @@ export declare function preflightUnlockCredentialRetirement({ idStore, unlockKey
275
312
  * carry the controller marker a client listing or a revocation removal
276
313
  * matches on.
277
314
  *
315
+ * Either flavor names its ladder's rung-0 commitment (`ladderCommitment`):
316
+ * `hash(rung 0)` in the multihash form `nextKeyHashes` carries, the same
317
+ * value the bind commits there. It is what a seedless reader anchors the
318
+ * credential's ladder walk on (`credentialLadderAnchor`), so no reader
319
+ * infers the anchor from the shape of the entry that introduced the member.
320
+ * Every bind site builds the member here, so no emitter can omit it; the
321
+ * roster resolver and the client listings ignore it.
322
+ *
278
323
  * @param options {object}
279
324
  * @param options.did {string} the account's did:webvh
280
325
  * @param options.keyAgreement {UnlockKeyAgreementPublication}
281
- * @returns {VerificationMethod}
326
+ * @param options.ladderCommitment {string} `hash(rung 0)` of the
327
+ * credential's ladder, as `deriveNextKeyHash` renders it
328
+ * @returns {CredentialKeyAgreementMethod}
282
329
  */
283
- export declare function unlockKeyVerificationMethod({ did, keyAgreement }: {
330
+ export declare function unlockKeyVerificationMethod({ did, keyAgreement, ladderCommitment }: {
284
331
  did: string;
285
332
  keyAgreement: UnlockKeyAgreementPublication;
286
- }): VerificationMethod;
333
+ ladderCommitment: string;
334
+ }): CredentialKeyAgreementMethod;
287
335
  /**
288
336
  * BIND (run by an enrolled client, root authority): publishes a standing
289
337
  * credential's split configuration into the document -- one entry adding the
@@ -299,7 +347,17 @@ export declare function unlockKeyVerificationMethod({ did, keyAgreement }: {
299
347
  * idempotence against the SAME seed, finds the completed stage and publishes
300
348
  * nothing -- where a mint-when-absent would publish a second VM that no
301
349
  * anchored attribution could later strike. A credential with no ladder at all
302
- * passes `null` and gets no VM.
350
+ * passes `null` and gets no VM. The same rule is enforced against the
351
+ * document, since a caller can mint a fresh seed for a member that already
352
+ * stands (a torn establishment re-run, a registry entry recording the wrong
353
+ * key): a standing member names its ladder's rung-0 commitment
354
+ * (`ladderCommitment`), and a bind whose rung-0 hash differs from it refuses
355
+ * with {@link LadderAttributionError} and writes nothing. Re-adding the
356
+ * member under the new hash would leave it unclaimable by every seedless
357
+ * reader for the rest of its standing run and the first ladder's VM and
358
+ * commitment as orphans; the re-run that converges holds the seed that bound
359
+ * the member. A standing member naming the same hash is extended as before,
360
+ * which is what a split bind's authority entry does.
303
361
  *
304
362
  * `part` splits the bind across two entries where a ceremony needs the
305
363
  * credential's decryption material to precede its authority: `'key'`
@@ -370,16 +428,20 @@ export declare function publishUnlockKey(options: {
370
428
  * too, reading the log's positional rules backwards, so an anchor advanced by
371
429
  * a self-enrollment resolves the same inventory a bind-time anchor does
372
430
  * wherever each rung's hash was committed by an entry that also revealed the
373
- * previous rung, or by a handover. One reachable shape falls outside that: a
374
- * ladder VM the last-client transition reinstalled, whose acting rung a later
375
- * self-enrollment then spends. That reveal-and-commit entry authorizes no key,
376
- * so the backward walk cannot name the rung that signed it, and the VM stays
377
- * standing as `unclaimed` (WC-158). A supplied `ladderSeed` is then a shortcut
378
- * and a cross-check rather than a requirement (every rung known outright, no
379
- * backward walk). For a
380
- * single-key credential (a
381
- * recovery code, a never-self-enrolled bind) the resolution degenerates to
382
- * exactly the recorded key's hash, as before.
431
+ * previous rung, or by a handover. The credential's own member names a
432
+ * second anchor, its rung-0 commitment, and the removal walks from both and
433
+ * cross-checks them ({@link attributeUnlockLadderInventory}): the
434
+ * member-anchored walk reads the whole history forward and is what the
435
+ * strike acts on, the registry-anchored one must be contained in it, and
436
+ * two anchors resolving to different ladders refuse with
437
+ * {@link LadderAttributionError}. That is what reads the one history the
438
+ * backward walk cannot -- a ladder VM the last-client transition reinstalled,
439
+ * whose acting rung a later self-enrollment then spends, so that the
440
+ * registry anchor advances past a reveal-and-commit entry that authorized no
441
+ * key. A supplied `ladderSeed` is then a shortcut and a cross-check rather
442
+ * than a requirement (every rung known outright, no backward walk). For a
443
+ * single-key credential (a recovery code, a never-self-enrolled bind) the
444
+ * resolution degenerates to exactly the recorded key's hash, as before.
383
445
  *
384
446
  * The credential's LADDER VM goes in the same entry, so a retired credential
385
447
  * no longer signs governed-log appends or account delegations. This is the
@@ -1 +1 @@
1
- {"version":3,"file":"standingWebvh.d.ts","sourceRoot":"","sources":["../../src/unlock/standingWebvh.ts"],"names":[],"mappings":"AA+BA,OAAO,KAAK,EACV,MAAM,EACN,MAAM,EACN,kBAAkB,EACnB,MAAM,2BAA2B,CAAA;AASlC,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAA;AAGhE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAA;AAMxD,OAAO,EAKL,KAAK,uBAAuB,EAC7B,MAAM,0BAA0B,CAAA;AAEjC;;;;;GAKG;AACH,MAAM,MAAM,cAAc,GAAG,IAAI,CAC/B,YAAY,EACZ,kBAAkB,GAAG,eAAe,GAAG,KAAK,CAC7C,CAAA;AAED;;;;;;;GAOG;AACH,MAAM,MAAM,mBAAmB,GAAG,KAAK,GAAG,KAAK,GAAG,WAAW,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