@open-e2ee/signal-protocol-sdk 13.3.0 → 13.5.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 (187) hide show
  1. package/CHANGELOG.md +436 -0
  2. package/README.md +1 -1
  3. package/SECURITY.md +2 -2
  4. package/dist/client/binary-send.d.ts +28 -0
  5. package/dist/client/binary-send.d.ts.map +1 -0
  6. package/dist/client/binary-send.js +26 -0
  7. package/dist/client/binary-send.js.map +1 -0
  8. package/dist/client/client.d.ts +47 -6
  9. package/dist/client/client.d.ts.map +1 -1
  10. package/dist/client/client.js +288 -136
  11. package/dist/client/client.js.map +1 -1
  12. package/dist/client/content-adapter.d.ts +18 -0
  13. package/dist/client/content-adapter.d.ts.map +1 -1
  14. package/dist/client/content-adapter.js.map +1 -1
  15. package/dist/client/device-set-reconciliation.d.ts +23 -8
  16. package/dist/client/device-set-reconciliation.d.ts.map +1 -1
  17. package/dist/client/device-set-reconciliation.js +25 -11
  18. package/dist/client/device-set-reconciliation.js.map +1 -1
  19. package/dist/client/event-hooks.d.ts +88 -8
  20. package/dist/client/event-hooks.d.ts.map +1 -1
  21. package/dist/client/event-hooks.js +1 -0
  22. package/dist/client/event-hooks.js.map +1 -1
  23. package/dist/client/group-outbox.d.ts +45 -10
  24. package/dist/client/group-outbox.d.ts.map +1 -1
  25. package/dist/client/group-outbox.js +246 -154
  26. package/dist/client/group-outbox.js.map +1 -1
  27. package/dist/client/group-receive-authorization.d.ts +10 -1
  28. package/dist/client/group-receive-authorization.d.ts.map +1 -1
  29. package/dist/client/group-receive-authorization.js.map +1 -1
  30. package/dist/client/hosted-anonymous-delivery.d.ts +18 -1
  31. package/dist/client/hosted-anonymous-delivery.d.ts.map +1 -1
  32. package/dist/client/hosted-anonymous-delivery.js +84 -12
  33. package/dist/client/hosted-anonymous-delivery.js.map +1 -1
  34. package/dist/client/hosted-connection.js +1 -1
  35. package/dist/client/hosted-connection.js.map +1 -1
  36. package/dist/client/hosted-group-authority.d.ts +6 -2
  37. package/dist/client/hosted-group-authority.d.ts.map +1 -1
  38. package/dist/client/hosted-group-authority.js +11 -7
  39. package/dist/client/hosted-group-authority.js.map +1 -1
  40. package/dist/client/hosted-groups.d.ts +5 -1
  41. package/dist/client/hosted-groups.d.ts.map +1 -1
  42. package/dist/client/hosted-groups.js +8 -4
  43. package/dist/client/hosted-groups.js.map +1 -1
  44. package/dist/client/hosted-http-error.d.ts +5 -1
  45. package/dist/client/hosted-http-error.d.ts.map +1 -1
  46. package/dist/client/hosted-http-error.js +5 -1
  47. package/dist/client/hosted-http-error.js.map +1 -1
  48. package/dist/client/hosted-mailbox-subscription.d.ts +2 -0
  49. package/dist/client/hosted-mailbox-subscription.d.ts.map +1 -1
  50. package/dist/client/hosted-mailbox-subscription.js +5 -5
  51. package/dist/client/hosted-mailbox-subscription.js.map +1 -1
  52. package/dist/client/hosted-resume-error.d.ts +19 -0
  53. package/dist/client/hosted-resume-error.d.ts.map +1 -0
  54. package/dist/client/hosted-resume-error.js +44 -0
  55. package/dist/client/hosted-resume-error.js.map +1 -0
  56. package/dist/client/hosted-resume.d.ts +24 -0
  57. package/dist/client/hosted-resume.d.ts.map +1 -0
  58. package/dist/client/hosted-resume.js +82 -0
  59. package/dist/client/hosted-resume.js.map +1 -0
  60. package/dist/client/hosted-transport.d.ts +11 -1
  61. package/dist/client/hosted-transport.d.ts.map +1 -1
  62. package/dist/client/hosted-transport.js +102 -33
  63. package/dist/client/hosted-transport.js.map +1 -1
  64. package/dist/client/hosted.d.ts.map +1 -1
  65. package/dist/client/hosted.js +29 -6
  66. package/dist/client/hosted.js.map +1 -1
  67. package/dist/client/index.d.ts +3 -1
  68. package/dist/client/index.d.ts.map +1 -1
  69. package/dist/client/index.js +2 -0
  70. package/dist/client/index.js.map +1 -1
  71. package/dist/client/receive-queue.d.ts +5 -2
  72. package/dist/client/receive-queue.d.ts.map +1 -1
  73. package/dist/client/receive-queue.js +55 -18
  74. package/dist/client/receive-queue.js.map +1 -1
  75. package/dist/client/relay-acceptance.d.ts +49 -6
  76. package/dist/client/relay-acceptance.d.ts.map +1 -1
  77. package/dist/client/relay-acceptance.js +49 -3
  78. package/dist/client/relay-acceptance.js.map +1 -1
  79. package/dist/client/relay-protocol.d.ts +37 -7
  80. package/dist/client/relay-protocol.d.ts.map +1 -1
  81. package/dist/client/relay-protocol.js +53 -10
  82. package/dist/client/relay-protocol.js.map +1 -1
  83. package/dist/client/retry-family.d.ts +3 -3
  84. package/dist/client/retry-family.js +1 -1
  85. package/dist/client/retry-family.js.map +1 -1
  86. package/dist/client/retry-request-envelope.d.ts +18 -8
  87. package/dist/client/retry-request-envelope.d.ts.map +1 -1
  88. package/dist/client/retry-request-envelope.js +57 -29
  89. package/dist/client/retry-request-envelope.js.map +1 -1
  90. package/dist/client/retry-request-lifecycle.d.ts +24 -11
  91. package/dist/client/retry-request-lifecycle.d.ts.map +1 -1
  92. package/dist/client/retry-request-lifecycle.js +46 -20
  93. package/dist/client/retry-request-lifecycle.js.map +1 -1
  94. package/dist/client/retry-terminal-recovery.d.ts +11 -8
  95. package/dist/client/retry-terminal-recovery.d.ts.map +1 -1
  96. package/dist/client/retry-terminal-recovery.js +18 -12
  97. package/dist/client/retry-terminal-recovery.js.map +1 -1
  98. package/dist/client/retry.d.ts +8 -7
  99. package/dist/client/retry.d.ts.map +1 -1
  100. package/dist/client/retry.js +30 -22
  101. package/dist/client/retry.js.map +1 -1
  102. package/dist/client/send-deadline.d.ts +308 -0
  103. package/dist/client/send-deadline.d.ts.map +1 -0
  104. package/dist/client/send-deadline.js +914 -0
  105. package/dist/client/send-deadline.js.map +1 -0
  106. package/dist/client/send-intent-driver.d.ts +116 -0
  107. package/dist/client/send-intent-driver.d.ts.map +1 -0
  108. package/dist/client/send-intent-driver.js +373 -0
  109. package/dist/client/send-intent-driver.js.map +1 -0
  110. package/dist/client/signal-service-cipher.d.ts +257 -27
  111. package/dist/client/signal-service-cipher.d.ts.map +1 -1
  112. package/dist/client/signal-service-cipher.js +1274 -283
  113. package/dist/client/signal-service-cipher.js.map +1 -1
  114. package/dist/client/startup-cleanup.d.ts +2 -0
  115. package/dist/client/startup-cleanup.d.ts.map +1 -0
  116. package/dist/client/startup-cleanup.js +14 -0
  117. package/dist/client/startup-cleanup.js.map +1 -0
  118. package/dist/client/types.d.ts +48 -5
  119. package/dist/client/types.d.ts.map +1 -1
  120. package/dist/client/types.js.map +1 -1
  121. package/dist/index.d.ts +3 -1
  122. package/dist/index.d.ts.map +1 -1
  123. package/dist/index.js +1 -0
  124. package/dist/index.js.map +1 -1
  125. package/dist/internal/manager/manager.d.ts +1 -0
  126. package/dist/internal/manager/manager.d.ts.map +1 -1
  127. package/dist/internal/manager/manager.js +17 -2
  128. package/dist/internal/manager/manager.js.map +1 -1
  129. package/dist/internal/manager/retained-identity.d.ts +2 -0
  130. package/dist/internal/manager/retained-identity.d.ts.map +1 -0
  131. package/dist/internal/manager/retained-identity.js +57 -0
  132. package/dist/internal/manager/retained-identity.js.map +1 -0
  133. package/dist/local/store/conformance/cases/metadata.d.ts +3 -2
  134. package/dist/local/store/conformance/cases/metadata.d.ts.map +1 -1
  135. package/dist/local/store/conformance/cases/metadata.js +153 -2
  136. package/dist/local/store/conformance/cases/metadata.js.map +1 -1
  137. package/dist/local/store/key-value/adapter.d.ts +2 -1
  138. package/dist/local/store/key-value/adapter.d.ts.map +1 -1
  139. package/dist/local/store/key-value/adapter.js +9 -0
  140. package/dist/local/store/key-value/adapter.js.map +1 -1
  141. package/dist/local/store/memory/adapter.d.ts +2 -1
  142. package/dist/local/store/memory/adapter.d.ts.map +1 -1
  143. package/dist/local/store/memory/adapter.js +4 -0
  144. package/dist/local/store/memory/adapter.js.map +1 -1
  145. package/dist/local/store/metadata-keys.d.ts +13 -0
  146. package/dist/local/store/metadata-keys.d.ts.map +1 -0
  147. package/dist/local/store/metadata-keys.js +20 -0
  148. package/dist/local/store/metadata-keys.js.map +1 -0
  149. package/dist/local/store/receive-work.d.ts.map +1 -1
  150. package/dist/local/store/receive-work.js +12 -1
  151. package/dist/local/store/receive-work.js.map +1 -1
  152. package/dist/local/store/reliability.d.ts +482 -33
  153. package/dist/local/store/reliability.d.ts.map +1 -1
  154. package/dist/local/store/reliability.js +690 -48
  155. package/dist/local/store/reliability.js.map +1 -1
  156. package/dist/local/store/sqlite/key-storage/index.d.ts +2 -1
  157. package/dist/local/store/sqlite/key-storage/index.d.ts.map +1 -1
  158. package/dist/local/store/sqlite/key-storage/index.js +3 -0
  159. package/dist/local/store/sqlite/key-storage/index.js.map +1 -1
  160. package/dist/local/store/sqlite/key-storage/metadata.d.ts +9 -0
  161. package/dist/local/store/sqlite/key-storage/metadata.d.ts.map +1 -1
  162. package/dist/local/store/sqlite/key-storage/metadata.js +12 -0
  163. package/dist/local/store/sqlite/key-storage/metadata.js.map +1 -1
  164. package/dist/local/store/sqlite/store.d.ts +2 -1
  165. package/dist/local/store/sqlite/store.d.ts.map +1 -1
  166. package/dist/local/store/sqlite/store.js +3 -0
  167. package/dist/local/store/sqlite/store.js.map +1 -1
  168. package/dist/local/store/web/adapter.d.ts +8 -1
  169. package/dist/local/store/web/adapter.d.ts.map +1 -1
  170. package/dist/local/store/web/adapter.js +18 -0
  171. package/dist/local/store/web/adapter.js.map +1 -1
  172. package/dist/remote/relay/request-admission.d.ts +49 -0
  173. package/dist/remote/relay/request-admission.d.ts.map +1 -0
  174. package/dist/remote/relay/request-admission.js +74 -0
  175. package/dist/remote/relay/request-admission.js.map +1 -0
  176. package/dist/types/api.d.ts +77 -0
  177. package/dist/types/api.d.ts.map +1 -1
  178. package/dist/types/errors.d.ts +144 -1
  179. package/dist/types/errors.d.ts.map +1 -1
  180. package/dist/types/errors.js +146 -1
  181. package/dist/types/errors.js.map +1 -1
  182. package/docs/ASSURANCE.md +5 -5
  183. package/docs/DEVIATIONS.md +34 -4
  184. package/docs/ERROR_HANDLING.md +134 -7
  185. package/docs/PACKAGE_SURFACE.md +21 -0
  186. package/docs/RECIPES.md +3 -2
  187. package/package.json +1 -1
