@open-e2ee/signal-protocol-sdk 11.0.0 → 12.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/ADAPTERS.md +4 -4
- package/ARCHITECTURE.md +6 -8
- package/CHANGELOG.md +1315 -0
- package/README.md +1 -1
- package/SECURITY.md +2 -2
- package/TROUBLESHOOTING.md +1 -1
- package/client/README.md +70 -37
- package/device/README.md +39 -85
- package/dist/client/client.d.ts +334 -63
- package/dist/client/client.d.ts.map +1 -1
- package/dist/client/client.js +1168 -184
- package/dist/client/client.js.map +1 -1
- package/dist/client/config.d.ts +40 -32
- package/dist/client/config.d.ts.map +1 -1
- package/dist/client/config.js +1 -1
- package/dist/client/config.js.map +1 -1
- package/dist/client/constants.d.ts +42 -8
- package/dist/client/constants.d.ts.map +1 -1
- package/dist/client/constants.js +48 -3
- package/dist/client/constants.js.map +1 -1
- package/dist/client/content-adapter.d.ts +80 -0
- package/dist/client/content-adapter.d.ts.map +1 -1
- package/dist/client/content-adapter.js +225 -12
- package/dist/client/content-adapter.js.map +1 -1
- package/dist/client/delivery-error.d.ts +150 -0
- package/dist/client/delivery-error.d.ts.map +1 -0
- package/dist/client/delivery-error.js +226 -0
- package/dist/client/delivery-error.js.map +1 -0
- package/dist/client/delivery-status.d.ts +32 -6
- package/dist/client/delivery-status.d.ts.map +1 -1
- package/dist/client/delivery-status.js +61 -13
- package/dist/client/delivery-status.js.map +1 -1
- package/dist/client/device-set-reconciliation.d.ts +196 -0
- package/dist/client/device-set-reconciliation.d.ts.map +1 -0
- package/dist/client/device-set-reconciliation.js +282 -0
- package/dist/client/device-set-reconciliation.js.map +1 -0
- package/dist/client/distribution-records.d.ts +29 -0
- package/dist/client/distribution-records.d.ts.map +1 -0
- package/dist/client/distribution-records.js +33 -0
- package/dist/client/distribution-records.js.map +1 -0
- package/dist/client/event-hooks.d.ts +280 -14
- package/dist/client/event-hooks.d.ts.map +1 -1
- package/dist/client/event-hooks.js +8 -0
- package/dist/client/event-hooks.js.map +1 -1
- package/dist/client/group-device-set.d.ts +47 -0
- package/dist/client/group-device-set.d.ts.map +1 -0
- package/dist/client/group-device-set.js +65 -0
- package/dist/client/group-device-set.js.map +1 -0
- package/dist/client/group-fetcher.d.ts +116 -0
- package/dist/client/group-fetcher.d.ts.map +1 -0
- package/dist/client/group-fetcher.js +598 -0
- package/dist/client/group-fetcher.js.map +1 -0
- package/dist/client/group-outbox.d.ts +172 -10
- package/dist/client/group-outbox.d.ts.map +1 -1
- package/dist/client/group-outbox.js +915 -74
- package/dist/client/group-outbox.js.map +1 -1
- package/dist/client/group-receive-authorization.d.ts +127 -4
- package/dist/client/group-receive-authorization.d.ts.map +1 -1
- package/dist/client/group-receive-authorization.js +270 -20
- package/dist/client/group-receive-authorization.js.map +1 -1
- package/dist/client/group-sealed-sender.d.ts +3 -0
- package/dist/client/group-sealed-sender.d.ts.map +1 -1
- package/dist/client/group-sealed-sender.js +1 -0
- package/dist/client/group-sealed-sender.js.map +1 -1
- package/dist/client/group-sender-key-operations.d.ts +14 -3
- package/dist/client/group-sender-key-operations.d.ts.map +1 -1
- package/dist/client/group-sender-key-operations.js +26 -5
- package/dist/client/group-sender-key-operations.js.map +1 -1
- package/dist/client/groups.d.ts +5 -5
- package/dist/client/groups.d.ts.map +1 -1
- package/dist/client/groups.js +5 -4
- package/dist/client/groups.js.map +1 -1
- package/dist/client/hosted-anonymous-delivery.d.ts +61 -9
- package/dist/client/hosted-anonymous-delivery.d.ts.map +1 -1
- package/dist/client/hosted-anonymous-delivery.js +242 -48
- package/dist/client/hosted-anonymous-delivery.js.map +1 -1
- package/dist/client/hosted-assertion-id.d.ts +7 -0
- package/dist/client/hosted-assertion-id.d.ts.map +1 -0
- package/dist/client/hosted-assertion-id.js +51 -0
- package/dist/client/hosted-assertion-id.js.map +1 -0
- package/dist/client/hosted-mailbox-subscription.d.ts +34 -2
- package/dist/client/hosted-mailbox-subscription.d.ts.map +1 -1
- package/dist/client/hosted-mailbox-subscription.js +87 -17
- package/dist/client/hosted-mailbox-subscription.js.map +1 -1
- package/dist/client/hosted-push.d.ts +22 -4
- package/dist/client/hosted-push.d.ts.map +1 -1
- package/dist/client/hosted-push.js +75 -22
- package/dist/client/hosted-push.js.map +1 -1
- package/dist/client/hosted-transport.d.ts +22 -28
- package/dist/client/hosted-transport.d.ts.map +1 -1
- package/dist/client/hosted-transport.js +115 -55
- package/dist/client/hosted-transport.js.map +1 -1
- package/dist/client/hosted.d.ts +10 -4
- package/dist/client/hosted.d.ts.map +1 -1
- package/dist/client/hosted.js +10 -4
- package/dist/client/hosted.js.map +1 -1
- package/dist/client/index.d.ts +5 -3
- package/dist/client/index.d.ts.map +1 -1
- package/dist/client/index.js +2 -0
- package/dist/client/index.js.map +1 -1
- package/dist/client/messages.d.ts +25 -3
- package/dist/client/messages.d.ts.map +1 -1
- package/dist/client/messages.js +111 -20
- package/dist/client/messages.js.map +1 -1
- package/dist/client/receive-admission.d.ts +58 -0
- package/dist/client/receive-admission.d.ts.map +1 -0
- package/dist/client/receive-admission.js +78 -0
- package/dist/client/receive-admission.js.map +1 -0
- package/dist/client/receive-expiry.d.ts +31 -0
- package/dist/client/receive-expiry.d.ts.map +1 -0
- package/dist/client/receive-expiry.js +35 -0
- package/dist/client/receive-expiry.js.map +1 -0
- package/dist/client/receive-hook-bound.d.ts +50 -0
- package/dist/client/receive-hook-bound.d.ts.map +1 -0
- package/dist/client/receive-hook-bound.js +115 -0
- package/dist/client/receive-hook-bound.js.map +1 -0
- package/dist/client/receive-queue.d.ts +299 -0
- package/dist/client/receive-queue.d.ts.map +1 -0
- package/dist/client/receive-queue.js +1420 -0
- package/dist/client/receive-queue.js.map +1 -0
- package/dist/client/receive-work-seed.d.ts +54 -0
- package/dist/client/receive-work-seed.d.ts.map +1 -0
- package/dist/client/receive-work-seed.js +116 -0
- package/dist/client/receive-work-seed.js.map +1 -0
- package/dist/client/recovery-driver.d.ts +25 -0
- package/dist/client/recovery-driver.d.ts.map +1 -0
- package/dist/client/recovery-driver.js +121 -0
- package/dist/client/recovery-driver.js.map +1 -0
- package/dist/client/relay-acceptance.d.ts +20 -7
- package/dist/client/relay-acceptance.d.ts.map +1 -1
- package/dist/client/relay-acceptance.js +30 -12
- package/dist/client/relay-acceptance.js.map +1 -1
- package/dist/client/relay-device-refusal.d.ts +18 -0
- package/dist/client/relay-device-refusal.d.ts.map +1 -1
- package/dist/client/relay-device-refusal.js +31 -0
- package/dist/client/relay-device-refusal.js.map +1 -1
- package/dist/client/relay-sealed-route.d.ts +36 -0
- package/dist/client/relay-sealed-route.d.ts.map +1 -0
- package/dist/client/relay-sealed-route.js +45 -0
- package/dist/client/relay-sealed-route.js.map +1 -0
- package/dist/client/relay-subscription.d.ts +56 -13
- package/dist/client/relay-subscription.d.ts.map +1 -1
- package/dist/client/relay-subscription.js +193 -123
- package/dist/client/relay-subscription.js.map +1 -1
- package/dist/client/resendable-content.d.ts +98 -0
- package/dist/client/resendable-content.d.ts.map +1 -0
- package/dist/client/resendable-content.js +136 -0
- package/dist/client/resendable-content.js.map +1 -0
- package/dist/client/retry-family.d.ts +57 -10
- package/dist/client/retry-family.d.ts.map +1 -1
- package/dist/client/retry-family.js +54 -12
- package/dist/client/retry-family.js.map +1 -1
- package/dist/client/retry-request-envelope.d.ts +107 -8
- package/dist/client/retry-request-envelope.d.ts.map +1 -1
- package/dist/client/retry-request-envelope.js +172 -23
- package/dist/client/retry-request-envelope.js.map +1 -1
- package/dist/client/retry-request-lifecycle.d.ts +70 -14
- package/dist/client/retry-request-lifecycle.d.ts.map +1 -1
- package/dist/client/retry-request-lifecycle.js +162 -32
- package/dist/client/retry-request-lifecycle.js.map +1 -1
- package/dist/client/retry-terminal-recovery.d.ts +100 -0
- package/dist/client/retry-terminal-recovery.d.ts.map +1 -0
- package/dist/client/retry-terminal-recovery.js +164 -0
- package/dist/client/retry-terminal-recovery.js.map +1 -0
- package/dist/client/retry-utils.d.ts +27 -0
- package/dist/client/retry-utils.d.ts.map +1 -1
- package/dist/client/retry-utils.js +46 -0
- package/dist/client/retry-utils.js.map +1 -1
- package/dist/client/retry.d.ts +100 -12
- package/dist/client/retry.d.ts.map +1 -1
- package/dist/client/retry.js +619 -116
- package/dist/client/retry.js.map +1 -1
- package/dist/client/sealed-sender.d.ts +23 -6
- package/dist/client/sealed-sender.d.ts.map +1 -1
- package/dist/client/sealed-sender.js +30 -6
- package/dist/client/sealed-sender.js.map +1 -1
- package/dist/client/sessions.d.ts +2 -2
- package/dist/client/sessions.js +2 -2
- package/dist/client/signal-service-cipher.d.ts +726 -19
- package/dist/client/signal-service-cipher.d.ts.map +1 -1
- package/dist/client/signal-service-cipher.js +2260 -342
- package/dist/client/signal-service-cipher.js.map +1 -1
- package/dist/client/state.d.ts +5 -0
- package/dist/client/state.d.ts.map +1 -1
- package/dist/client/state.js +11 -1
- package/dist/client/state.js.map +1 -1
- package/dist/client/storage-protection.d.ts +64 -0
- package/dist/client/storage-protection.d.ts.map +1 -0
- package/dist/client/storage-protection.js +150 -0
- package/dist/client/storage-protection.js.map +1 -0
- package/dist/client/types.d.ts +149 -15
- package/dist/client/types.d.ts.map +1 -1
- package/dist/client/types.js +1 -1
- package/dist/client/types.js.map +1 -1
- package/dist/device/constants.d.ts +0 -5
- package/dist/device/constants.d.ts.map +1 -1
- package/dist/device/constants.js +0 -5
- package/dist/device/constants.js.map +1 -1
- package/dist/device/expo/index.d.ts +4 -17
- package/dist/device/expo/index.d.ts.map +1 -1
- package/dist/device/expo/index.js +4 -23
- package/dist/device/expo/index.js.map +1 -1
- package/dist/device/index.d.ts +0 -2
- package/dist/device/index.d.ts.map +1 -1
- package/dist/device/index.js +0 -7
- package/dist/device/index.js.map +1 -1
- package/dist/device/lifecycle/manager.d.ts +5 -4
- package/dist/device/lifecycle/manager.d.ts.map +1 -1
- package/dist/device/lifecycle/manager.js +16 -16
- package/dist/device/lifecycle/manager.js.map +1 -1
- package/dist/device/lifecycle/types.d.ts +2 -2
- package/dist/device/lifecycle/types.d.ts.map +1 -1
- package/dist/device/react-native/index.d.ts +4 -15
- package/dist/device/react-native/index.d.ts.map +1 -1
- package/dist/device/react-native/index.js +4 -21
- package/dist/device/react-native/index.js.map +1 -1
- package/dist/device/types.d.ts +1 -1
- package/dist/groups/index.d.ts +1 -1
- package/dist/groups/index.d.ts.map +1 -1
- package/dist/index.d.ts +8 -6
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -1
- package/dist/index.js.map +1 -1
- package/dist/internal/crypto/ec/x25519-validation.d.ts +0 -1
- package/dist/internal/crypto/ec/x25519-validation.d.ts.map +1 -1
- package/dist/internal/crypto/ec/x25519-validation.js +0 -1
- package/dist/internal/crypto/ec/x25519-validation.js.map +1 -1
- package/dist/internal/crypto/validation.d.ts +2 -2
- package/dist/internal/groups/index.d.ts +1 -0
- package/dist/internal/groups/index.d.ts.map +1 -1
- package/dist/internal/groups/index.js +1 -0
- package/dist/internal/groups/index.js.map +1 -1
- package/dist/internal/groups/manager.d.ts +37 -16
- package/dist/internal/groups/manager.d.ts.map +1 -1
- package/dist/internal/groups/manager.js +46 -1
- package/dist/internal/groups/manager.js.map +1 -1
- package/dist/internal/groups/receive-record.d.ts +78 -0
- package/dist/internal/groups/receive-record.d.ts.map +1 -0
- package/dist/internal/groups/receive-record.js +43 -0
- package/dist/internal/groups/receive-record.js.map +1 -0
- package/dist/internal/groups/sdk-store.d.ts +27 -3
- package/dist/internal/groups/sdk-store.d.ts.map +1 -1
- package/dist/internal/groups/sdk-store.js +151 -19
- package/dist/internal/groups/sdk-store.js.map +1 -1
- package/dist/internal/groups/wire.d.ts +12 -1
- package/dist/internal/groups/wire.d.ts.map +1 -1
- package/dist/internal/groups/wire.js +36 -0
- package/dist/internal/groups/wire.js.map +1 -1
- package/dist/internal/manager/index.d.ts +1 -1
- package/dist/internal/manager/manager.d.ts +20 -19
- package/dist/internal/manager/manager.d.ts.map +1 -1
- package/dist/internal/manager/manager.js +56 -39
- package/dist/internal/manager/manager.js.map +1 -1
- package/dist/internal/protocol/double-ratchet/chains.d.ts +4 -18
- package/dist/internal/protocol/double-ratchet/chains.d.ts.map +1 -1
- package/dist/internal/protocol/double-ratchet/chains.js +23 -74
- package/dist/internal/protocol/double-ratchet/chains.js.map +1 -1
- package/dist/internal/protocol/double-ratchet/index.d.ts +1 -1
- package/dist/internal/protocol/double-ratchet/index.d.ts.map +1 -1
- package/dist/internal/protocol/double-ratchet/index.js +1 -1
- package/dist/internal/protocol/double-ratchet/index.js.map +1 -1
- package/dist/internal/protocol/double-ratchet/ratchet.d.ts +5 -7
- package/dist/internal/protocol/double-ratchet/ratchet.d.ts.map +1 -1
- package/dist/internal/protocol/double-ratchet/ratchet.js +4 -6
- package/dist/internal/protocol/double-ratchet/ratchet.js.map +1 -1
- package/dist/internal/protocol/pqxdh/pqxdh.d.ts.map +1 -1
- package/dist/internal/protocol/pqxdh/pqxdh.js +2 -1
- package/dist/internal/protocol/pqxdh/pqxdh.js.map +1 -1
- package/dist/internal/protocol/sealed-sender/types.d.ts +6 -8
- package/dist/internal/protocol/sealed-sender/types.d.ts.map +1 -1
- package/dist/internal/protocol/sealed-sender/types.js +8 -9
- package/dist/internal/protocol/sealed-sender/types.js.map +1 -1
- package/dist/internal/protocol/sender-keys/handoff-ledger.d.ts +110 -0
- package/dist/internal/protocol/sender-keys/handoff-ledger.d.ts.map +1 -0
- package/dist/internal/protocol/sender-keys/handoff-ledger.js +124 -0
- package/dist/internal/protocol/sender-keys/handoff-ledger.js.map +1 -0
- package/dist/internal/protocol/sender-keys/manager.d.ts +71 -62
- package/dist/internal/protocol/sender-keys/manager.d.ts.map +1 -1
- package/dist/internal/protocol/sender-keys/manager.js +228 -175
- package/dist/internal/protocol/sender-keys/manager.js.map +1 -1
- package/dist/internal/protocol/spqr/index.d.ts +2 -2
- package/dist/internal/protocol/spqr/index.d.ts.map +1 -1
- package/dist/internal/protocol/spqr/index.js +2 -2
- package/dist/internal/protocol/spqr/index.js.map +1 -1
- package/dist/internal/protocol/spqr/serialize.d.ts +9 -1
- package/dist/internal/protocol/spqr/serialize.d.ts.map +1 -1
- package/dist/internal/protocol/spqr/serialize.js +56 -16
- package/dist/internal/protocol/spqr/serialize.js.map +1 -1
- package/dist/internal/protocol/spqr/spqr.d.ts +1 -14
- package/dist/internal/protocol/spqr/spqr.d.ts.map +1 -1
- package/dist/internal/protocol/spqr/spqr.js +54 -42
- package/dist/internal/protocol/spqr/spqr.js.map +1 -1
- package/dist/internal/protocol/spqr/validate.d.ts +26 -6
- package/dist/internal/protocol/spqr/validate.d.ts.map +1 -1
- package/dist/internal/protocol/spqr/validate.js +49 -21
- package/dist/internal/protocol/spqr/validate.js.map +1 -1
- package/dist/internal/sesame/index.d.ts +1 -1
- package/dist/internal/sesame/index.d.ts.map +1 -1
- package/dist/internal/sesame/index.js.map +1 -1
- package/dist/internal/sesame/manager.d.ts +66 -13
- package/dist/internal/sesame/manager.d.ts.map +1 -1
- package/dist/internal/sesame/manager.js +221 -87
- package/dist/internal/sesame/manager.js.map +1 -1
- package/dist/internal/sesame/types.d.ts +95 -17
- package/dist/internal/sesame/types.d.ts.map +1 -1
- package/dist/internal/sesame/types.js +17 -0
- package/dist/internal/sesame/types.js.map +1 -1
- package/dist/internal/session/builder.d.ts +5 -5
- package/dist/internal/session/builder.d.ts.map +1 -1
- package/dist/internal/session/builder.js +12 -17
- package/dist/internal/session/builder.js.map +1 -1
- package/dist/internal/session/cipher.d.ts +13 -11
- package/dist/internal/session/cipher.d.ts.map +1 -1
- package/dist/internal/session/cipher.js +40 -22
- package/dist/internal/session/cipher.js.map +1 -1
- package/dist/internal/session/factory.d.ts +5 -5
- package/dist/internal/session/factory.d.ts.map +1 -1
- package/dist/internal/session/factory.js +4 -4
- package/dist/internal/session/factory.js.map +1 -1
- package/dist/internal/session/handshake.d.ts +14 -16
- package/dist/internal/session/handshake.d.ts.map +1 -1
- package/dist/internal/session/handshake.js +18 -75
- package/dist/internal/session/handshake.js.map +1 -1
- package/dist/internal/session/index.d.ts +1 -1
- package/dist/internal/session/index.js +1 -1
- package/dist/internal/session/record-locks.d.ts +17 -6
- package/dist/internal/session/record-locks.d.ts.map +1 -1
- package/dist/internal/session/record-locks.js +43 -7
- package/dist/internal/session/record-locks.js.map +1 -1
- package/dist/internal/session/session-resolver.d.ts +1 -1
- package/dist/internal/session/session-resolver.js +1 -1
- package/dist/internal/session/state.d.ts +2 -2
- package/dist/internal/session/state.js +1 -1
- package/dist/internal/session/types.d.ts +4 -12
- package/dist/internal/session/types.d.ts.map +1 -1
- package/dist/internal/session/types.js +1 -1
- package/dist/keys/generation.d.ts +2 -2
- package/dist/keys/generation.js +2 -2
- package/dist/keys/types.d.ts +5 -5
- package/dist/keys/types.d.ts.map +1 -1
- package/dist/keys/types.js +1 -1
- package/dist/layers.d.ts +1 -1
- package/dist/layers.js +2 -2
- package/dist/layers.js.map +1 -1
- package/dist/local/store/expo/adapter.d.ts.map +1 -1
- package/dist/local/store/expo/adapter.js +12 -8
- package/dist/local/store/expo/adapter.js.map +1 -1
- package/dist/local/store/key-value/adapter.d.ts +76 -10
- package/dist/local/store/key-value/adapter.d.ts.map +1 -1
- package/dist/local/store/key-value/adapter.js +367 -61
- package/dist/local/store/key-value/adapter.js.map +1 -1
- package/dist/local/store/key-value/backend-conformance.d.ts.map +1 -1
- package/dist/local/store/key-value/backend-conformance.js +74 -0
- package/dist/local/store/key-value/backend-conformance.js.map +1 -1
- package/dist/local/store/key-value/batch.d.ts +2 -0
- package/dist/local/store/key-value/batch.d.ts.map +1 -1
- package/dist/local/store/key-value/batch.js +26 -0
- package/dist/local/store/key-value/batch.js.map +1 -1
- package/dist/local/store/key-value/receive-work.d.ts +55 -0
- package/dist/local/store/key-value/receive-work.d.ts.map +1 -0
- package/dist/local/store/key-value/receive-work.js +162 -0
- package/dist/local/store/key-value/receive-work.js.map +1 -0
- package/dist/local/store/key-value/send-log.d.ts +61 -0
- package/dist/local/store/key-value/send-log.d.ts.map +1 -0
- package/dist/local/store/key-value/send-log.js +430 -0
- package/dist/local/store/key-value/send-log.js.map +1 -0
- package/dist/local/store/key-value/sender-key-handoff.d.ts +68 -0
- package/dist/local/store/key-value/sender-key-handoff.d.ts.map +1 -0
- package/dist/local/store/key-value/sender-key-handoff.js +189 -0
- package/dist/local/store/key-value/sender-key-handoff.js.map +1 -0
- package/dist/local/store/key-value/storage.d.ts +15 -0
- package/dist/local/store/key-value/storage.d.ts.map +1 -1
- package/dist/local/store/keyed-index.d.ts +23 -0
- package/dist/local/store/keyed-index.d.ts.map +1 -0
- package/dist/local/store/keyed-index.js +41 -0
- package/dist/local/store/keyed-index.js.map +1 -0
- package/dist/local/store/memory/adapter.d.ts +44 -12
- package/dist/local/store/memory/adapter.d.ts.map +1 -1
- package/dist/local/store/memory/adapter.js +197 -46
- package/dist/local/store/memory/adapter.js.map +1 -1
- package/dist/local/store/memory/send-log.d.ts +42 -0
- package/dist/local/store/memory/send-log.d.ts.map +1 -0
- package/dist/local/store/memory/send-log.js +190 -0
- package/dist/local/store/memory/send-log.js.map +1 -0
- package/dist/local/store/node/adapter.d.ts.map +1 -1
- package/dist/local/store/node/adapter.js +8 -6
- package/dist/local/store/node/adapter.js.map +1 -1
- package/dist/local/store/react-native/adapter.d.ts.map +1 -1
- package/dist/local/store/react-native/adapter.js +12 -8
- package/dist/local/store/react-native/adapter.js.map +1 -1
- package/dist/local/store/receive-work.d.ts +87 -0
- package/dist/local/store/receive-work.d.ts.map +1 -0
- package/dist/local/store/receive-work.js +204 -0
- package/dist/local/store/receive-work.js.map +1 -0
- package/dist/local/store/received-content.d.ts +3 -3
- package/dist/local/store/received-content.d.ts.map +1 -1
- package/dist/local/store/received-content.js +2 -11
- package/dist/local/store/received-content.js.map +1 -1
- package/dist/local/store/reliability.d.ts +317 -18
- package/dist/local/store/reliability.d.ts.map +1 -1
- package/dist/local/store/reliability.js +371 -46
- package/dist/local/store/reliability.js.map +1 -1
- package/dist/local/store/send-log-order.d.ts +15 -0
- package/dist/local/store/send-log-order.d.ts.map +1 -0
- package/dist/local/store/send-log-order.js +24 -0
- package/dist/local/store/send-log-order.js.map +1 -0
- package/dist/local/store/sender-key-handoff-index.d.ts +38 -0
- package/dist/local/store/sender-key-handoff-index.d.ts.map +1 -0
- package/dist/local/store/sender-key-handoff-index.js +101 -0
- package/dist/local/store/sender-key-handoff-index.js.map +1 -0
- package/dist/local/store/sender-key-handoff-table.d.ts +29 -0
- package/dist/local/store/sender-key-handoff-table.d.ts.map +1 -0
- package/dist/local/store/sender-key-handoff-table.js +97 -0
- package/dist/local/store/sender-key-handoff-table.js.map +1 -0
- package/dist/local/store/sqlite/encryption.d.ts +8 -1
- package/dist/local/store/sqlite/encryption.d.ts.map +1 -1
- package/dist/local/store/sqlite/encryption.js +9 -0
- package/dist/local/store/sqlite/encryption.js.map +1 -1
- package/dist/local/store/sqlite/key-storage/index.d.ts +25 -4
- package/dist/local/store/sqlite/key-storage/index.d.ts.map +1 -1
- package/dist/local/store/sqlite/key-storage/index.js +68 -7
- package/dist/local/store/sqlite/key-storage/index.js.map +1 -1
- package/dist/local/store/sqlite/key-storage/message-records.d.ts +16 -4
- package/dist/local/store/sqlite/key-storage/message-records.d.ts.map +1 -1
- package/dist/local/store/sqlite/key-storage/message-records.js +49 -6
- package/dist/local/store/sqlite/key-storage/message-records.js.map +1 -1
- package/dist/local/store/sqlite/key-storage/metadata.d.ts +8 -7
- package/dist/local/store/sqlite/key-storage/metadata.d.ts.map +1 -1
- package/dist/local/store/sqlite/key-storage/metadata.js +17 -15
- package/dist/local/store/sqlite/key-storage/metadata.js.map +1 -1
- package/dist/local/store/sqlite/key-storage/receive-work.d.ts +27 -0
- package/dist/local/store/sqlite/key-storage/receive-work.d.ts.map +1 -0
- package/dist/local/store/sqlite/key-storage/receive-work.js +98 -0
- package/dist/local/store/sqlite/key-storage/receive-work.js.map +1 -0
- package/dist/local/store/sqlite/key-storage/send-log.d.ts +27 -0
- package/dist/local/store/sqlite/key-storage/send-log.d.ts.map +1 -0
- package/dist/local/store/sqlite/key-storage/send-log.js +178 -0
- package/dist/local/store/sqlite/key-storage/send-log.js.map +1 -0
- package/dist/local/store/sqlite/key-storage/sender-key-handoff.d.ts +27 -0
- package/dist/local/store/sqlite/key-storage/sender-key-handoff.d.ts.map +1 -0
- package/dist/local/store/sqlite/key-storage/sender-key-handoff.js +75 -0
- package/dist/local/store/sqlite/key-storage/sender-key-handoff.js.map +1 -0
- package/dist/local/store/sqlite/key-storage/session-trust.d.ts +2 -2
- package/dist/local/store/sqlite/key-storage/session-trust.js +5 -5
- package/dist/local/store/sqlite/key-storage/session-trust.js.map +1 -1
- package/dist/local/store/sqlite/migrations.d.ts.map +1 -1
- package/dist/local/store/sqlite/migrations.js +101 -0
- package/dist/local/store/sqlite/migrations.js.map +1 -1
- package/dist/local/store/sqlite/models/index.d.ts +2 -1
- package/dist/local/store/sqlite/models/index.d.ts.map +1 -1
- package/dist/local/store/sqlite/models/index.js +5 -1
- package/dist/local/store/sqlite/models/index.js.map +1 -1
- package/dist/local/store/sqlite/models/message-record.d.ts +15 -0
- package/dist/local/store/sqlite/models/message-record.d.ts.map +1 -1
- package/dist/local/store/sqlite/models/message-record.js +24 -0
- package/dist/local/store/sqlite/models/message-record.js.map +1 -1
- package/dist/local/store/sqlite/models/send-log.d.ts +51 -0
- package/dist/local/store/sqlite/models/send-log.d.ts.map +1 -0
- package/dist/local/store/sqlite/models/send-log.js +206 -0
- package/dist/local/store/sqlite/models/send-log.js.map +1 -0
- package/dist/local/store/sqlite/open-store.d.ts +9 -1
- package/dist/local/store/sqlite/open-store.d.ts.map +1 -1
- package/dist/local/store/sqlite/open-store.js +20 -1
- package/dist/local/store/sqlite/open-store.js.map +1 -1
- package/dist/local/store/sqlite/schema.d.ts +34 -1
- package/dist/local/store/sqlite/schema.d.ts.map +1 -1
- package/dist/local/store/sqlite/schema.js +14 -0
- package/dist/local/store/sqlite/schema.js.map +1 -1
- package/dist/local/store/sqlite/store.d.ts +61 -11
- package/dist/local/store/sqlite/store.d.ts.map +1 -1
- package/dist/local/store/sqlite/store.js +191 -27
- package/dist/local/store/sqlite/store.js.map +1 -1
- package/dist/local/store/web/adapter.d.ts +76 -8
- package/dist/local/store/web/adapter.d.ts.map +1 -1
- package/dist/local/store/web/adapter.js +579 -127
- package/dist/local/store/web/adapter.js.map +1 -1
- package/dist/local/store/web/receive-work.d.ts +57 -0
- package/dist/local/store/web/receive-work.d.ts.map +1 -0
- package/dist/local/store/web/receive-work.js +99 -0
- package/dist/local/store/web/receive-work.js.map +1 -0
- package/dist/local/store/web/send-log.d.ts +92 -0
- package/dist/local/store/web/send-log.d.ts.map +1 -0
- package/dist/local/store/web/send-log.js +267 -0
- package/dist/local/store/web/send-log.js.map +1 -0
- package/dist/local/store/web/sender-key-handoff.d.ts +81 -0
- package/dist/local/store/web/sender-key-handoff.d.ts.map +1 -0
- package/dist/local/store/web/sender-key-handoff.js +156 -0
- package/dist/local/store/web/sender-key-handoff.js.map +1 -0
- package/dist/local/store/web-sqlite/adapter.d.ts +2 -0
- package/dist/local/store/web-sqlite/adapter.d.ts.map +1 -1
- package/dist/local/store/web-sqlite/adapter.js +12 -6
- package/dist/local/store/web-sqlite/adapter.js.map +1 -1
- package/dist/local/vault/custody.d.ts +8 -0
- package/dist/local/vault/custody.d.ts.map +1 -0
- package/dist/local/vault/custody.js +9 -0
- package/dist/local/vault/custody.js.map +1 -0
- package/dist/local/vault/electron-safe-storage.d.ts +3 -1
- package/dist/local/vault/electron-safe-storage.d.ts.map +1 -1
- package/dist/local/vault/electron-safe-storage.js +2 -0
- package/dist/local/vault/electron-safe-storage.js.map +1 -1
- package/dist/local/vault/expo-secure-store.d.ts +3 -1
- package/dist/local/vault/expo-secure-store.d.ts.map +1 -1
- package/dist/local/vault/expo-secure-store.js +2 -0
- package/dist/local/vault/expo-secure-store.js.map +1 -1
- package/dist/local/vault/indexed-db.d.ts +3 -1
- package/dist/local/vault/indexed-db.d.ts.map +1 -1
- package/dist/local/vault/indexed-db.js +2 -0
- package/dist/local/vault/indexed-db.js.map +1 -1
- package/dist/local/vault/react-native-keychain.d.ts +3 -1
- package/dist/local/vault/react-native-keychain.d.ts.map +1 -1
- package/dist/local/vault/react-native-keychain.js +2 -0
- package/dist/local/vault/react-native-keychain.js.map +1 -1
- package/dist/remote/relay/device-set.d.ts +94 -0
- package/dist/remote/relay/device-set.d.ts.map +1 -0
- package/dist/remote/relay/device-set.js +156 -0
- package/dist/remote/relay/device-set.js.map +1 -0
- package/dist/remote/relay/types.d.ts +92 -107
- package/dist/remote/relay/types.d.ts.map +1 -1
- package/dist/safety/core.d.ts +15 -6
- package/dist/safety/core.d.ts.map +1 -1
- package/dist/safety/core.js +41 -27
- package/dist/safety/core.js.map +1 -1
- package/dist/safety/index.d.ts +2 -1
- package/dist/safety/index.d.ts.map +1 -1
- package/dist/safety/index.js +12 -18
- package/dist/safety/index.js.map +1 -1
- package/dist/types/api.d.ts +707 -62
- package/dist/types/api.d.ts.map +1 -1
- package/dist/types/errors.d.ts +14 -33
- package/dist/types/errors.d.ts.map +1 -1
- package/dist/types/errors.js +14 -24
- package/dist/types/errors.js.map +1 -1
- package/dist/types/messages.d.ts +2 -2
- package/dist/types/messages.js +1 -1
- package/dist/types/protocol-config.d.ts +175 -42
- package/dist/types/protocol-config.d.ts.map +1 -1
- package/dist/types/protocol-config.js +19 -38
- package/dist/types/protocol-config.js.map +1 -1
- package/dist/types/protocol-constants.d.ts +6 -6
- package/dist/types/protocol-constants.js +6 -6
- package/dist/types/session.d.ts +7 -7
- package/dist/types/session.d.ts.map +1 -1
- package/dist/types/session.js +39 -21
- package/dist/types/session.js.map +1 -1
- package/dist/username/link.d.ts +2 -2
- package/dist/username/link.js +2 -2
- package/dist/utils/origin-lock.d.ts +45 -0
- package/dist/utils/origin-lock.d.ts.map +1 -0
- package/dist/utils/origin-lock.js +80 -0
- package/dist/utils/origin-lock.js.map +1 -0
- package/docs/ASSURANCE.md +6 -6
- package/docs/CLIENT_COMPOSITION.md +2 -2
- package/docs/DEVIATIONS.md +677 -182
- package/docs/E2EE.md +1 -1
- package/docs/ERROR_HANDLING.md +165 -2
- package/docs/GETTING_STARTED.md +7 -4
- package/docs/INTERFACES.md +1 -1
- package/docs/PACKAGE_SURFACE.md +6 -5
- package/docs/PROTOCOL_POLICY.md +102 -22
- package/docs/RECIPES.md +3 -15
- package/docs/SECURITY.md +90 -5
- package/keys/README.md +3 -3
- package/local/store/README.md +78 -14
- package/local/store/key-value/README.md +14 -3
- package/local/store/node/README.md +8 -3
- package/local/store/web/README.md +9 -0
- package/local/store/web-sqlite/README.md +14 -2
- package/local/vault/README.md +21 -0
- package/package.json +1 -6
- package/remote/README.md +0 -1
- package/remote/relay/README.md +2 -2
- package/dist/device/provisioning.d.ts +0 -242
- package/dist/device/provisioning.d.ts.map +0 -1
- package/dist/device/provisioning.js +0 -421
- package/dist/device/provisioning.js.map +0 -1
- package/dist/internal/protocol/x3dh/index.d.ts +0 -15
- package/dist/internal/protocol/x3dh/index.d.ts.map +0 -1
- package/dist/internal/protocol/x3dh/index.js +0 -13
- package/dist/internal/protocol/x3dh/index.js.map +0 -1
- package/dist/internal/protocol/x3dh/x3dh.d.ts +0 -131
- package/dist/internal/protocol/x3dh/x3dh.d.ts.map +0 -1
- package/dist/internal/protocol/x3dh/x3dh.js +0 -261
- package/dist/internal/protocol/x3dh/x3dh.js.map +0 -1
|
@@ -1,11 +1,18 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Wire form of a retry request.
|
|
3
3
|
*
|
|
4
|
-
* A retry request
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
*
|
|
4
|
+
* A retry request is a mailbox envelope with `messageType: 'retry_request'`.
|
|
5
|
+
* The envelope sender is the requester, so the payload never carries it.
|
|
6
|
+
* The `ciphertext` field holds canonical base64 of a small UTF-8 JSON
|
|
7
|
+
* payload. The payload is not ratchet-encrypted. It holds only what the
|
|
8
|
+
* requester knows about the failed message.
|
|
9
|
+
*
|
|
10
|
+
* The request record stores the identified form of the envelope.
|
|
11
|
+
* `retryRequestPost` seals it at each post when an access key of the target
|
|
12
|
+
* permits it: the seal holds the same payload as `PLAINTEXT_CONTENT`, and
|
|
13
|
+
* the sender certificate in the seal names the requester. Otherwise the
|
|
14
|
+
* post is identified, and the relay stamps the requester, only when the
|
|
15
|
+
* sealed sender delivery mode permits it.
|
|
9
16
|
*
|
|
10
17
|
* The requester keeps one request record for each failed envelope. The record
|
|
11
18
|
* holds a random retry ID, and every wire ID of the request family derives from
|
|
@@ -16,19 +23,29 @@
|
|
|
16
23
|
* The requester stores each request envelope before the post. After a post
|
|
17
24
|
* that fails with a retryable class, the retry request scheduler posts the
|
|
18
25
|
* stored envelope again, until the deadline of the record.
|
|
26
|
+
*
|
|
27
|
+
* A relay can assign its own envelope ID. The payload then also carries the
|
|
28
|
+
* client message ID of the failed envelope, the ID that the sender chose. A
|
|
29
|
+
* request without a ratchet key names a failed sender-key message.
|
|
19
30
|
*/
|
|
31
|
+
import { SealedSenderAuthError } from '../types/errors.js';
|
|
20
32
|
import { RetryReason } from '../internal/sesame/types.js';
|
|
21
33
|
import { base64ToBytes, bytesToBase64, generateUuidV4, stringToBytes } from '../internal/crypto/index.js';
|
|
22
34
|
import { utf8Decode } from '../internal/platform/index.js';
|
|
23
|
-
import { isRetryId,
|
|
35
|
+
import { isRetryId, RETRY_REQUEST_DEADLINE_MS, retryAttemptClientMessageId, retryRequestClientMessageId, storeRetryRequest, updateRetryRequest, } from '../local/store/reliability.js';
|
|
24
36
|
import { classifyRetryRequestPostFailure, relayOperationRefusal, } from './relay-acceptance.js';
|
|
25
37
|
import { rethrowRelayWorkStopped } from './relay-work.js';
|
|
38
|
+
import { isStaleDeviceRefusal } from './relay-device-refusal.js';
|
|
39
|
+
import { MAX_RETRY_RESPONSES_PER_MESSAGE } from './constants.js';
|
|
26
40
|
/** The payload version that this client writes and reads. */
|
|
27
41
|
const RETRY_REQUEST_PAYLOAD_VERSION = 1;
|
|
28
42
|
/** The decoder refuses a longer `ciphertext` value before it decodes it. */
|
|
29
43
|
export const MAX_RETRY_REQUEST_CIPHERTEXT_LENGTH = 2_048;
|
|
30
|
-
/**
|
|
31
|
-
|
|
44
|
+
/**
|
|
45
|
+
* The Relay refuses a longer message ID, so a failed envelope ID and a
|
|
46
|
+
* failed client message ID are 1 to this many characters.
|
|
47
|
+
*/
|
|
48
|
+
const MAX_MESSAGE_ID_LENGTH = 128;
|
|
32
49
|
/** The decoded ratchet key is 1 to this many bytes. */
|
|
33
50
|
const MAX_RATCHET_KEY_BYTES = 64;
|
|
34
51
|
const RETRY_REASONS = new Set(Object.values(RetryReason));
|
|
@@ -50,6 +67,10 @@ export async function retryRequestEnvelope(request, sender, failed) {
|
|
|
50
67
|
timestamp: request.timestamp,
|
|
51
68
|
...(request.ratchetKey === undefined ? {} : { ratchetKey: request.ratchetKey }),
|
|
52
69
|
...(failed && { failedEnvelopeId: failed.failedEnvelopeId, retryId: failed.retryId }),
|
|
70
|
+
// The sender chose this ID. A value that the decoder refuses is left out.
|
|
71
|
+
...(isMessageId(request.failedClientMessageId) && {
|
|
72
|
+
failedClientMessageId: request.failedClientMessageId,
|
|
73
|
+
}),
|
|
53
74
|
};
|
|
54
75
|
return {
|
|
55
76
|
targetUserId: request.originalSenderUserId,
|
|
@@ -65,6 +86,85 @@ export async function retryRequestEnvelope(request, sender, failed) {
|
|
|
65
86
|
: await generateUuidV4(),
|
|
66
87
|
};
|
|
67
88
|
}
|
|
89
|
+
/**
|
|
90
|
+
* Make the function that posts one retry request envelope, by the sealed
|
|
91
|
+
* sender delivery mode, as a receipt goes.
|
|
92
|
+
*
|
|
93
|
+
* With an access key of the target, the post is sealed: the Relay sees the
|
|
94
|
+
* target, the timing and the size, and not the requester. The sealed post
|
|
95
|
+
* keeps the client message ID and the timestamp of the envelope, so the
|
|
96
|
+
* Relay deduplicates the attempt by the same operation as an identified
|
|
97
|
+
* post. When the Relay refuses the access key, the post goes identified
|
|
98
|
+
* only when the delivery mode permits it. When `seal` resolves to
|
|
99
|
+
* undefined, the post goes identified. In `'required'` mode `seal` throws
|
|
100
|
+
* instead, and nothing goes identified. The caller classifies each error
|
|
101
|
+
* of the post.
|
|
102
|
+
*
|
|
103
|
+
* When the Relay refuses the post as `STALE_DEVICE`, the target device has
|
|
104
|
+
* a new registration. The post then refreshes the session with the device
|
|
105
|
+
* once from a fresh bundle, and posts the same envelope again, sealed and
|
|
106
|
+
* named with the new session, as a receipt goes. The request is plaintext,
|
|
107
|
+
* so nothing is encrypted again. A refresh that finds no bundle,
|
|
108
|
+
* or a second refusal, throws the refusal. A refresh that fails for another
|
|
109
|
+
* reason throws StaleSessionRefreshError, which classifies as a transport
|
|
110
|
+
* outage, so the next post refreshes again.
|
|
111
|
+
*
|
|
112
|
+
* @param seal - Seals the payload. Without it, each post is identified.
|
|
113
|
+
* @param relay - Posts the sealed envelope.
|
|
114
|
+
* @param sendIdentified - Posts the identified envelope.
|
|
115
|
+
* @param registrationOf - The registration ID of the current session with
|
|
116
|
+
* the target device. The identified envelope names it, as the sealed body
|
|
117
|
+
* does, so the Relay refuses the post to a reinstalled device. With no
|
|
118
|
+
* session, or without this function, the envelope names none.
|
|
119
|
+
* @param refreshStaleSession - Refreshes the session with a refused device.
|
|
120
|
+
* Resolves to true when the new session is ready. Without it, a stale
|
|
121
|
+
* refusal throws.
|
|
122
|
+
*/
|
|
123
|
+
export function retryRequestPost(seal, relay, sendIdentified, registrationOf, refreshStaleSession) {
|
|
124
|
+
const post = async (envelope) => {
|
|
125
|
+
const payloadBase64 = typeof envelope.ciphertext === 'string'
|
|
126
|
+
? envelope.ciphertext
|
|
127
|
+
: bytesToBase64(envelope.ciphertext);
|
|
128
|
+
const sealed = await seal?.(envelope.targetUserId, envelope.targetDeviceId, payloadBase64);
|
|
129
|
+
if (sealed) {
|
|
130
|
+
// The seal resolves only when the relay has anonymous delivery.
|
|
131
|
+
if (!relay?.sendMultiRecipientUnidentified) {
|
|
132
|
+
throw new Error('Relay has no anonymous delivery for a sealed retry request');
|
|
133
|
+
}
|
|
134
|
+
try {
|
|
135
|
+
return await relay.sendMultiRecipientUnidentified(sealed.sentMessageBase64, sealed.auth, envelope.timestamp, envelope.deliveryClass, [envelope.targetUserId], envelope.clientMessageId);
|
|
136
|
+
}
|
|
137
|
+
catch (error) {
|
|
138
|
+
if (!(error instanceof SealedSenderAuthError) || !sealed.identifiedFallback)
|
|
139
|
+
throw error;
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
const recipientRegistrationId = await registrationOf?.(envelope.targetUserId, envelope.targetDeviceId);
|
|
143
|
+
return sendIdentified(recipientRegistrationId === undefined ? envelope : { ...envelope, recipientRegistrationId });
|
|
144
|
+
};
|
|
145
|
+
return async (envelope) => {
|
|
146
|
+
try {
|
|
147
|
+
return await post(envelope);
|
|
148
|
+
}
|
|
149
|
+
catch (error) {
|
|
150
|
+
if (!refreshStaleSession || !isStaleDeviceRefusal(error))
|
|
151
|
+
throw error;
|
|
152
|
+
const refreshed = await refreshStaleSession(envelope.targetUserId, envelope.targetDeviceId);
|
|
153
|
+
if (!refreshed)
|
|
154
|
+
throw error;
|
|
155
|
+
return post(envelope);
|
|
156
|
+
}
|
|
157
|
+
};
|
|
158
|
+
}
|
|
159
|
+
/**
|
|
160
|
+
* Tell whether a stored request attempt is answered and is the last
|
|
161
|
+
* attempt of its request. A sender answers at most
|
|
162
|
+
* `MAX_RETRY_RESPONSES_PER_MESSAGE` requests for one message, so when the
|
|
163
|
+
* resend that answered this attempt also fails, the request ends.
|
|
164
|
+
*/
|
|
165
|
+
export function answeredLastRetryAttempt(stored) {
|
|
166
|
+
return stored.answered && stored.attempt >= MAX_RETRY_RESPONSES_PER_MESSAGE;
|
|
167
|
+
}
|
|
68
168
|
/** The shortest wait before the next post of a stored attempt. */
|
|
69
169
|
const MIN_RETRY_REQUEST_BACKOFF_MS = 60_000;
|
|
70
170
|
/** The longest wait before the next post of a stored attempt. */
|
|
@@ -79,8 +179,15 @@ const MAX_RETRY_REQUEST_BACKOFF_MS = 60 * 60_000;
|
|
|
79
179
|
* record that ended posts nothing. At the deadline of the record, the
|
|
80
180
|
* request ends as `expired-content` and posts nothing. When a member
|
|
81
181
|
* failed and the stored attempt is answered, it creates the next attempt
|
|
82
|
-
* under the same retry ID, with the same deadline, and posts it.
|
|
83
|
-
*
|
|
182
|
+
* under the same retry ID, with the same deadline, and posts it. When that
|
|
183
|
+
* answered attempt is the last one, as `answeredLastRetryAttempt` tells,
|
|
184
|
+
* the request ends as `attempts-exhausted` and posts nothing. Otherwise it
|
|
185
|
+
* posts the stored attempt, as `postStoredRetryRequest` does.
|
|
186
|
+
*
|
|
187
|
+
* Each new attempt carries the failed client message ID, the content hint,
|
|
188
|
+
* the sender, the receive time and the delivery error state of the stored
|
|
189
|
+
* record. Attempt 1 takes them from `failed`, with the time of now as the
|
|
190
|
+
* receive time.
|
|
84
191
|
*
|
|
85
192
|
* @param store - The local store that keeps the request records.
|
|
86
193
|
* @param failed - The failed envelope and its stored request.
|
|
@@ -92,7 +199,8 @@ const MAX_RETRY_REQUEST_BACKOFF_MS = 60 * 60_000;
|
|
|
92
199
|
export async function postRetryRequest(store, failed, createRequest, sender, send) {
|
|
93
200
|
const failedEnvelopeId = failed.id;
|
|
94
201
|
if (failedEnvelopeId === undefined) {
|
|
95
|
-
|
|
202
|
+
const request = withFailedClientMessageId(await createRequest(), failed.clientMessageId);
|
|
203
|
+
await send(await retryRequestEnvelope(request, sender));
|
|
96
204
|
return 'posted';
|
|
97
205
|
}
|
|
98
206
|
const attempts = retryRequestAttempts(store, createRequest, sender, send);
|
|
@@ -103,13 +211,23 @@ export async function postRetryRequest(store, failed, createRequest, sender, sen
|
|
|
103
211
|
retryId: await generateUuidV4(),
|
|
104
212
|
attempt: 1,
|
|
105
213
|
...(failed.fingerprint !== undefined && { fingerprint: failed.fingerprint }),
|
|
214
|
+
...(failed.groupMessage && { groupMessage: true }),
|
|
215
|
+
...(failed.clientMessageId !== undefined && {
|
|
216
|
+
failedClientMessageId: failed.clientMessageId,
|
|
217
|
+
}),
|
|
218
|
+
...(failed.groupId !== undefined && { groupId: failed.groupId }),
|
|
219
|
+
receivedAt: Date.now(),
|
|
220
|
+
...(failed.contentHint !== undefined && { contentHint: failed.contentHint }),
|
|
221
|
+
...(failed.sender !== undefined && { failedSender: failed.sender }),
|
|
106
222
|
}));
|
|
107
223
|
}
|
|
108
224
|
if (stored.terminal !== undefined || stored.envelope === undefined)
|
|
109
225
|
return 'terminal';
|
|
110
226
|
if (Date.now() >= stored.deadlineAt)
|
|
111
|
-
return attempts.
|
|
227
|
+
return attempts.end(stored, 'expired-content');
|
|
112
228
|
if (failed.member !== undefined && stored.answered) {
|
|
229
|
+
if (answeredLastRetryAttempt(stored))
|
|
230
|
+
return attempts.end(stored, 'attempts-exhausted');
|
|
113
231
|
return attempts.postNew(await attempts.next(stored));
|
|
114
232
|
}
|
|
115
233
|
return attempts.postStored(stored);
|
|
@@ -140,12 +258,13 @@ export async function postStoredRetryRequest(store, stored, createRequest, sende
|
|
|
140
258
|
function retryRequestAttempts(store, createRequest, sender, send) {
|
|
141
259
|
const update = (record, changes) => updateRetryRequest(store, record.failedEnvelopeId, record.retryId, record.attempt, changes);
|
|
142
260
|
/**
|
|
143
|
-
* Create and store a new attempt. Attempt 1 sets the deadline
|
|
144
|
-
* attempt is due at its own time until
|
|
145
|
-
* scheduler posts it again when a stop or a
|
|
261
|
+
* Create and store a new attempt. Attempt 1 sets the deadline from its
|
|
262
|
+
* own time, the first failure. The attempt is due at its own time until
|
|
263
|
+
* its post settles, so the scheduler posts it again when a stop or a
|
|
264
|
+
* crash ends the post.
|
|
146
265
|
*/
|
|
147
266
|
const create = async (attempt) => {
|
|
148
|
-
const request = await createRequest();
|
|
267
|
+
const request = withFailedClientMessageId(await createRequest(), attempt.failedClientMessageId);
|
|
149
268
|
const envelope = await retryRequestEnvelope(request, sender, attempt);
|
|
150
269
|
const record = {
|
|
151
270
|
failedEnvelopeId: attempt.failedEnvelopeId,
|
|
@@ -153,9 +272,19 @@ function retryRequestAttempts(store, createRequest, sender, send) {
|
|
|
153
272
|
attempt: attempt.attempt,
|
|
154
273
|
requestedAt: envelope.timestamp,
|
|
155
274
|
...(attempt.fingerprint !== undefined && { fingerprint: attempt.fingerprint }),
|
|
275
|
+
...(attempt.groupId !== undefined && { groupId: attempt.groupId }),
|
|
156
276
|
answered: false,
|
|
157
|
-
|
|
158
|
-
|
|
277
|
+
...(attempt.groupMessage && { groupMessage: true }),
|
|
278
|
+
...(attempt.failedClientMessageId !== undefined && {
|
|
279
|
+
failedClientMessageId: attempt.failedClientMessageId,
|
|
280
|
+
}),
|
|
281
|
+
...(attempt.groupId !== undefined && { groupId: attempt.groupId }),
|
|
282
|
+
...(attempt.receivedAt !== undefined && { receivedAt: attempt.receivedAt }),
|
|
283
|
+
...(attempt.contentHint !== undefined && { contentHint: attempt.contentHint }),
|
|
284
|
+
...(attempt.failedSender !== undefined && { failedSender: attempt.failedSender }),
|
|
285
|
+
...(attempt.errorShown && { errorShown: true }),
|
|
286
|
+
...(attempt.recoveredEmitted && { recoveredEmitted: true }),
|
|
287
|
+
deadlineAt: attempt.deadlineAt ?? envelope.timestamp + RETRY_REQUEST_DEADLINE_MS,
|
|
159
288
|
nextAttemptAt: envelope.timestamp,
|
|
160
289
|
envelope,
|
|
161
290
|
};
|
|
@@ -168,11 +297,19 @@ function retryRequestAttempts(store, createRequest, sender, send) {
|
|
|
168
297
|
retryId: stored.retryId,
|
|
169
298
|
attempt: stored.attempt + 1,
|
|
170
299
|
fingerprint: stored.fingerprint,
|
|
300
|
+
groupMessage: stored.groupMessage,
|
|
301
|
+
failedClientMessageId: stored.failedClientMessageId,
|
|
302
|
+
groupId: stored.groupId,
|
|
303
|
+
receivedAt: stored.receivedAt,
|
|
304
|
+
contentHint: stored.contentHint,
|
|
305
|
+
failedSender: stored.failedSender,
|
|
306
|
+
errorShown: stored.errorShown,
|
|
307
|
+
recoveredEmitted: stored.recoveredEmitted,
|
|
171
308
|
deadlineAt: stored.deadlineAt,
|
|
172
309
|
});
|
|
173
|
-
const
|
|
310
|
+
const end = async (stored, terminal) => {
|
|
174
311
|
await update(stored, {
|
|
175
|
-
terminal: { class:
|
|
312
|
+
terminal: { class: terminal, at: Date.now(), emitted: false },
|
|
176
313
|
nextAttemptAt: undefined,
|
|
177
314
|
});
|
|
178
315
|
return 'terminal';
|
|
@@ -220,7 +357,7 @@ function retryRequestAttempts(store, createRequest, sender, send) {
|
|
|
220
357
|
return {
|
|
221
358
|
create,
|
|
222
359
|
next,
|
|
223
|
-
|
|
360
|
+
end,
|
|
224
361
|
postNew: (record) => post(record, true),
|
|
225
362
|
postStored: (stored) => post(stored, false),
|
|
226
363
|
};
|
|
@@ -265,7 +402,7 @@ export function readRetryRequestEnvelope(envelope, local) {
|
|
|
265
402
|
if (payload.v !== RETRY_REQUEST_PAYLOAD_VERSION) {
|
|
266
403
|
return { ok: false, cause: 'payload version is not supported' };
|
|
267
404
|
}
|
|
268
|
-
const { failedTimestamp, deviceId, reason, timestamp, ratchetKey, failedEnvelopeId, retryId } = payload;
|
|
405
|
+
const { failedTimestamp, deviceId, reason, timestamp, ratchetKey, failedEnvelopeId, retryId, failedClientMessageId, } = payload;
|
|
269
406
|
if (!Number.isSafeInteger(failedTimestamp) || failedTimestamp <= 0) {
|
|
270
407
|
return { ok: false, cause: 'failedTimestamp is not valid' };
|
|
271
408
|
}
|
|
@@ -289,12 +426,15 @@ export function readRetryRequestEnvelope(envelope, local) {
|
|
|
289
426
|
if (failedEnvelopeId !== undefined &&
|
|
290
427
|
(typeof failedEnvelopeId !== 'string' ||
|
|
291
428
|
failedEnvelopeId.length < 1 ||
|
|
292
|
-
failedEnvelopeId.length >
|
|
429
|
+
failedEnvelopeId.length > MAX_MESSAGE_ID_LENGTH)) {
|
|
293
430
|
return { ok: false, cause: 'failedEnvelopeId is not valid' };
|
|
294
431
|
}
|
|
295
432
|
if (retryId !== undefined && !isRetryId(retryId)) {
|
|
296
433
|
return { ok: false, cause: 'retryId is not valid' };
|
|
297
434
|
}
|
|
435
|
+
if (failedClientMessageId !== undefined && !isMessageId(failedClientMessageId)) {
|
|
436
|
+
return { ok: false, cause: 'failedClientMessageId is not valid' };
|
|
437
|
+
}
|
|
298
438
|
// The sender derives the resend IDs from the retry ID and keys its record by
|
|
299
439
|
// the failed envelope ID, so a payload carries both or neither.
|
|
300
440
|
if ((failedEnvelopeId === undefined) !== (retryId === undefined)) {
|
|
@@ -314,12 +454,21 @@ export function readRetryRequestEnvelope(envelope, local) {
|
|
|
314
454
|
timestamp: timestamp,
|
|
315
455
|
reason: reason,
|
|
316
456
|
...(ratchetKey === undefined ? {} : { ratchetKey: ratchetKey }),
|
|
457
|
+
...(failedClientMessageId === undefined ? {} : { failedClientMessageId }),
|
|
317
458
|
},
|
|
318
459
|
...(retryId === undefined
|
|
319
460
|
? {}
|
|
320
461
|
: { retry: { failedEnvelopeId: failedEnvelopeId, retryId: retryId } }),
|
|
321
462
|
};
|
|
322
463
|
}
|
|
464
|
+
/** The request with the failed client message ID, when there is one. */
|
|
465
|
+
function withFailedClientMessageId(request, failedClientMessageId) {
|
|
466
|
+
return failedClientMessageId === undefined ? request : { ...request, failedClientMessageId };
|
|
467
|
+
}
|
|
468
|
+
/** True for a string of 1 to `MAX_MESSAGE_ID_LENGTH` characters. */
|
|
469
|
+
function isMessageId(value) {
|
|
470
|
+
return typeof value === 'string' && value.length >= 1 && value.length <= MAX_MESSAGE_ID_LENGTH;
|
|
471
|
+
}
|
|
323
472
|
/** Decode canonical base64, or return undefined. */
|
|
324
473
|
function canonicalBase64Bytes(value) {
|
|
325
474
|
try {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"retry-request-envelope.js","sourceRoot":"","sources":["../../client/retry-request-envelope.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,EAAE,WAAW,EAAqB,MAAM,0BAA0B,CAAC;AAC1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,CAAC,KAAe,CAAC,CAAC;QAC7C,OAAO,aAAa,CAAC,KAAK,CAAC,KAAK,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,SAAS,CAAC;IAC5D,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,SAAS,CAAC;IACnB,CAAC;AACH,CAAC"}
|
|
@@ -6,16 +6,23 @@
|
|
|
6
6
|
* failed envelope posts nothing while the record exists. A post that fails
|
|
7
7
|
* with a retryable class is posted again by the scheduler at its next
|
|
8
8
|
* attempt time. A post that fails with a conclusive class, the deadline of
|
|
9
|
-
* the record,
|
|
10
|
-
*
|
|
9
|
+
* the record, a failed resend of the last answered attempt, and an
|
|
10
|
+
* exhausted abuse allowance end the request. Each end calls the
|
|
11
|
+
* `onRetryTerminal` hook at least once: the record is marked emitted only
|
|
12
|
+
* after the hook returns. Each request and each scheduler pass also checks
|
|
13
|
+
* the delivery error of the record, as `reportDeliveryError` tells. Each
|
|
14
|
+
* scheduler pass also runs a recovery that the hook did not mark, as
|
|
15
|
+
* `reportDeliveryRecovered` tells.
|
|
11
16
|
*/
|
|
12
17
|
import type { Logger } from '../logger.js';
|
|
13
18
|
import type { Envelope } from '../remote/relay/types.js';
|
|
14
19
|
import type { RetryRequest } from '../internal/sesame/types.js';
|
|
20
|
+
import type { ContentHint } from '../types/messages.js';
|
|
15
21
|
import { storeRetryRequest } from '../local/store/reliability.js';
|
|
16
|
-
import {
|
|
22
|
+
import type { SignalProtocolClientHooks } from './event-hooks.js';
|
|
17
23
|
import type { RetryFamilyReceive } from './retry-family.js';
|
|
18
24
|
import { type RetryPostOutcome, type RetryRequestDevice } from './retry-request-envelope.js';
|
|
25
|
+
import { type RetryTerminalResetContext, type RetryTerminalResetSteps } from './retry-terminal-recovery.js';
|
|
19
26
|
type RetryRequestStore = Parameters<typeof storeRetryRequest>[0];
|
|
20
27
|
/**
|
|
21
28
|
* What the retry request of one failed decrypt did.
|
|
@@ -43,27 +50,68 @@ export interface RetryRequestSource {
|
|
|
43
50
|
readonly hooks: SignalProtocolClientHooks | undefined;
|
|
44
51
|
/** The local identity, which sends the request envelope. */
|
|
45
52
|
readonly local: RetryRequestDevice;
|
|
46
|
-
/** The user ID of the failed sender
|
|
53
|
+
/** The user ID of the failed sender. A new record stores it. */
|
|
47
54
|
readonly senderUserId: string;
|
|
55
|
+
/** The device ID of the failed sender. A new record stores it. */
|
|
56
|
+
readonly senderDeviceId: number;
|
|
48
57
|
/** Spends one request of the rate limit of the sender. False when refused. */
|
|
49
58
|
allow(): boolean;
|
|
50
59
|
/** The rate limit window, for the log line and the cooldown of a member. */
|
|
51
60
|
readonly windowMs: number;
|
|
52
61
|
/** Posts one request envelope. Without it, nothing is posted. */
|
|
53
62
|
readonly send: ((envelope: Envelope) => Promise<unknown>) | undefined;
|
|
54
|
-
/**
|
|
55
|
-
|
|
63
|
+
/**
|
|
64
|
+
* What the failed envelope itself names. A member is a resend or a null
|
|
65
|
+
* message of a stored request, so the stored record names its failed
|
|
66
|
+
* envelope, and the request ignores these.
|
|
67
|
+
*/
|
|
68
|
+
readonly failedEnvelope?: {
|
|
69
|
+
/** The client message ID that the relay delivered with the envelope. */
|
|
70
|
+
readonly clientMessageId?: string;
|
|
71
|
+
/** True when the envelope is a sender-key message. */
|
|
72
|
+
readonly senderKey: boolean;
|
|
73
|
+
/** True when the request record stores the envelope as a group message. */
|
|
74
|
+
readonly groupMessage?: boolean;
|
|
75
|
+
/** The group of the envelope, when the local device knows it. */
|
|
76
|
+
readonly groupId?: string;
|
|
77
|
+
/** The content hint of the envelope, which sets the time of its delivery error. */
|
|
78
|
+
readonly contentHint?: ContentHint;
|
|
79
|
+
};
|
|
80
|
+
/**
|
|
81
|
+
* Creates the request of a new attempt. `senderKey` is true when the
|
|
82
|
+
* failed envelope is a sender-key message, so the request has no ratchet
|
|
83
|
+
* key.
|
|
84
|
+
*/
|
|
85
|
+
createRequest(senderKey: boolean): Promise<RetryRequest>;
|
|
56
86
|
/** Arms the scheduler for the next attempt time or the deadline of a record. */
|
|
57
87
|
readonly schedule: ((at: number) => void) | undefined;
|
|
88
|
+
/**
|
|
89
|
+
* The raw group ID of the failed envelope, when it is a group message
|
|
90
|
+
* whose group the receive resolved. A new record stores it, before the
|
|
91
|
+
* group of `failedEnvelope`.
|
|
92
|
+
*/
|
|
93
|
+
readonly groupId?: string;
|
|
94
|
+
/** The session reset of an `expired-content` end. Without it, nothing resets. */
|
|
95
|
+
readonly reset: RetryTerminalResetSteps | undefined;
|
|
58
96
|
}
|
|
59
97
|
/**
|
|
60
98
|
* Call the `onRetryTerminal` hook for the terminal state of a request
|
|
61
|
-
* record, once. It reads the record,
|
|
62
|
-
*
|
|
63
|
-
*
|
|
64
|
-
*
|
|
99
|
+
* record, once. It reads the record, and when the terminal state is not
|
|
100
|
+
* emitted, it first resets the session of an `expired-content` end with
|
|
101
|
+
* `resetRetryTerminalSession`. It then calls the hook and stores the state
|
|
102
|
+
* as emitted. The other classes reset nothing.
|
|
103
|
+
*
|
|
104
|
+
* The hook is called directly, not through `callHook`, so a hook that
|
|
105
|
+
* throws, and the RelayWorkStopped of a stop or of the reset, propagate and
|
|
106
|
+
* leave the state not emitted. The rule is: mark only after the hook
|
|
107
|
+
* returns, and keep the caller alive. The scheduler logs the error and goes
|
|
108
|
+
* on with the next record, and the receive path does not acknowledge the
|
|
109
|
+
* failed envelope. The next scheduler pass, at the next start or the next
|
|
110
|
+
* armed time, or the redelivery continues the reset from its stored steps
|
|
111
|
+
* and calls the hook again. The record holds no emit count, so a hook that
|
|
112
|
+
* keeps throwing runs once each pass until the record expires.
|
|
65
113
|
*/
|
|
66
|
-
export declare function emitRetryTerminal(
|
|
114
|
+
export declare function emitRetryTerminal(context: RetryTerminalResetContext, failedEnvelopeId: string): Promise<void>;
|
|
67
115
|
/**
|
|
68
116
|
* Ask for a resend after a failed decrypt, through the retry family of the
|
|
69
117
|
* envelope.
|
|
@@ -74,6 +122,10 @@ export declare function emitRetryTerminal(storage: RetryRequestStore, hooks: Sig
|
|
|
74
122
|
* - A failed envelope with no record spends one request of the rate limit.
|
|
75
123
|
* A refusal stores a record that ends as `abuse-allowance-exhausted`.
|
|
76
124
|
* - A member of a request that ended posts nothing and gives `terminal`.
|
|
125
|
+
* - A member whose stored attempt is answered and is the last attempt, as
|
|
126
|
+
* `answeredLastRetryAttempt` tells, ends the request as
|
|
127
|
+
* `attempts-exhausted` and gives `terminal`. The rate limit does not
|
|
128
|
+
* count it.
|
|
77
129
|
* - A member whose stored attempt is answered, or that has no record,
|
|
78
130
|
* spends one request of the rate limit, unless an earlier refusal set a
|
|
79
131
|
* next attempt time that has not come. A refusal sets that time to the
|
|
@@ -82,13 +134,15 @@ export declare function emitRetryTerminal(storage: RetryRequestStore, hooks: Sig
|
|
|
82
134
|
* rate limit.
|
|
83
135
|
*
|
|
84
136
|
* After a post, a terminal outcome calls the hook, and any other outcome
|
|
85
|
-
* arms the scheduler for the record.
|
|
137
|
+
* arms the scheduler for the record. Then, for each failed envelope with
|
|
138
|
+
* an ID, it runs `onDeliveryError` when the error of the record is due,
|
|
139
|
+
* and arms the scheduler for an error that is due later.
|
|
86
140
|
*/
|
|
87
141
|
export declare function requestRetryInFamily(family: RetryFamilyReceive, fingerprint: string | undefined, source: RetryRequestSource): Promise<RetryRequestOutcome>;
|
|
88
142
|
/**
|
|
89
143
|
* The context of one scheduler pass: the hooks run through the relay work
|
|
90
|
-
* of the pass. Without `send`, the pass only calls the
|
|
91
|
-
* states.
|
|
144
|
+
* of the pass. Without `send`, the pass only calls the hooks for terminal
|
|
145
|
+
* states and delivery errors.
|
|
92
146
|
*/
|
|
93
147
|
export interface RetryRequestPass {
|
|
94
148
|
readonly storage: RetryRequestStore;
|
|
@@ -96,6 +150,8 @@ export interface RetryRequestPass {
|
|
|
96
150
|
readonly hooks: SignalProtocolClientHooks | undefined;
|
|
97
151
|
readonly local: RetryRequestDevice;
|
|
98
152
|
readonly send: ((envelope: Envelope) => Promise<unknown>) | undefined;
|
|
153
|
+
/** The session reset of an `expired-content` end. Without it, nothing resets. */
|
|
154
|
+
readonly reset: RetryTerminalResetSteps | undefined;
|
|
99
155
|
}
|
|
100
156
|
export {};
|
|
101
157
|
//# sourceMappingURL=retry-request-lifecycle.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"retry-request-lifecycle.d.ts","sourceRoot":"","sources":["../../client/retry-request-lifecycle.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"retry-request-lifecycle.d.ts","sourceRoot":"","sources":["../../client/retry-request-lifecycle.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,WAAW,CAAC;AACxC,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AACtD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAC7D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AACrD,OAAO,EAKL,iBAAiB,EAIlB,MAAM,4BAA4B,CAAC;AAEpC,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,eAAe,CAAC;AAE/D,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,gBAAgB,CAAC;AACzD,OAAO,EAKL,KAAK,gBAAgB,EACrB,KAAK,kBAAkB,EAExB,MAAM,0BAA0B,CAAC;AAElC,OAAO,EAEL,KAAK,yBAAyB,EAC9B,KAAK,uBAAuB,EAC7B,MAAM,2BAA2B,CAAC;AAEnC,KAAK,iBAAiB,GAAG,UAAU,CAAC,OAAO,iBAAiB,CAAC,CAAC,CAAC,CAAC,CAAC;AAEjE;;;;;;;;;;GAUG;AACH,MAAM,MAAM,mBAAmB,GAAG,gBAAgB,GAAG,OAAO,GAAG,UAAU,GAAG,SAAS,CAAC;AAEtF;;;;;GAKG;AACH,wBAAgB,wBAAwB,CAAC,OAAO,EAAE,mBAAmB,EAAE,MAAM,EAAE,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