@@ -25,8 +25,10 @@ import { GroupReceiveRefusedError, GroupReceiveUnavailableError, type GroupRecei
25
25
  import type { PreparedAttachmentUpload, SealedReceipt, SendOptions, SendResult } from './types.js';
26
26
  import { ContentHint } from '../types/messages.js';
27
27
  import { type BlockedRecipientsSyncInput, type ConfigurationSyncInput, type GroupContentContext, type InspectedSignalProtocolContent, type MediaAttachmentDeleteSyncInput, type ReadSyncEntryInput, type RecipientUsernameSyncInput, type SignalProtocolContentAdapter, type TaskNotificationAckSyncInput, type UsernameStateSyncInput, type VerificationStateSyncInput, type ViewOnceOpenSyncInput } from './content-adapter.js';
28
- import { type RetryResendTarget } from '../local/store/reliability.js';
28
+ import { type OutgoingIntentEndReport, type RetryResendTarget, type StoredManualResend, type StoredOutgoingMessageIntent } from '../local/store/reliability.js';
29
29
  import { type BoundedFanOut } from '../utils/bounded-fan-out.js';
30
+ import { type ManualResendEndReport } from './send-deadline.js';
31
+ import { type IntentContent } from './send-intent-driver.js';
30
32
  import { RelayProtocolError } from './device-set-reconciliation.js';
31
33
  import { type SealedSenderProvider as SealedSenderProviderContract } from './sealed-sender.js';
32
34
  import { type ContactProfileStateStore } from '../profile/contact-state.js';
@@ -246,6 +248,8 @@ export declare class SignalProtocolServiceCipher {
246
248
  private groupContextProvider?;
247
249
  constructor(userId: string, deviceId: number, sesameManager: SesameManager, senderKeyManager: SenderKeyManager, storage: SignalProtocolLocalStore, relay?: SignalProtocolRelayServer | undefined, remoteObjectStore?: SignalProtocolRemoteObjectStore | undefined, contentAdapter?: SignalProtocolContentAdapter | undefined, logger?: Required<Logger>, fanOut?: BoundedFanOut);
248
250
  private getResolvedContentAdapter;
251
+ /** The plaintext with no group context, by the resolved content adapter. */
252
+ withoutGroupContext(plaintext: string): string;
249
253
  private getDirectConversationId;
250
254
  private buildSentSyncTranscript;
251
255
  private encodeLosslessPlaintext;
@@ -263,6 +267,12 @@ export declare class SignalProtocolServiceCipher {
263
267
  * warning is logged. The post then resolves, so the send completes without
264
268
  * the copy.
265
269
  *
270
+ * `gate` gives the `beforeRequest` of each copy by its client message ID,
271
+ * or by `undefined` for a copy that has no ID. Without `gate`, each copy
272
+ * uses the `beforeRequest` of `control`.
273
+ *
274
+ * @returns The relay receipt of the copy or of its repaired copy, or
275
+ * undefined when the copy left the intent
266
276
  * @throws {EncryptionError} SESSION_ESTABLISHMENT_FAILED when the refresh
267
277
  * fails or the rebuild gives the device no copy. The copy stays in the
268
278
  * intent, so a replay posts it again.
@@ -284,6 +294,7 @@ export declare class SignalProtocolServiceCipher {
284
294
  * @returns The relay receipt of the post
285
295
  */
286
296
  private postSyncCopy;
297
+ private postSyncCopyRequest;
287
298
  /**
288
299
  * Run one relay phase of a send: a task for each device message, at the same
289
300
  * time, under the client's relay request bound. Every device is attempted.
@@ -535,14 +546,15 @@ export declare class SignalProtocolServiceCipher {
535
546
  * kind of the stored record posts the stored bytes with their epoch
536
547
  * again, and does not encrypt: that is the sender's own retry of a post
537
548
  * that did not complete. A call for another request envelope or kind
538
- * encrypts with a fresh epoch, replaces the record in one write, and
539
- * posts it. So does a call whose stored bytes the Relay refuses with
540
- * OPERATION_EXPIRED: the new bytes post under the same ID. A
541
- * RETRY_CONFLICT answer to a post means that the Relay holds an earlier
542
- * encryption under this ID, so the answer is complete. When the Relay
543
- * admits the new bytes after the recipient acknowledged the earlier
544
- * ones, the recipient drops them as processed. Nothing deletes the
545
- * record before `RELIABILITY_RECORD_TTL_MS`.
549
+ * encrypts once under its own attempt ID, replaces the record in one
550
+ * write, and posts it. A call whose stored bytes the Relay refuses with
551
+ * OPERATION_EXPIRED marks the record acceptance-unknown and posts
552
+ * nothing more under that ID. A later call for that attempt and kind
553
+ * finds the mark and posts nothing. A RETRY_CONFLICT answer to a post, or a
554
+ * DELIVERY_ALREADY_ACCEPTED answer under protocol version 2, means that the
555
+ * Relay holds an earlier encryption under this ID, so the answer is
556
+ * complete. Nothing deletes the record before
557
+ * `RELIABILITY_RECORD_TTL_MS`.
546
558
  *
547
559
  * @param recipientUserId - The user of the device
548
560
  * @param recipientDeviceId - The device that gets the message
@@ -555,14 +567,15 @@ export declare class SignalProtocolServiceCipher {
555
567
  * the content carries that own sender key of the raw group: each
556
568
  * encryption keeps the key, and when the Relay accepts the bytes, the
557
569
  * send records a handoff row of the key that they carry. A post that the
558
- * Relay answers with RETRY_CONFLICT records no row, because the Relay
559
- * holds an earlier encryption
570
+ * Relay answers with RETRY_CONFLICT, or with DELIVERY_ALREADY_ACCEPTED
571
+ * under protocol version 2, records no row, because the Relay holds an
572
+ * earlier encryption
560
573
  * @param stopSignal - The stop signal of the relay work that sends. When it
561
574
  * aborts while the send waits for the recipient's lock, the send throws
562
575
  * RelayWorkStopped
563
- * @returns False only when the content is null and no stored attempt can
564
- * post: there is none for this request attempt, or the Relay refused it
565
- * with OPERATION_EXPIRED
576
+ * @returns False when the content is null and no stored bytes posted in
577
+ * this call. True when the stored bytes posted, or when content exists
578
+ * and the stored attempt has unknown acceptance. Then nothing posts
566
579
  * @throws Error when the request envelope ID is not a retry request of
567
580
  * the retry ID. Nothing is posted
568
581
  */
@@ -576,7 +589,10 @@ export declare class SignalProtocolServiceCipher {
576
589
  generation: number;
577
590
  };
578
591
  }, stopSignal?: AbortSignal): Promise<boolean>;
579
- /** Post the encrypted bytes of a resend with their operation epoch, under one client message ID. */
592
+ /**
593
+ * Post the encrypted bytes of a resend with their operation epoch, under
594
+ * one client message ID. `control` gives the request checks of the post.
595
+ */
580
596
  private postResend;
581
597
  /**
582
598
  * The sealed authorization of one resend post, or null when the post goes
@@ -603,10 +619,11 @@ export declare class SignalProtocolServiceCipher {
603
619
  distribution: SenderKeyDistributionMessage;
604
620
  } | null>;
605
621
  /**
606
- * Encrypt one attempt of a resend, with the current time as its operation
607
- * epoch. The resend of a group send's message takes the sealed
608
- * authorization of a pre-message: the recipient's access key first, then
609
- * the group endorsement of the recipient's account.
622
+ * Encrypt one attempt of a resend, with the epoch of the options or the
623
+ * current time as its operation epoch. The resend of a group send's
624
+ * message takes the sealed authorization of a pre-message: the
625
+ * recipient's access key first, then the group endorsement of the
626
+ * recipient's account.
610
627
  */
611
628
  private encryptResend;
612
629
  /**
@@ -621,7 +638,7 @@ export declare class SignalProtocolServiceCipher {
621
638
  private toSesameMessage;
622
639
  /**
623
640
  * Archive the session with one device, for the session reset of a retry
624
- * request that ended as `expired-content`.
641
+ * request that ended as `expired-content` or `posting-deadline`.
625
642
  *
626
643
  * The archive takes the decrypt lock of the device first, so each decrypt
627
644
  * from the device in progress ends before it, and a decrypt that starts
@@ -748,6 +765,193 @@ export declare class SignalProtocolServiceCipher {
748
765
  private encryptToUser;
749
766
  private encryptToUserWithOutbox;
750
767
  private encryptToUserWithOutboxLocked;
768
+ /**
769
+ * The evidence of one `send()` call of a direct or group intent. It starts
770
+ * from the stored progress of the intent and stores each answer of the
771
+ * call.
772
+ */
773
+ private sendCallEvidence;
774
+ /** A post control whose requests meet the posting deadline of the call. */
775
+ private postingControl;
776
+ /**
777
+ * Post one device message of a direct intent and record its answer in the
778
+ * evidence of the call. Before each request of the post, the outbox stores
779
+ * the request of the device, after the checks of `control`. So the stored
780
+ * progress counts every request that starts.
781
+ */
782
+ private postDirectDeviceMessage;
783
+ /**
784
+ * Post one destination of a group send and record its answer in the
785
+ * evidence of the call. Before each request of the post, the outbox stores
786
+ * the request of the destination, after the checks of `control`.
787
+ */
788
+ private postGroupDestination;
789
+ /**
790
+ * The `beforeRequest` of a group post: it runs the checks of `control`,
791
+ * then stores the request of each destination of the post.
792
+ */
793
+ private recordingRequests;
794
+ /**
795
+ * Send one relay request of a group post under a slot of the bound. With
796
+ * one destination, the evidence of the call records the requests and the
797
+ * answer of the device, and a repeat request that the transport starts for
798
+ * the device meets the deadline and stores its request first. With a list,
799
+ * the post is a shared body: each request counts for each destination, and
800
+ * the one answer is recorded on each destination. A repeat request that the
801
+ * transport starts for one destination of the body stores the request of
802
+ * that destination.
803
+ */
804
+ private postGroupRelay;
805
+ /**
806
+ * Decide the recipient phase of a direct or group send that failed. At or
807
+ * after the posting deadline with an open destination, or when every open
808
+ * destination got OPERATION_EXPIRED, the send ends: the outbox stores its outcome, and
809
+ * the error is the class of the end. Before that, the error is thrown with
810
+ * the deadline, and the intent stays open. A device-set reconciliation
811
+ * error keeps its own rule.
812
+ */
813
+ private endOrRethrow;
814
+ /**
815
+ * End an open intent whose posting deadline has passed, with the class that
816
+ * its stored progress gives, and post nothing. The SDK send driver calls it.
817
+ * Under the intent lock, the call reads the intent again. An intent that is
818
+ * gone, ended, completed or not yet due stays as it is. Past the deadline,
819
+ * the stored progress gives no end only when the Relay accepted each
820
+ * recipient destination: the call then completes the intent from its
821
+ * stored progress, with `syncPending` when a sync copy is not accepted. With
822
+ * `report`, the end write or the completion write records the end in it.
823
+ */
824
+ endPastDeadlineIntent(clientMessageId: string, report?: OutgoingIntentEndReport): Promise<void>;
825
+ /**
826
+ * Complete an open intent whose stored progress records each recipient
827
+ * destination as accepted, with no post. A process can stop after the last
828
+ * acceptance and before the completion write, or a sync failure can leave
829
+ * the intent open after its recipient phase. The result takes its message
830
+ * ID and time from the stored acceptances, as a send call that found each
831
+ * destination accepted does. A sync copy with no stored acceptance keeps
832
+ * the sync phase pending. The caller holds the intent lock.
833
+ */
834
+ private completeAcceptedIntent;
835
+ /**
836
+ * Post a manual resend of a send that ended at its posting deadline
837
+ * without acceptance (`resendMessage`). Only an intent with `outcome` and
838
+ * no `result` takes one.
839
+ *
840
+ * - With no open resend, the call stores a new one. Its message ID is
841
+ * `<clientMessageId>:manual:N`, N from 1. One clock read gives its
842
+ * `createdAt` and its operation epoch, and its posting deadline is 24
843
+ * hours later. It encrypts `content` again for each recipient device
844
+ * that no post of the send or of an earlier resend got accepted, with
845
+ * the client timestamp of the send in the content. Logged bytes of a
846
+ * group send carry the group context of the send and post as they are.
847
+ * Other content of a group intent takes the current group context.
848
+ * - An open resend posts again under its stored epoch and bytes, and the
849
+ * call ignores `content`. At or after its deadline, it ends from its
850
+ * stored progress and posts nothing.
851
+ *
852
+ * The resend ends with its result when the Relay accepts each of its
853
+ * devices, or with its class (contract §3.4) when it is due. A
854
+ * RETRY_CONFLICT under the manual message ID, or a version 2
855
+ * DELIVERY_ALREADY_ACCEPTED, is the resend's own earlier post, so it counts
856
+ * as accepted. The end write fills `report`.
857
+ *
858
+ * @throws Error when the send is missing, open, completed, or accepted by
859
+ * each recipient device. Nothing is posted
860
+ */
861
+ resendOutgoingMessage(clientMessageId: string, content: IntentContent | undefined, options?: {
862
+ stopSignal?: AbortSignal;
863
+ report?: ManualResendEndReport;
864
+ }): Promise<SendResult>;
865
+ /**
866
+ * Post the open manual resend of an ended intent again for the SDK send
867
+ * driver, as `resendOutgoingMessage` does with no content. When the intent
868
+ * has no open resend under the intent lock, for example because a
869
+ * `resendMessage` call ended it after the driver listed it, the call posts
870
+ * nothing and fills nothing in `report`.
871
+ */
872
+ replayManualResend(clientMessageId: string, options: {
873
+ stopSignal?: AbortSignal;
874
+ report: ManualResendEndReport;
875
+ }): Promise<void>;
876
+ /**
877
+ * Run `operation` under the order lock of the recipient of a stored send.
878
+ * A resend keeps the order of the sends to its recipient, as a send does,
879
+ * and the lock serializes the manual resends of one intent.
880
+ */
881
+ private withManualResendOrderLock;
882
+ /**
883
+ * Post a manual resend under the order lock. No encrypt lock is taken
884
+ * while the intent lock is held: a send takes its encrypt lock before the
885
+ * intent lock, so the other order can deadlock with it.
886
+ *
887
+ * 1. Under the intent lock, an open resend posts or ends. With no open
888
+ * resend, the checks run and the call plans a new resend.
889
+ * 2. With no intent lock held, the call encrypts the content for each
890
+ * target device.
891
+ * 3. Under the intent lock, the call stores the resend, which refuses a
892
+ * change to the intent since step 1, and posts it.
893
+ */
894
+ private resendOutgoingMessageOrdered;
895
+ /**
896
+ * Post an open manual resend, or end it from its stored progress at or
897
+ * after its deadline. The caller holds the intent lock.
898
+ */
899
+ private continueManualResend;
900
+ /**
901
+ * Encrypt a planned manual resend for each of its target devices. The
902
+ * caller holds the order lock of the recipient and no intent lock.
903
+ */
904
+ private encryptManualResend;
905
+ /** The evidence of one call of a manual resend, from its stored progress. */
906
+ private manualResendEvidence;
907
+ /**
908
+ * Post each device of an open manual resend under its stored epoch, and
909
+ * end the resend when each device is accepted or when it is due. The
910
+ * caller holds the intent lock.
911
+ */
912
+ private postManualResend;
913
+ /**
914
+ * End a manual resend that is due after a failed post (contract §3.4), and
915
+ * return the error of its end. Undefined when the resend stays open. The
916
+ * caller holds the intent lock.
917
+ */
918
+ private endDueManualResend;
919
+ /**
920
+ * End an open manual resend from its stored progress, and post nothing:
921
+ * with its result when the Relay accepted each of its devices, else with
922
+ * its class. The caller holds the intent lock.
923
+ */
924
+ private endStoredManualResend;
925
+ /**
926
+ * End an open manual resend whose posting deadline has passed, from its
927
+ * stored progress, and post nothing. The SDK send driver calls it. Under
928
+ * the intent lock, the call reads the intent again.
929
+ *
930
+ * @returns The intent and the ended resend, or undefined when the resend
931
+ * is gone, ended or not yet due
932
+ */
933
+ endPastDeadlineManualResend(clientMessageId: string, manualMessageId: string): Promise<{
934
+ intent: StoredOutgoingMessageIntent;
935
+ resend: StoredManualResend;
936
+ } | undefined>;
937
+ /**
938
+ * End a replay whose recipient phase posted no device that a stored
939
+ * refusal proves refused (`provenRefused`). When every open device has such
940
+ * a refusal, the send ends now: the outbox stores its outcome, and the end
941
+ * error is thrown. Otherwise the call returns, and the replay goes on.
942
+ */
943
+ private endRefusedReplay;
944
+ /**
945
+ * The end of a recipient phase that the device-set reconciliation ended
946
+ * unresolved: the class of the send at this point (contract §3.4), from
947
+ * the evidence of the call and the stored progress. Reason `expired` gives
948
+ * `acceptance-unknown`, because the Relay refused the restart post with
949
+ * OPERATION_EXPIRED and an earlier post of the operation can have been
950
+ * accepted. Undefined for an intent that is gone or ended, or whose
951
+ * recipient destinations are all accepted. The caller holds the intent
952
+ * lock.
953
+ */
954
+ private unresolvedRecipientEnd;
751
955
  /**
752
956
  * Post a direct intent to its known devices while the recipient's device
753
957
  * list is read, then reconcile the intent with the list and post the rest.
@@ -793,7 +997,12 @@ export declare class SignalProtocolServiceCipher {
793
997
  * and a concurrent commit that read the store before it fails.
794
998
  */
795
999
  private inRepairTurn;
796
- /** Refresh the session of a rejected device and replace its transmission. */
1000
+ /**
1001
+ * Refresh the session of a rejected device and replace its transmission.
1002
+ *
1003
+ * @returns The new transmission, and the stored progress entry of the
1004
+ * device, which carries the repair mark
1005
+ */
797
1006
  private repairRejectedDirectDeviceMessage;
798
1007
  private repairRejectedDirectDeviceMessageInTurn;
799
1008
  private sendStoredDirectDeviceMessage;
@@ -802,7 +1011,10 @@ export declare class SignalProtocolServiceCipher {
802
1011
  /**
803
1012
  * Post each device message of a direct intent, then the sync messages, and
804
1013
  * complete the intent. A device that a send-first pass already posted keeps
805
- * its result or its refusal.
1014
+ * its result or its refusal. A replay does not post a device that the
1015
+ * stored progress records as accepted or as refused for good
1016
+ * (`provenRefused`), and it does not post an accepted sync copy. When it
1017
+ * skipped a refused device, the send can end before the sync copies.
806
1018
  */
807
1019
  private sendStoredDirectIntent;
808
1020
  /** True when the relay compares declared device sets, so each send declares them. */
@@ -879,7 +1091,8 @@ export declare class SignalProtocolServiceCipher {
879
1091
  private uncheckedDeclaredPostError;
880
1092
  /**
881
1093
  * Replay a stored direct send on a relay that compares device sets. A
882
- * terminal send starts a new run at 0 restarts. A completed send with a
1094
+ * later `send()` after a recipient-phase end throws the stored-end class
1095
+ * of its outcome and posts nothing. A completed send with a
883
1096
  * pending sync phase posts only its sync messages. It first reads the own
884
1097
  * device list when the send could not read it: the phase has no sync
885
1098
  * message and stores no own device with no bundle. A stored device with no
@@ -910,7 +1123,10 @@ export declare class SignalProtocolServiceCipher {
910
1123
  * restart count. A failure or an unresolved end is logged and leaves the
911
1124
  * phase pending. The outcome keeps the receipt of each accepted sync post,
912
1125
  * also when the phase fails, so the send reports a receipt without the
913
- * `deviceSetChecked` mark.
1126
+ * `deviceSetChecked` mark. A direct send passes its posting deadline
1127
+ * check, so no sync post starts at or after the deadline. It also passes
1128
+ * the evidence of its call: the outbox then stores the progress of each
1129
+ * sync copy, and the phase does not post a copy that the Relay accepted.
914
1130
  */
915
1131
  private finishDeclaredSync;
916
1132
  /**
@@ -927,7 +1143,9 @@ export declare class SignalProtocolServiceCipher {
927
1143
  private encryptToGroupWithOutbox;
928
1144
  /**
929
1145
  * The declared work of a group send on a relay that compares device sets
930
- * (§5.5 of the device-set contract).
1146
+ * (§5.5 of the device-set contract). `readEvidence` gives the evidence of
1147
+ * the call, so each sync copy meets the posting deadline and stores its
1148
+ * progress.
931
1149
  */
932
1150
  private groupDeviceSetContext;
933
1151
  /**
@@ -979,6 +1197,16 @@ export declare class SignalProtocolServiceCipher {
979
1197
  * refreshes the session and drops the pre-message, because it has no
980
1198
  * distribution of the key of the send. Resolves to the pre-message that the
981
1199
  * relay accepted or that the send dropped, with the outcome.
1200
+ *
1201
+ * A RETRY_CONFLICT answer, or a DELIVERY_ALREADY_ACCEPTED answer under
1202
+ * protocol version 2, means that the Relay holds a message under the ID of
1203
+ * the post. The evidence of the call accepts it only when the stored
1204
+ * entry of the destination has no blocking repair mark: then the Relay
1205
+ * holds the same bytes, and the pre-message counts as accepted. Each other
1206
+ * such answer leaves the destination unknown, and the pre-message counts
1207
+ * as held: it writes no handoff row, so the next send gives the key again.
1208
+ * A repair refreshes the evidence entry of its repaired post before the
1209
+ * post, so the answer to that post reads the repair mark.
982
1210
  */
983
1211
  private postPreMessage;
984
1212
  /**
@@ -1016,8 +1244,10 @@ export declare class SignalProtocolServiceCipher {
1016
1244
  /**
1017
1245
  * Refresh the session of a device that refused a pre-message, encrypt the
1018
1246
  * distribution again, and replace the stored pre-message before its post.
1019
- * The saved refused ciphertext is never posted again. Resolves to
1020
- * undefined when a replay has no distribution of the key of the send.
1247
+ * The saved refused ciphertext is never posted again. Resolves to the
1248
+ * repaired transport and the stored entry of its post, which carries the
1249
+ * repair mark, or to undefined when a replay has no distribution of the
1250
+ * key of the send.
1021
1251
  */
1022
1252
  private repairRejectedPreMessageInTurn;
1023
1253
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"signal-service-cipher.d.ts","sourceRoot":"","sources":["../../client/signal-service-cipher.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAIH,OAAO,KAAK,EACV,yBAAyB,EACzB,QAAQ,EAGR,iBAAiB,EAElB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,KAAK,EAAE,+BAA+B,EAAE,MAAM,wBAAwB,CAAC;AAC9E,OAAO,KAAK,EACV,wBAAwB,EAExB,iBAAiB,EACjB,eAAe,EAChB,MAAM,UAAU,CAAC;AAClB,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,cAAc,CAAC;AAI3D,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AAGvD,OAAO,EAEL,KAAK,aAAa,EAElB,KAAK,aAAa,EAEnB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EAA+B,KAAK,MAAM,EAAE,MAAM,WAAW,CAAC;AACrE,OAAO,EACL,gBAAgB,EAChB,KAAK,4BAA4B,EAClC,MAAM,kCAAkC,CAAC;AAO1C,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAChE,OAAO,EACL,wBAAwB,EACxB,4BAA4B,EAI5B,KAAK,qBAAqB,EAC3B,MAAM,+BAA+B,CAAC;AAIvC,OAAO,KAAK,EAAE,wBAAwB,EAAE,aAAa,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAMhG,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAEhD,OAAO,EACL,KAAK,0BAA0B,EAE/B,KAAK,sBAAsB,EAC3B,KAAK,mBAAmB,EACxB,KAAK,8BAA8B,EACnC,KAAK,8BAA8B,EACnC,KAAK,kBAAkB,EACvB,KAAK,0BAA0B,EAC/B,KAAK,4BAA4B,EACjC,KAAK,4BAA4B,EACjC,KAAK,sBAAsB,EAC3B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