@open-e2ee/signal-protocol-sdk 0.1.0-alpha.4 → 0.1.0-alpha.5
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/CHANGELOG.md +54 -0
- package/README.md +4 -2
- package/dist/blocking/types.d.ts +1 -1
- package/dist/blocking/types.js +1 -1
- package/dist/client/client.d.ts +3 -3
- package/dist/client/client.js +4 -4
- package/dist/client/client.js.map +1 -1
- package/dist/client/compose.d.ts +1 -1
- package/dist/client/compose.d.ts.map +1 -1
- package/dist/client/config.d.ts +2 -2
- package/dist/client/event-hooks.d.ts +1 -1
- package/dist/client/headless.d.ts +2 -2
- package/dist/client/headless.js +2 -2
- package/dist/client/key-rotation-core.d.ts +4 -4
- package/dist/client/key-rotation-core.js +11 -11
- package/dist/client/key-rotation-core.js.map +1 -1
- package/dist/client/media.d.ts +2 -2
- package/dist/client/media.js +5 -5
- package/dist/client/media.js.map +1 -1
- package/dist/client/messages.js +2 -2
- package/dist/client/messages.js.map +1 -1
- package/dist/client/relay-subscription.js +17 -0
- package/dist/client/relay-subscription.js.map +1 -1
- package/dist/client/retry.js +1 -1
- package/dist/client/retry.js.map +1 -1
- package/dist/client/sealed-sender-ops.js +1 -1
- package/dist/client/sealed-sender-ops.js.map +1 -1
- package/dist/client/sessions.d.ts.map +1 -1
- package/dist/client/sessions.js +3 -0
- package/dist/client/sessions.js.map +1 -1
- package/dist/client/signal-service-cipher.d.ts +5 -1
- package/dist/client/signal-service-cipher.d.ts.map +1 -1
- package/dist/client/signal-service-cipher.js +19 -14
- package/dist/client/signal-service-cipher.js.map +1 -1
- package/dist/device/provisioning.d.ts +3 -3
- package/dist/device/provisioning.js +2 -2
- package/dist/device/provisioning.js.map +1 -1
- package/dist/hooks/use-connection-presence.d.ts +2 -2
- package/dist/hooks/use-connection-presence.d.ts.map +1 -1
- package/dist/hooks/use-connection-presence.js +1 -1
- package/dist/hooks/use-group-membership.d.ts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +3 -3
- package/dist/index.js.map +1 -1
- package/dist/internal/crypto/index.js +1 -1
- package/dist/internal/crypto/index.js.map +1 -1
- package/dist/internal/crypto/kdf/hkdf.d.ts +1 -1
- package/dist/internal/crypto/kdf/hkdf.d.ts.map +1 -1
- package/dist/internal/crypto/kdf/hkdf.js +2 -2
- package/dist/internal/crypto/kdf/hkdf.js.map +1 -1
- package/dist/internal/crypto/key-prefix.d.ts +1 -1
- package/dist/internal/crypto/key-prefix.js +1 -1
- package/dist/internal/crypto/pq/kyber.d.ts +1 -1
- package/dist/internal/crypto/pq/kyber.js +1 -1
- package/dist/internal/crypto/symmetric/aes-gcm-siv.d.ts +1 -1
- package/dist/internal/crypto/symmetric/aes-gcm-siv.js +1 -1
- package/dist/internal/crypto/utils.d.ts +2 -2
- package/dist/internal/crypto/utils.js +2 -2
- package/dist/internal/encoding/proto/index.js +1 -1
- package/dist/internal/encoding/proto/index.js.map +1 -1
- package/dist/internal/encoding/proto/pq-ratchet-serialize.d.ts +2 -2
- package/dist/internal/encoding/proto/pq-ratchet-serialize.d.ts.map +1 -1
- package/dist/internal/encoding/proto/pq-ratchet-serialize.js +2 -2
- package/dist/internal/encoding/proto/pq-ratchet-serialize.js.map +1 -1
- package/dist/internal/groups/group-id.d.ts +1 -1
- package/dist/internal/groups/group-id.js +1 -1
- package/dist/internal/groups/group-id.js.map +1 -1
- package/dist/internal/groups-v2/access-control.d.ts +8 -1
- package/dist/internal/groups-v2/access-control.d.ts.map +1 -1
- package/dist/internal/groups-v2/access-control.js +8 -1
- package/dist/internal/groups-v2/access-control.js.map +1 -1
- package/dist/internal/groups-v2/change-actions.d.ts +8 -3
- package/dist/internal/groups-v2/change-actions.d.ts.map +1 -1
- package/dist/internal/groups-v2/change-actions.js +8 -3
- package/dist/internal/groups-v2/change-actions.js.map +1 -1
- package/dist/internal/groups-v2/index.d.ts +7 -2
- package/dist/internal/groups-v2/index.d.ts.map +1 -1
- package/dist/internal/groups-v2/index.js.map +1 -1
- package/dist/internal/groups-v2/manager.d.ts +4 -2
- package/dist/internal/groups-v2/manager.d.ts.map +1 -1
- package/dist/internal/groups-v2/manager.js +5 -3
- package/dist/internal/groups-v2/manager.js.map +1 -1
- package/dist/internal/groups-v2/types.d.ts +10 -3
- package/dist/internal/groups-v2/types.d.ts.map +1 -1
- package/dist/internal/groups-v2/types.js.map +1 -1
- package/dist/internal/manager/manager.d.ts.map +1 -1
- package/dist/internal/manager/manager.js +25 -14
- package/dist/internal/manager/manager.js.map +1 -1
- package/dist/internal/protocol/double-ratchet/chains.d.ts +1 -1
- package/dist/internal/protocol/double-ratchet/chains.js +1 -1
- package/dist/internal/protocol/double-ratchet/ratchet.d.ts +1 -1
- package/dist/internal/protocol/double-ratchet/ratchet.js +1 -1
- package/dist/internal/protocol/sealed-sender/decryption.js +2 -2
- package/dist/internal/protocol/sealed-sender/decryption.js.map +1 -1
- package/dist/internal/protocol/sealed-sender/types.d.ts +1 -1
- package/dist/internal/protocol/sealed-sender/types.js +1 -1
- package/dist/internal/protocol/sender-keys/index.d.ts +1 -1
- package/dist/internal/protocol/sender-keys/manager.d.ts +2 -2
- package/dist/internal/protocol/sender-keys/manager.js +3 -3
- package/dist/internal/protocol/sender-keys/manager.js.map +1 -1
- package/dist/internal/protocol/spqr/index.d.ts +1 -1
- package/dist/internal/protocol/spqr/index.js +1 -1
- package/dist/internal/protocol/spqr/message.d.ts +1 -1
- package/dist/internal/protocol/spqr/message.js +1 -1
- package/dist/internal/protocol/spqr/ml-kem-braid/rs/codec.d.ts +3 -3
- package/dist/internal/protocol/spqr/ml-kem-braid/rs/codec.d.ts.map +1 -1
- package/dist/internal/protocol/spqr/ml-kem-braid/rs/index.js +2 -2
- package/dist/internal/protocol/spqr/ml-kem-braid/rs/index.js.map +1 -1
- package/dist/internal/protocol/spqr/ml-kem-braid/rs/lagrange.d.ts +1 -1
- package/dist/internal/protocol/spqr/ml-kem-braid/rs/lagrange.js +1 -1
- package/dist/internal/protocol/spqr/ml-kem-braid/rs/lagrange.js.map +1 -1
- package/dist/internal/protocol/spqr/ml-kem-braid/serialize.d.ts +1 -1
- package/dist/internal/protocol/spqr/ml-kem-braid/serialize.js +1 -1
- package/dist/internal/protocol/spqr/ml-kem-braid/state-machine.js +5 -5
- package/dist/internal/protocol/spqr/ml-kem-braid/state-machine.js.map +1 -1
- package/dist/internal/protocol/spqr/ml-kem-braid/types.d.ts +1 -1
- package/dist/internal/protocol/spqr/ml-kem-braid/types.d.ts.map +1 -1
- package/dist/internal/protocol/spqr/spqr.d.ts +9 -9
- package/dist/internal/protocol/spqr/spqr.d.ts.map +1 -1
- package/dist/internal/protocol/spqr/spqr.js +9 -9
- package/dist/internal/protocol/spqr/spqr.js.map +1 -1
- package/dist/internal/protocol/triple-ratchet/ratchet.d.ts +1 -1
- package/dist/internal/protocol/triple-ratchet/ratchet.js +1 -1
- package/dist/internal/protocol/username/generate.d.ts +1 -1
- package/dist/internal/protocol/username/generate.js +1 -1
- package/dist/internal/protocol/username/hash.d.ts +1 -1
- package/dist/internal/protocol/username/hash.js +1 -1
- package/dist/internal/protocol/username/link.d.ts +1 -1
- package/dist/internal/protocol/username/link.js +1 -1
- package/dist/internal/protocol/username/proof.d.ts +1 -1
- package/dist/internal/protocol/username/proof.js +1 -1
- package/dist/internal/protocol/x3dh/x3dh.js +3 -3
- package/dist/internal/protocol/x3dh/x3dh.js.map +1 -1
- package/dist/internal/protocol/zk/groups/client-zk-group-cipher.d.ts +2 -2
- package/dist/internal/protocol/zk/groups/client-zk-group-cipher.js +2 -2
- package/dist/internal/sesame/device-registry.d.ts +11 -6
- package/dist/internal/sesame/device-registry.d.ts.map +1 -1
- package/dist/internal/sesame/device-registry.js +11 -7
- package/dist/internal/sesame/device-registry.js.map +1 -1
- package/dist/internal/sesame/manager.js +1 -1
- package/dist/internal/sesame/manager.js.map +1 -1
- package/dist/internal/session/keys.d.ts +1 -1
- package/dist/keys/generation.d.ts +1 -1
- package/dist/keys/generation.js +1 -1
- package/dist/keys/types.d.ts +1 -1
- package/dist/keys/types.d.ts.map +1 -1
- package/dist/local/store/expo/adapter.d.ts +3 -3
- package/dist/local/store/expo/adapter.js +2 -2
- package/dist/local/store/expo/db.js +1 -1
- package/dist/local/store/expo/db.js.map +1 -1
- package/dist/local/store/expo/index.d.ts +1 -1
- package/dist/local/store/expo/models/local-identity.d.ts +1 -1
- package/dist/local/store/expo/models/local-identity.js +1 -1
- package/dist/local/store/expo/models/sender-key.d.ts +3 -3
- package/dist/local/store/expo/models/sender-key.d.ts.map +1 -1
- package/dist/local/store/expo/models/sender-key.js +3 -3
- package/dist/local/store/expo/models/sender-key.js.map +1 -1
- package/dist/local/store/expo/schema.d.ts +1 -1
- package/dist/local/store/expo/schema.js +1 -1
- package/dist/local/store/expo/secure-store-options.d.ts +1 -1
- package/dist/local/store/mock/adapter.d.ts +6 -0
- package/dist/local/store/mock/adapter.d.ts.map +1 -1
- package/dist/local/store/mock/adapter.js +117 -47
- package/dist/local/store/mock/adapter.js.map +1 -1
- package/dist/local/store/mock/failures.d.ts +34 -0
- package/dist/local/store/mock/failures.d.ts.map +1 -0
- package/dist/local/store/mock/failures.js +75 -0
- package/dist/local/store/mock/failures.js.map +1 -0
- package/dist/local/store/mock/index.d.ts +4 -3
- package/dist/local/store/mock/index.d.ts.map +1 -1
- package/dist/local/store/mock/index.js +3 -2
- package/dist/local/store/mock/index.js.map +1 -1
- package/dist/local/store/node/database-key.js +1 -1
- package/dist/local/store/react-native/adapter.js +2 -2
- package/dist/local/store/react-native/adapter.js.map +1 -1
- package/dist/local/store/react-native/storage.d.ts +1 -1
- package/dist/local/store/web/adapter.d.ts.map +1 -1
- package/dist/local/store/web/adapter.js +14 -2
- package/dist/local/store/web/adapter.js.map +1 -1
- package/dist/local/vault/index.d.ts +1 -1
- package/dist/logger.d.ts +1 -1
- package/dist/logger.js +1 -1
- package/dist/media/index.d.ts +2 -2
- package/dist/media/index.js +2 -2
- package/dist/profile/cipher.d.ts +1 -1
- package/dist/profile/cipher.js +1 -1
- package/dist/profile/contact-state.d.ts +1 -1
- package/dist/profile/contact-state.js +1 -1
- package/dist/profile/crypto.d.ts +1 -1
- package/dist/profile/crypto.js +1 -1
- package/dist/profile/profile-key.js +1 -1
- package/dist/profile/update-service.d.ts +2 -2
- package/dist/profile/update-service.d.ts.map +1 -1
- package/dist/remote/object-store/convex-r2/server.d.ts +1 -1
- package/dist/remote/relay/convex/index.d.ts +1 -1
- package/dist/remote/relay/convex/index.js +1 -1
- package/dist/remote/relay/convex/relay.d.ts +2 -2
- package/dist/remote/relay/convex/relay.js +2 -2
- package/dist/remote/relay/convex/types.d.ts +7 -7
- package/dist/remote/relay/convex/types.js +1 -1
- package/dist/remote/relay/mock/adapter.d.ts +13 -2
- package/dist/remote/relay/mock/adapter.d.ts.map +1 -1
- package/dist/remote/relay/mock/adapter.js +165 -51
- package/dist/remote/relay/mock/adapter.js.map +1 -1
- package/dist/remote/relay/mock/failures.d.ts +57 -0
- package/dist/remote/relay/mock/failures.d.ts.map +1 -0
- package/dist/remote/relay/mock/failures.js +118 -0
- package/dist/remote/relay/mock/failures.js.map +1 -0
- package/dist/remote/relay/mock/index.d.ts +4 -3
- package/dist/remote/relay/mock/index.d.ts.map +1 -1
- package/dist/remote/relay/mock/index.js +4 -3
- package/dist/remote/relay/mock/index.js.map +1 -1
- package/dist/remote/relay/types.d.ts +1 -1
- package/dist/remote/relay/types.js +1 -1
- package/dist/safety/protobuf.d.ts +1 -1
- package/dist/safety/protobuf.d.ts.map +1 -1
- package/dist/types/api.d.ts +6 -6
- package/dist/types/errors.d.ts +2 -2
- package/dist/types/errors.d.ts.map +1 -1
- package/dist/types/errors.js +2 -2
- package/dist/types/errors.js.map +1 -1
- package/dist/types/protocol-config.d.ts +3 -2
- package/dist/types/protocol-config.d.ts.map +1 -1
- package/dist/types/protocol-config.js.map +1 -1
- package/dist/types/protocol-constants.d.ts +1 -1
- package/dist/types/protocol-constants.js +1 -1
- package/dist/utils/binary-transfer.d.ts +1 -1
- package/dist/utils/errors.d.ts +2 -2
- package/dist/utils/errors.js +2 -2
- package/dist/utils/retry.d.ts +2 -1
- package/dist/utils/retry.d.ts.map +1 -1
- package/dist/utils/retry.js +3 -1
- package/dist/utils/retry.js.map +1 -1
- package/dist/zk/groups.d.ts +1 -1
- package/dist/zk/groups.js +1 -1
- package/docs/CLIENT_COMPOSITION.md +5 -3
- package/docs/DEVIATIONS.md +63 -62
- package/docs/GETTING_STARTED.md +10 -6
- package/docs/PACKAGE_SURFACE.md +2 -2
- package/docs/PROTOCOL_POLICY.md +2 -2
- package/docs/RECIPES.md +4 -0
- package/docs/api/classes/SignalProtocolClient.md +4 -4
- package/docs/api/functions/createDefaultSignalLogger.md +2 -2
- package/docs/api/functions/resolveSignalLogger.md +2 -2
- package/docs/api/interfaces/BlockedRecipientEntry.md +1 -1
- package/docs/api/interfaces/ILogger.md +1 -1
- package/docs/api/interfaces/ISignalLocalSecretVault.md +2 -2
- package/docs/api/interfaces/ISignalLocalStore.md +2 -2
- package/docs/api/interfaces/ISignalProtocolClient.md +2 -2
- package/docs/api/interfaces/MLKEMBraidAgentState.md +1 -1
- package/docs/api/interfaces/PreKeyMaintenanceStore.md +2 -1
- package/docs/api/interfaces/SealedSenderConfig.md +2 -2
- package/docs/api/interfaces/SignalProtocolClientCompositionOptions.md +2 -2
- package/docs/api/interfaces/SignalProtocolClientConfig.md +2 -2
- package/docs/api/interfaces/SignalProtocolClientHooks.md +1 -1
- package/docs/api/interfaces/SignalProtocolClientIdentityConfig.md +1 -1
- package/docs/api/interfaces/SignalProtocolClientMediaConfig.md +3 -3
- package/docs/api/interfaces/SignalProtocolConfig.md +1 -1
- package/docs/api/namespaces/encoding/functions/bytesToUrlSafeBase64.md +2 -2
- package/docs/api/namespaces/keys/functions/generateKemOneTimePreKeys.md +1 -1
- package/docs/api/namespaces/media/functions/prepareMediaAttachmentUpload.md +1 -1
- package/docs/api/namespaces/media/functions/resolveMediaAttachment.md +1 -1
- package/docs/api/namespaces/media/variables/downloadMediaAttachment.md +1 -1
- package/docs/api/type-aliases/GroupId.md +1 -1
- package/docs/api/variables/MAX_RECEIVER_CHAINS.md +1 -1
- package/docs/api/variables/ONE_TIME_PREKEY_BATCH_SIZE.md +1 -1
- package/docs/api/variables/defaultSignalLogger.md +2 -2
- package/local/store/mock/README.md +31 -0
- package/package.json +1 -1
- package/remote/relay/mock/README.md +37 -0
|
@@ -23,7 +23,7 @@ export declare const BraidPolicy: {
|
|
|
23
23
|
};
|
|
24
24
|
export type BraidPolicy = (typeof BraidPolicy)[keyof typeof BraidPolicy];
|
|
25
25
|
/**
|
|
26
|
-
* Public Signal
|
|
26
|
+
* Public Signal Protocol configuration.
|
|
27
27
|
*
|
|
28
28
|
* This keeps application code in product/security terms. Internal protocol
|
|
29
29
|
* strategy details such as X3DH fallback remain below the SignalProtocolClient seam.
|
|
@@ -233,7 +233,8 @@ export interface ReplacedOneTimePreKeyCullResult {
|
|
|
233
233
|
/**
|
|
234
234
|
* App-provided persistence helpers for prekey replacement bookkeeping.
|
|
235
235
|
*
|
|
236
|
-
* Signal owns rotation semantics; concrete storage adapters own
|
|
236
|
+
* The Signal Protocol SDK owns rotation semantics; concrete storage adapters own
|
|
237
|
+
* persistence.
|
|
237
238
|
*/
|
|
238
239
|
export interface PreKeyMaintenanceStore {
|
|
239
240
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"protocol-config.d.ts","sourceRoot":"","sources":["../../types/protocol-config.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAElD;;GAEG;AACH,eAAO,MAAM,iBAAiB;aAC5B,QAAQ,EAAE,UAAU;aACpB,UAAU,EAAE,YAAY;CAChB,CAAC;AAEX,MAAM,MAAM,iBAAiB,GAAG,CAAC,OAAO,iBAAiB,CAAC,CAAC,MAAM,OAAO,iBAAiB,CAAC,CAAC;AAE3F;;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AAM,EAAE,eAAe;QACxC,UAAU,EAAE,MAAM,EAAE,UAAU;QAC9B,qBAAqB,EAAE,MAAM,EAAE,qBAAqB;KACrD,CAAC;AACJ,CAAC;AAYD;;GAEG;AACH,MAAM,CAAC,MAAM,oBAAoB,GAAuB;IACtD,cAAc,EAAE,KAAK;IACrB,iBAAiB,EAAE,IAAI;CACxB,CAAC;AAEF;;GAEG;AACH,MAAM,UAAU,iBAAiB,CAAC,MAAmB;IACnD,OAAO;QACL,cAAc,EAAE,MAAM,EAAE,cAAc,IAAI,oBAAoB,CAAC,cAAc;QAC7E,iBAAiB,EAAE,MAAM,EAAE,iBAAiB,IAAI,oBAAoB,CAAC,iBAAiB;KACvF,CAAC;AACJ,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,eAAe,CAAC,MAA+B;IAC7D,OAAO,MAAM,EAAE,QAAQ,IAAI,OAAO,CAAC;AACrC,CAAC;AAYD;;GAEG;AACH,MAAM,UAAU,6BAA6B,CAAC,QAAiB;IAC7D,IAAI,QAAQ,EAAE,CAAC;QACb,OAAO,EAAE,KAAK,EAAE,QAAQ,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAC;IAC7C,CAAC;IACD,OAAO;QACL,KAAK,EAAE,kBAAkB;QACzB,IAAI,EAAE,iBAAiB;KACxB,CAAC;AACJ,CAAC"}
|
|
@@ -26,7 +26,7 @@ export declare const MAX_REGISTRATION_ID = 16380;
|
|
|
26
26
|
/**
|
|
27
27
|
* Batch size for one-time prekeys (both EC and KEM)
|
|
28
28
|
*
|
|
29
|
-
*
|
|
29
|
+
* The reference implementation uses 100 for both EC and KEM one-time prekeys to maintain
|
|
30
30
|
* protocol symmetry. This balances key availability with storage/upload costs.
|
|
31
31
|
*
|
|
32
32
|
* Per PQXDH specification, KEM one-time prekeys follow the same
|
|
@@ -31,7 +31,7 @@ export const MAX_REGISTRATION_ID = 16380;
|
|
|
31
31
|
/**
|
|
32
32
|
* Batch size for one-time prekeys (both EC and KEM)
|
|
33
33
|
*
|
|
34
|
-
*
|
|
34
|
+
* The reference implementation uses 100 for both EC and KEM one-time prekeys to maintain
|
|
35
35
|
* protocol symmetry. This balances key availability with storage/upload costs.
|
|
36
36
|
*
|
|
37
37
|
* Per PQXDH specification, KEM one-time prekeys follow the same
|
package/dist/utils/errors.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* SDK-local error helpers.
|
|
3
3
|
*
|
|
4
|
-
* The Signal package should not depend on app-owned error utilities.
|
|
4
|
+
* The Signal Protocol package should not depend on app-owned error utilities.
|
|
5
5
|
*/
|
|
6
6
|
export {};
|
|
7
7
|
export declare function getErrorMessage(error: unknown): string;
|
package/dist/utils/errors.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* SDK-local error helpers.
|
|
3
3
|
*
|
|
4
|
-
* The Signal package should not depend on app-owned error utilities.
|
|
4
|
+
* The Signal Protocol package should not depend on app-owned error utilities.
|
|
5
5
|
*/
|
|
6
6
|
export function getErrorMessage(error) {
|
|
7
7
|
if (error instanceof Error) {
|
package/dist/utils/retry.d.ts
CHANGED
|
@@ -4,7 +4,8 @@
|
|
|
4
4
|
* Provides retry logic with exponential backoff for transient failures.
|
|
5
5
|
* Distinguishes between retryable (network, timeout) and non-retryable (crypto) errors.
|
|
6
6
|
*
|
|
7
|
-
* This module is package-local on purpose. Signal must not
|
|
7
|
+
* This module is package-local on purpose. The Signal Protocol package must not
|
|
8
|
+
* depend on the app retry layer.
|
|
8
9
|
*/
|
|
9
10
|
/**
|
|
10
11
|
* Signal Protocol retry configuration
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"retry.d.ts","sourceRoot":"","sources":["../../utils/retry.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"retry.d.ts","sourceRoot":"","sources":["../../utils/retry.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAIH;;;;GAIG;AACH,OAAO,EAAE,CAAC;AACV,MAAM,WAAW,iBAAiB;IAChC,qFAAqF;IACrF,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,yDAAyD;IACzD,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,8DAA8D;IAC9D,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,8CAA8C;IAC9C,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,iCAAiC;IACjC,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAsED;;;;;;;;;;;GAWG;AACH,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,KAAK,GAAG,OAAO,CAyBtD;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAsB,SAAS,CAAC,CAAC,EAC/B,EAAE,EAAE,MAAM,OAAO,CAAC,CAAC,CAAC,EACpB,MAAM,GAAE,iBAAsB,GAC7B,OAAO,CAAC,CAAC,CAAC,CAoCZ"}
|
package/dist/utils/retry.js
CHANGED
|
@@ -4,7 +4,8 @@
|
|
|
4
4
|
* Provides retry logic with exponential backoff for transient failures.
|
|
5
5
|
* Distinguishes between retryable (network, timeout) and non-retryable (crypto) errors.
|
|
6
6
|
*
|
|
7
|
-
* This module is package-local on purpose. Signal must not
|
|
7
|
+
* This module is package-local on purpose. The Signal Protocol package must not
|
|
8
|
+
* depend on the app retry layer.
|
|
8
9
|
*/
|
|
9
10
|
import { EncryptionErrorCode } from '../types/index.js';
|
|
10
11
|
const SIGNAL_RETRY_CONFIG = {
|
|
@@ -23,6 +24,7 @@ const NON_RETRYABLE_ERROR_CODES = new Set([
|
|
|
23
24
|
EncryptionErrorCode.ENCRYPTION_FAILED,
|
|
24
25
|
EncryptionErrorCode.TOO_MANY_SKIPPED_MESSAGES,
|
|
25
26
|
EncryptionErrorCode.IDENTITY_KEY_CHANGED,
|
|
27
|
+
EncryptionErrorCode.KEY_STORAGE_ERROR,
|
|
26
28
|
]);
|
|
27
29
|
function sleep(ms) {
|
|
28
30
|
return new Promise((resolve) => setTimeout(resolve, ms));
|
package/dist/utils/retry.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"retry.js","sourceRoot":"","sources":["../../utils/retry.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"retry.js","sourceRoot":"","sources":["../../utils/retry.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AAqB/C,MAAM,mBAAmB,GAAG;IAC1B,UAAU,EAAE,CAAC;IACb,SAAS,EAAE,IAAI;IACf,QAAQ,EAAE,KAAK;IACf,iBAAiB,EAAE,CAAC;IACpB,YAAY,EAAE,IAAI;CACnB,CAAC;AAEF;;GAEG;AACH,MAAM,yBAAyB,GAAG,IAAI,GAAG,CAAC;IACxC,mBAAmB,CAAC,qBAAqB;IACzC,mBAAmB,CAAC,gBAAgB;IACpC,mBAAmB,CAAC,iBAAiB;IACrC,mBAAmB,CAAC,yBAAyB;IAC7C,mBAAmB,CAAC,oBAAoB;IACxC,mBAAmB,CAAC,iBAAiB;CACtC,CAAC,CAAC;AAEH,SAAS,KAAK,CAAC,EAAU;IACvB,OAAO,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,UAAU,CAAC,OAAO,EAAE,EAAE,CAAC,CAAC,CAAC;AAC3D,CAAC;AAED,SAAS,qBAAqB,CAC5B,OAAe,EACf,SAAiB,EACjB,QAAgB,EAChB,iBAAyB,EACzB,YAAqB;IAErB,IAAI,KAAK,GAAG,IAAI,CAAC,GAAG,CAAC,SAAS,GAAG,IAAI,CAAC,GAAG,CAAC,iBAAiB,EAAE,OAAO,CAAC,EAAE,QAAQ,CAAC,CAAC;IACjF,IAAI,YAAY,EAAE,CAAC;QACjB,KAAK,IAAI,IAAI,CAAC,MAAM,EAAE,GAAG,KAAK,GAAG,IAAI,CAAC;IACxC,CAAC;IACD,OAAO,IAAI,CAA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CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,eAAe,GACnB,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,KAAK,CAAC,GAAG,aAAa,YAAY,MAAM,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC;YAC1F,SAAS,GAAG,eAAe,CAAC;YAE5B,IAAI,OAAO,KAAK,aAAa,GAAG,CAAC,IAAI,CAAC,gBAAgB,CAAC,eAAe,CAAC,EAAE,CAAC;gBACxE,MAAM;YACR,CAAC;YAED,MAAM,KAAK,GAAG,qBAAqB,CACjC,OAAO,EACP,SAAS,EACT,QAAQ,EACR,mBAAmB,CAAC,iBAAiB,EACrC,YAAY,CACb,CAAC;YACF,MAAM,KAAK,CAAC,KAAK,CAAC,CAAC;QACrB,CAAC;IACH,CAAC;IAED,MAAM,SAAS,IAAI,IAAI,KAAK,CAAC,GAAG,aAAa,gCAAgC,CAAC,CAAC;AACjF,CAAC"}
|
package/dist/zk/groups.d.ts
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Public zkgroup API.
|
|
3
3
|
*
|
|
4
4
|
* Server-side wrappers and advanced app integrations should use this module
|
|
5
|
-
* rather than importing Signal
|
|
5
|
+
* rather than importing Signal Protocol internals directly.
|
|
6
6
|
*/
|
|
7
7
|
export {};
|
|
8
8
|
export * from '../internal/protocol/zk/groups/index.js';
|
package/dist/zk/groups.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Public zkgroup API.
|
|
3
3
|
*
|
|
4
4
|
* Server-side wrappers and advanced app integrations should use this module
|
|
5
|
-
* rather than importing Signal
|
|
5
|
+
* rather than importing Signal Protocol internals directly.
|
|
6
6
|
*/
|
|
7
7
|
export * from '../internal/protocol/zk/groups/index.js';
|
|
8
8
|
export { uuidToBytes, serviceIdBinary, uidStructFromServiceId, SERVICE_ID_ACI, SERVICE_ID_PNI, } from '../internal/protocol/zk/groups/uid-struct.js';
|
|
@@ -75,7 +75,9 @@ subscription startup.
|
|
|
75
75
|
|
|
76
76
|
## Local Client
|
|
77
77
|
|
|
78
|
+
<!-- mock-snippet:run client-composition-local-client -->
|
|
78
79
|
```ts
|
|
80
|
+
// Real protocol and cryptography; simulated in-memory infrastructure.
|
|
79
81
|
import { createSignalProtocolClient } from "@open-e2ee/signal-protocol-sdk";
|
|
80
82
|
import { mockStore } from "@open-e2ee/signal-protocol-sdk/local/store/mock";
|
|
81
83
|
|
|
@@ -136,9 +138,9 @@ const signal = await createSignalProtocolClient({
|
|
|
136
138
|
}),
|
|
137
139
|
},
|
|
138
140
|
media: {
|
|
139
|
-
// The existing Signal storage adapter persists queue metadata.
|
|
140
|
-
// callbacks keep app-owned files, plaintext cache, and UI state
|
|
141
|
-
// protocol package.
|
|
141
|
+
// The existing Signal Protocol storage adapter persists queue metadata.
|
|
142
|
+
// These callbacks keep app-owned files, plaintext cache, and UI state
|
|
143
|
+
// outside the protocol package.
|
|
142
144
|
loadLocalAttachment: async ({ localMediaId }) =>
|
|
143
145
|
appDraftMedia.readBytes(localMediaId),
|
|
144
146
|
saveUploadedAttachment: async ({ localMediaId, attachment }) =>
|
package/docs/DEVIATIONS.md
CHANGED
|
@@ -9,24 +9,24 @@
|
|
|
9
9
|
This SDK implements the same cryptographic core as the published Signal Protocol
|
|
10
10
|
specifications — X3DH/PQXDH key agreement, the Double Ratchet, the ML-KEM Braid
|
|
11
11
|
post-quantum ratchet, Sesame multi-device session management, sealed sender, and
|
|
12
|
-
Signal's zero-knowledge group credential system. In many places it is faithful
|
|
12
|
+
the Signal Protocol's zero-knowledge group credential system. In many places it is faithful
|
|
13
13
|
down to the byte: the same KDF labels, the same chain-key constants, the same
|
|
14
14
|
protobuf field numbers, the same iteration counts.
|
|
15
15
|
|
|
16
16
|
It is **not wire-compatible with Signal Messenger or with `libsignal`**, and it
|
|
17
17
|
is not intended to be. Messages produced by this SDK cannot be decrypted by a
|
|
18
|
-
Signal client, identities cannot be exchanged, safety numbers computed here
|
|
19
|
-
cannot be compared against safety numbers shown in Signal, and sessions cannot be
|
|
18
|
+
Signal Messenger client, identities cannot be exchanged, safety numbers computed here
|
|
19
|
+
cannot be compared against safety numbers shown in Signal Messenger, and sessions cannot be
|
|
20
20
|
migrated in either direction. This is a distinct wire profile —
|
|
21
|
-
`IndependentProfileV1` — that shares Signal's cryptographic design and
|
|
21
|
+
`IndependentProfileV1` — that shares the Signal Protocol's cryptographic design and
|
|
22
22
|
deliberately does not share its encoding.
|
|
23
23
|
|
|
24
24
|
That distinction matters in a specific way. Reading "implements X3DH and the
|
|
25
25
|
Double Ratchet" reasonably leads someone to expect interoperability. There is
|
|
26
|
-
none. Reading "
|
|
27
|
-
expect that a user could verify a contact by comparing a number
|
|
28
|
-
against the same contact's number in Signal. They
|
|
29
|
-
computed over different inputs and will never match.
|
|
26
|
+
none. Reading "safety numbers compatible with Signal Messenger" would reasonably
|
|
27
|
+
lead someone to expect that a user could verify a contact by comparing a number
|
|
28
|
+
shown in this SDK against the same contact's number in Signal Messenger. They
|
|
29
|
+
cannot; the numbers are computed over different inputs and will never match.
|
|
30
30
|
|
|
31
31
|
This document is the complete, honest account of where and why the profile
|
|
32
32
|
differs. Each entry names the implementing file, the specification section or
|
|
@@ -39,8 +39,8 @@ Deviations fall into three kinds:
|
|
|
39
39
|
- **Deviation** — does something different from the specification or from
|
|
40
40
|
`libsignal`, deliberately.
|
|
41
41
|
- **Extension** — adds a mechanism the specification does not describe.
|
|
42
|
-
- **Independent design** — shares a name and a goal with a Signal system, but is
|
|
43
|
-
the SDK's own construction rather than a port of
|
|
42
|
+
- **Independent design** — shares a name and a goal with a Signal Protocol system, but is
|
|
43
|
+
the SDK's own construction rather than a port of the corresponding `libsignal` system.
|
|
44
44
|
|
|
45
45
|
A fourth label, **faithful**, appears in the table where an area follows the
|
|
46
46
|
specification closely enough that its presence in this document is only to
|
|
@@ -58,23 +58,23 @@ model and what is out of scope.
|
|
|
58
58
|
| Area | Specification followed | Deviation or extension | Why | Consequence |
|
|
59
59
|
|---|---|---|---|---|
|
|
60
60
|
| **Identity keys** | X3DH §2.2; `libsignal` `identity_key.rs` | **Deviation.** A 67-byte composite of separate X25519 and Ed25519 keys replaces the single 33-byte Curve25519 identity key | Avoids XEdDSA, a non-standard signature scheme with no vetted JavaScript implementation; standard Ed25519 is independently verifiable | Two keys to store and rotate; larger identity; **no wire compatibility for any identity-bearing material** |
|
|
61
|
-
| **Prekey signatures** | X3DH §2.2, §4.5 | **Deviation.** RFC 8032 Ed25519 over a domain-separated context binding the identity commitment, algorithm tag, and key ID — not XEdDSA over the bare key | Defeats cross-algorithm and cross-key-ID substitution that a bare-key signature does not cover | Strictly stronger binding; signatures are unverifiable by Signal clients and vice versa |
|
|
62
|
-
| **Safety numbers** | `libsignal` `fingerprint.rs` | **Deviation.** Iteration and digit encoding are byte-identical, but the input is a composite-identity commitment under an SDK domain string, the QR version is `3`, and the two halves are ordered by user ID rather than by digit string | Follows from the composite identity; a single-key fingerprint cannot authenticate both components | **Safety numbers are not comparable to Signal's.** The ordering rule also differs from `libsignal` even on the single-key path |
|
|
61
|
+
| **Prekey signatures** | X3DH §2.2, §4.5 | **Deviation.** RFC 8032 Ed25519 over a domain-separated context binding the identity commitment, algorithm tag, and key ID — not XEdDSA over the bare key | Defeats cross-algorithm and cross-key-ID substitution that a bare-key signature does not cover | Strictly stronger binding; signatures are unverifiable by Signal Messenger clients and vice versa |
|
|
62
|
+
| **Safety numbers** | `libsignal` `fingerprint.rs` | **Deviation.** Iteration and digit encoding are byte-identical, but the input is a composite-identity commitment under an SDK domain string, the QR version is `3`, and the two halves are ordered by user ID rather than by digit string | Follows from the composite identity; a single-key fingerprint cannot authenticate both components | **Safety numbers are not comparable to Signal Messenger's.** The ordering rule also differs from `libsignal` even on the single-key path |
|
|
63
63
|
| **X3DH / PQXDH** | X3DH rev. 1; PQXDH rev. 3 | **Faithful** on DH order, the `0xFF`×32 prefix, zero-salt HKDF, and KEM-secret position. **Deviation:** ML-KEM-1024 (FIPS 203) runs under an info string naming `CRYSTALS-KYBER-1024` | Standardized ML-KEM preferred over round-3 Kyber; the label was inherited from `libsignal` and not updated | Identical label with a different KEM means the same transcript derives a **different** shared secret, with no domain separation signalling it. Violates PQXDH §2.2 |
|
|
64
64
|
| **Associated data** | X3DH §3.3 | **Deviation.** `AD` is a domain-separated HMAC input over SHA-256 commitments to both composite identities, not `IK_A ‖ IK_B` | Binds the Ed25519 component, which a raw-key `AD` would leave uncovered | Stronger binding; wire-incompatible |
|
|
65
|
-
| **Double Ratchet** | Double Ratchet rev. 4 | **Faithful** on `WhisperRatchet`, `WhisperMessageKeys`, the `0x01`/`0x02` seeds, the 80-byte split, AES-256-CBC, the `0x44` version byte, and 8-byte MAC truncation | — | The ratchet core
|
|
66
|
-
| **Message wire format** | `libsignal` `wire.proto` | **Faithful** field numbers 1–8. **Extension:** fields at 100+ carry identity type and ML-KEM one-time prekey material. **Deviation:** address binding uses variable-length UTF-8 user IDs and 4-byte device IDs instead of 17-byte ServiceIds and 1-byte device IDs | The SDK binds application-defined identifiers, not Signal ACIs | Wire-incompatible; a Signal client would silently ignore the added fields |
|
|
65
|
+
| **Double Ratchet** | Double Ratchet rev. 4 | **Faithful** on `WhisperRatchet`, `WhisperMessageKeys`, the `0x01`/`0x02` seeds, the 80-byte split, AES-256-CBC, the `0x44` version byte, and 8-byte MAC truncation | — | The ratchet core follows the Double Ratchet specification |
|
|
66
|
+
| **Message wire format** | `libsignal` `wire.proto` | **Faithful** field numbers 1–8. **Extension:** fields at 100+ carry identity type and ML-KEM one-time prekey material. **Deviation:** address binding uses variable-length UTF-8 user IDs and 4-byte device IDs instead of 17-byte ServiceIds and 1-byte device IDs | The SDK binds application-defined identifiers, not Signal Messenger ACIs | Wire-incompatible; a Signal Messenger client would silently ignore the added fields |
|
|
67
67
|
| **Skipped keys and archiving** | Double Ratchet §2.6; `libsignal` `consts.rs` | **Deviation.** The 2000-key cap is global rather than per-chain, eviction is by wall-clock timestamp, and skipped keys expire after 7 days. Session records serialize as JSON, not protobuf | Simpler storage accounting and bounded growth | **Legitimate messages can become undecryptable** where `libsignal` would still decrypt them: a 5× smaller effective cap, cross-chain eviction, and a hard 7-day limit for offline recipients |
|
|
68
|
-
| **Padding** | — | **Extension.** ISO 7816-4 bit padding to 160-byte buckets inside the library | Length hiding by default rather than left to the application | `libsignal` does not pad at this layer; Signal's apps do. PKCS#7 then adds a block, so ciphertext lands 16 bytes past each boundary |
|
|
69
|
-
| **SPQR / ML-KEM Braid** | ML-KEM Braid rev. 1 | **Deviation.** Same protocol, same KDF labels, same Reed–Solomon parameters, byte-identical message framing — except `hek = SHA3-256(ek_seed ‖ ek_vector)`, the operand order the specification states, which is the reverse of
|
|
70
|
-
| **Triple Ratchet** | `libsignal` `triple_ratchet.rs` | **Faithful.** The PQ secret enters as the HKDF salt at message-key expansion, same label, same order | — | The braiding construction
|
|
68
|
+
| **Padding** | — | **Extension.** ISO 7816-4 bit padding to 160-byte buckets inside the library | Length hiding by default rather than left to the application | `libsignal` does not pad at this layer; Signal Messenger's apps do. PKCS#7 then adds a block, so ciphertext lands 16 bytes past each boundary |
|
|
69
|
+
| **SPQR / ML-KEM Braid** | ML-KEM Braid rev. 1 | **Deviation.** Same protocol, same KDF labels, same Reed–Solomon parameters, byte-identical message framing — except `hek = SHA3-256(ek_seed ‖ ek_vector)`, the operand order the specification states, which is the reverse of `libsignal`'s implementation | The normative text was followed over the executable reference | Wire-visible. Headers, ciphertexts, and shared secrets diverge; a braid session cannot complete a single epoch against `libsignal`'s implementation. Also means the KEM is not FIPS 203 in braid mode |
|
|
70
|
+
| **Triple Ratchet** | `libsignal` `triple_ratchet.rs` | **Faithful.** The PQ secret enters as the HKDF salt at message-key expansion, same label, same order | — | The braiding construction follows the ML-KEM Braid specification |
|
|
71
71
|
| **Sesame** | Sesame rev. 2 | **Deviation** on session expiry (§4.2 applies only to unacknowledged sessions) and on deleted devices (hard-removed rather than marked stale). **Extensions:** QR provisioning, device transfer, encrypted device names, identity-change gating, a 5-device cap | Product requirements the specification does not address | Hard deletion **drops the MAXLATENCY window, so in-flight messages from a just-removed device become permanently undecryptable**. Device transfer clones ratchet state, which weakens the forward-secrecy bound |
|
|
72
72
|
| **Sealed sender v1** | `libsignal` `sealed_sender.rs` | **Deviation.** Correct labels, cipher, and MAC length, but the 96-byte HKDF output is split `(cipher, mac, chain)` where `libsignal` splits `(chain, cipher, mac)`; keys in the salt omit the `0x05` type byte; the inner envelope is a hand-rolled varint format rather than the `UnidentifiedSenderMessage.Message` protobuf | The slice order and the missing prefix are unintentional; the envelope is a deliberate simplification | Self-consistent and secure, but every v1 key sits in a different slot than `libsignal`'s. The envelope also drops the message-type field |
|
|
73
|
-
| **Sealed sender v2** | `libsignal` `sealed_sender.rs` | **Faithful** on all four labels, the KEM, AES-256-GCM-SIV, the multi-recipient binary format, and the `0x3FFF` registration-ID mask | — | The v2 construction
|
|
74
|
-
| **Delivery token** | `libsignal` `profile_key.rs` | **Faithful.** `deriveAccessKey`
|
|
73
|
+
| **Sealed sender v2** | `libsignal` `sealed_sender.rs` | **Faithful** on all four labels, the KEM, AES-256-GCM-SIV, the multi-recipient binary format, and the `0x3FFF` registration-ID mask | — | The v2 construction follows `libsignal` |
|
|
74
|
+
| **Delivery token** | `libsignal` `profile_key.rs` | **Faithful.** `deriveAccessKey` follows `libsignal`'s `ProfileKey::derive_access_key`, and reproduces `libsignal`'s published known-answer values | — | Not an SDK invention, despite what the module name suggests |
|
|
75
75
|
| **Sender keys** | `libsignal` `sender_keys.rs` | **Deviation.** Protobuf field numbers and `0x33` framing match, and the `0x01`/`0x02` seeds match, but message-key derivation **omits HKDF-Extract**, signatures are Ed25519 not XEdDSA, and `distributionUuid` carries a UTF-8 string rather than 16 UUID bytes | The Ed25519 choice follows the identity profile; the missing Extract appears unintentional | Group message keys differ from `libsignal`'s for the same chain key. Confirmed numerically, not merely by inspection |
|
|
76
|
-
| **Groups v2** | Signal Private Group System | **Independent design.** Real zkgroup primitives underneath, but the client is the state authority: it re-encrypts and uploads whole group state, and server signatures are not verified | Ships a working group system without a validating server | The relay **cannot validate group changes**, so it cannot enforce roles or membership. This is a materially weaker trust model than Signal
|
|
77
|
-
| **zkgroup / zkcredential** | `libsignal` `zkgroup`, `zkcredential`, `poksho` | **Faithful** port of the Ristretto255 KVAC and Sigma-protocol system, verified against `libsignal`'s known-answer vectors. **Deviation:** server parameter derivation uses SDK-specific labels | Server keys are the SDK's own trust root, not Signal's | The zero-knowledge properties are real. Credentials are not interchangeable with Signal's |
|
|
76
|
+
| **Groups v2** | Signal Private Group System | **Independent design.** Real zkgroup primitives underneath, but the client is the state authority: it re-encrypts and uploads whole group state, and server signatures are not verified | Ships a working group system without a validating server | The relay **cannot validate group changes**, so it cannot enforce roles or membership. This is a materially weaker trust model than the Signal Private Group System, where the server validates every change against zero-knowledge presentations |
|
|
77
|
+
| **zkgroup / zkcredential** | `libsignal` `zkgroup`, `zkcredential`, `poksho` | **Faithful** port of the Ristretto255 KVAC and Sigma-protocol system, verified against `libsignal`'s known-answer vectors. **Deviation:** server parameter derivation uses SDK-specific labels | Server keys are the SDK's own trust root, not Signal Messenger's | The zero-knowledge properties are real. Credentials are not interchangeable with Signal Messenger's |
|
|
78
78
|
| **Registration IDs** | `libsignal` `sealed_sender.rs` | **Faithful** as of 0.1.0-alpha.4. Generated in `[1, 16383]`, strictly inside the 14 bits the wire format reserves | — | Through alpha.3 the range ran to 16384, which masked to `0` on the wire in multi-recipient sealed sender for roughly 1 install in 16,384 |
|
|
79
79
|
|
|
80
80
|
---
|
|
@@ -157,7 +157,7 @@ or which identity it belongs to. Binding all three defeats cross-algorithm
|
|
|
157
157
|
substitution (presenting an X25519 signature as an ML-KEM one) and cross-key-ID
|
|
158
158
|
substitution. This is strictly stronger than the specification requires.
|
|
159
159
|
|
|
160
|
-
**Cost.** Wire incompatibility, and a signature format that no Signal
|
|
160
|
+
**Cost.** Wire incompatibility, and a signature format that no Signal Messenger
|
|
161
161
|
implementation can verify.
|
|
162
162
|
|
|
163
163
|
The same Ed25519-instead-of-XEdDSA choice applies to sealed sender certificates
|
|
@@ -169,10 +169,10 @@ this codebase. Where the frozen upstream specification snapshots mention them,
|
|
|
169
169
|
that is upstream text; the SDK's own documentation consistently states that
|
|
170
170
|
ordinary Ed25519 is used instead.
|
|
171
171
|
|
|
172
|
-
### 1.3 Safety numbers are not comparable to Signal's
|
|
172
|
+
### 1.3 Safety numbers are not comparable to Signal Messenger's
|
|
173
173
|
|
|
174
174
|
State this without hedging: **a safety number produced by this SDK will never
|
|
175
|
-
match the safety number Signal shows for the same two users.** A user cannot
|
|
175
|
+
match the safety number Signal Messenger shows for the same two users.** A user cannot
|
|
176
176
|
verify a contact by reading a number out of one application and comparing it
|
|
177
177
|
against the other.
|
|
178
178
|
|
|
@@ -193,7 +193,7 @@ SDK's low-level single-key path, which is otherwise byte-identical to
|
|
|
193
193
|
`libsignal`. The SDK orders by user identifier — `localId.localeCompare(remoteId)`
|
|
194
194
|
(`safety/core.ts:177`) — where `libsignal` orders by the encoded digit strings
|
|
195
195
|
themselves ([`fingerprint.rs:32-40`][fp]). Both rules are symmetric, so the two
|
|
196
|
-
parties always agree with each other; they simply do not agree with Signal, and
|
|
196
|
+
parties always agree with each other; they simply do not agree with Signal Messenger, and
|
|
197
197
|
roughly half the time the halves come out in the opposite order. `localeCompare`
|
|
198
198
|
is additionally locale-sensitive, so two devices with different default locales
|
|
199
199
|
can in principle disagree with each other on the ordering of the same pair of
|
|
@@ -209,7 +209,7 @@ cross-verification swap and constant-time comparison match as well.
|
|
|
209
209
|
The QR format version is the SDK's own: `3` for the composite path
|
|
210
210
|
(`safety/core.ts:46`), where `libsignal` knows only versions 1 and 2 and returns
|
|
211
211
|
`VersionMismatch` for anything else. Using a distinct version in the same
|
|
212
|
-
protobuf namespace is the correct fail-closed choice — a Signal client rejects
|
|
212
|
+
protobuf namespace is the correct fail-closed choice — a Signal Messenger client rejects
|
|
213
213
|
the code rather than misreading it.
|
|
214
214
|
|
|
215
215
|
The SDK also offers an emoji fingerprint (`safety/core.ts:308-392`) and
|
|
@@ -223,7 +223,7 @@ number and should not be presented to users as an equal-strength alternative.
|
|
|
223
223
|
Registration IDs are generated in the closed range `[1, 16383]`
|
|
224
224
|
(`keys/generation.ts:43-46`). The wire format reserves exactly 14 bits, and
|
|
225
225
|
`libsignal` rejects any ID where `id & 0x3FFF != id`
|
|
226
|
-
([`sealed_sender.rs:1508-1515`][ss]);
|
|
226
|
+
([`sealed_sender.rs:1508-1515`][ss]); `libsignal`'s own helper generates `[1, 16380]`.
|
|
227
227
|
|
|
228
228
|
Through 0.1.0-alpha.3 the range was `[1, 16384]`, an off-by-one: 16384 is
|
|
229
229
|
`0x4000` and does not fit in 14 bits, and the SDK's multi-recipient sealed sender
|
|
@@ -309,8 +309,8 @@ Ed25519 signing component unbound — the component that authenticates every pre
|
|
|
309
309
|
the peer will ever publish. Hashing the commitment covers both.
|
|
310
310
|
|
|
311
311
|
**Cost.** This is the single largest wire deviation in the message path. The
|
|
312
|
-
truncation to 8 bytes matches
|
|
313
|
-
and domain-separated, but a Signal client and this SDK cannot exchange a single
|
|
312
|
+
truncation to 8 bytes matches `libsignal`'s convention, and the construction is sound
|
|
313
|
+
and domain-separated, but a Signal Messenger client and this SDK cannot exchange a single
|
|
314
314
|
message.
|
|
315
315
|
|
|
316
316
|
### 2.3 One-time prekey deletion is deferred
|
|
@@ -380,7 +380,7 @@ field 6.
|
|
|
380
380
|
have: `recipientIdentityType` on both message types, and `kemOneTimePreKeyId` /
|
|
381
381
|
`kemOneTimeCiphertext` on prekey messages
|
|
382
382
|
(`internal/encoding/proto/signal-message.ts:80`, `:226-228`). High numbering
|
|
383
|
-
avoids collision with future upstream fields. A Signal client would parse the
|
|
383
|
+
avoids collision with future upstream fields. A Signal Messenger client would parse the
|
|
384
384
|
message and silently ignore them, losing the identity-type binding.
|
|
385
385
|
|
|
386
386
|
**Deviation.** `libsignal` binds addresses as a 17-byte fixed-width ServiceId plus
|
|
@@ -388,7 +388,7 @@ a 1-byte device ID ([`protocol.rs:246-260`][proto]). The SDK binds a
|
|
|
388
388
|
format-version byte, a varint-length-prefixed UTF-8 user ID, and a 4-byte
|
|
389
389
|
big-endian device ID (`internal/encoding/proto/signal-message.ts:84-92`). The
|
|
390
390
|
encoding is unambiguous, but it authenticates an application-defined identifier
|
|
391
|
-
rather than a Signal ACI or PNI — which is the correct thing for this SDK to bind
|
|
391
|
+
rather than a Signal Messenger ACI or PNI — which is the correct thing for this SDK to bind
|
|
392
392
|
and an incompatible thing to put on the wire.
|
|
393
393
|
|
|
394
394
|
The SDK is also stricter than `libsignal` on decode, requiring fields that
|
|
@@ -446,7 +446,7 @@ storage.
|
|
|
446
446
|
|
|
447
447
|
**Session records serialize as JSON, not protobuf** (`types/session.ts:1002-1028`).
|
|
448
448
|
This is acknowledged in the source as a simplicity and debuggability choice.
|
|
449
|
-
Consequences worth naming: stored sessions are not portable to or from any Signal
|
|
449
|
+
Consequences worth naming: stored sessions are not portable to or from any Signal Messenger
|
|
450
450
|
client, and key material sits in immutable JavaScript strings that cannot be
|
|
451
451
|
zeroed, where `libsignal`'s byte vectors can be.
|
|
452
452
|
|
|
@@ -458,7 +458,7 @@ padding — a `0x80` terminator followed by zeros
|
|
|
458
458
|
rejects malformed padding with a deliberately generic error to avoid a padding
|
|
459
459
|
oracle.
|
|
460
460
|
|
|
461
|
-
`libsignal` does not bucket-pad at this layer; in Signal, that lives in the client
|
|
461
|
+
`libsignal` does not bucket-pad at this layer; in Signal Messenger, that lives in the client
|
|
462
462
|
applications. Doing it in the library means length hiding is on by default rather
|
|
463
463
|
than a thing each integrator must remember.
|
|
464
464
|
|
|
@@ -472,7 +472,7 @@ past each boundary rather than on it.
|
|
|
472
472
|
|
|
473
473
|
## 4. SPQR and the ML-KEM Braid
|
|
474
474
|
|
|
475
|
-
This is the same protocol as
|
|
475
|
+
This is the same protocol as the SparsePostQuantumRatchet v1 protocol, implemented
|
|
476
476
|
independently and pinned against `SparsePostQuantumRatchet v1.5.1` (commit
|
|
477
477
|
`f2589fef`). The fidelity is high and specific:
|
|
478
478
|
|
|
@@ -483,10 +483,10 @@ independently and pinned against `SparsePostQuantumRatchet v1.5.1` (commit
|
|
|
483
483
|
(`internal/protocol/spqr/ml-kem-braid/kdf.ts:32-92`).
|
|
484
484
|
- **The Reed–Solomon erasure layer matches**: GF(2^16) with primitive polynomial
|
|
485
485
|
`0x1100b`, 32-byte chunks, 16 polynomials, degree bound 35. Reed–Solomon is
|
|
486
|
-
present in
|
|
486
|
+
present in `libsignal`; it is not an SDK addition.
|
|
487
487
|
- **The production wire framing is byte-compatible**:
|
|
488
488
|
`VERSION ‖ LEB128(epoch) ‖ LEB128(chain_index) ‖ MSG_TYPE ‖ [LEB128(chunk_index) ‖ CHUNK]`
|
|
489
|
-
(`internal/encoding/proto/pq-ratchet-serialize.ts`), matching
|
|
489
|
+
(`internal/encoding/proto/pq-ratchet-serialize.ts`), matching `libsignal`'s
|
|
490
490
|
`serialize.rs`, with the same message-type values and the same epoch offset.
|
|
491
491
|
- **ML-KEM-768 with the same incremental split** (32-byte seed, 1152-byte vector,
|
|
492
492
|
960/128-byte ciphertext parts).
|
|
@@ -500,18 +500,18 @@ One divergence breaks interoperability completely. The SDK computes
|
|
|
500
500
|
hek = SHA3-256(ek_seed || ek_vector)
|
|
501
501
|
```
|
|
502
502
|
|
|
503
|
-
|
|
503
|
+
`libsignal`, via libcrux, builds the encapsulation key as
|
|
504
504
|
`t̂ ‖ ρ` before hashing — the reverse order.
|
|
505
505
|
|
|
506
506
|
The SDK follows the **normative text of the published ML-KEM Braid
|
|
507
|
-
specification**, which states seed-first ordering.
|
|
507
|
+
specification**, which states seed-first ordering. `libsignal` follows FIPS 203,
|
|
508
508
|
which serializes vector-first. The specification and the reference implementation
|
|
509
509
|
disagree, and the SDK chose the specification.
|
|
510
510
|
|
|
511
511
|
The value feeds the Fujisaki–Okamoto transform, so the consequences cascade:
|
|
512
|
-
different header bytes, so
|
|
512
|
+
different header bytes, so `libsignal`'s header validation rejects the SDK's output;
|
|
513
513
|
different ciphertext; different shared secret; different epoch secret; different
|
|
514
|
-
authenticator ratchet. **A braid session between this SDK and Signal's
|
|
514
|
+
authenticator ratchet. **A braid session between this SDK and Signal Messenger's
|
|
515
515
|
implementation cannot complete a single epoch.**
|
|
516
516
|
|
|
517
517
|
Two further consequences a reader should not have to infer:
|
|
@@ -521,7 +521,7 @@ Two further consequences a reader should not have to infer:
|
|
|
521
521
|
is a permutation of the same material — but a FIPS conformance claim would not
|
|
522
522
|
hold for this path. Direct (non-braid) mode uses stock ML-KEM-768.
|
|
523
523
|
- The SDK resolves the same spec-versus-code conflict in the *opposite* direction
|
|
524
|
-
elsewhere: for `KDF_AUTH`, it follows
|
|
524
|
+
elsewhere: for `KDF_AUTH`, it follows the `libsignal` Rust reference rather than the
|
|
525
525
|
written specification. The two choices are individually defensible and
|
|
526
526
|
collectively inconsistent about which artifact is authoritative.
|
|
527
527
|
|
|
@@ -533,17 +533,17 @@ braid session persisted under the former ordering.
|
|
|
533
533
|
|
|
534
534
|
**Extension.** An opt-in direct mode (`protocol.braid: 'disabled'`) uses stock
|
|
535
535
|
ML-KEM-768 and adds wire message types `0x80`–`0x82`
|
|
536
|
-
(`internal/encoding/proto/pq-ratchet-serialize.ts:38-45`).
|
|
536
|
+
(`internal/encoding/proto/pq-ratchet-serialize.ts:38-45`). `libsignal`'s parser rejects
|
|
537
537
|
anything above `6`, so these are visible only within the SDK; they occupy a byte
|
|
538
|
-
range
|
|
538
|
+
range `libsignal` has not claimed. This mode has no Signal Protocol analogue.
|
|
539
539
|
|
|
540
540
|
**Independent design.** Persisted SPQR state uses a flat message with 20 fields
|
|
541
|
-
where
|
|
541
|
+
where `libsignal` uses an 11-variant `oneof` over nested structures. Serialized SPQR
|
|
542
542
|
state is not portable in either direction.
|
|
543
543
|
|
|
544
544
|
**Deviation.** Skipped-key eviction in the SPQR chain triggers at the cap and
|
|
545
|
-
evicts by wall-clock timestamp, where
|
|
546
|
-
evicts by message index.
|
|
545
|
+
evicts by wall-clock timestamp, where `libsignal` triggers at `max_ooo × 11/10 + 1` and
|
|
546
|
+
evicts by message index. `libsignal`'s rule is deterministic and index-anchored; the
|
|
547
547
|
SDK's introduces a clock dependency into ratchet state.
|
|
548
548
|
|
|
549
549
|
### 4.3 The Triple Ratchet is faithful
|
|
@@ -564,7 +564,7 @@ wire. It is documented in the PR that accompanied this file as cleanup work.
|
|
|
564
564
|
## 5. Sesame
|
|
565
565
|
|
|
566
566
|
Sesame has no reference implementation to compare against — `libsignal` does not
|
|
567
|
-
implement it; device and session management lives in the Signal service and its
|
|
567
|
+
implement it; device and session management lives in the Signal Messenger service and its
|
|
568
568
|
clients. Everything below is measured against the pinned specification text
|
|
569
569
|
(revision 2) alone.
|
|
570
570
|
|
|
@@ -689,13 +689,14 @@ internally inconsistent about this.
|
|
|
689
689
|
([`sealed_sender.rs:2055-2075`][ss]); the unseal path reconstructs the envelope
|
|
690
690
|
with a fixed type instead.
|
|
691
691
|
|
|
692
|
-
### 6.3 The delivery token
|
|
692
|
+
### 6.3 The delivery token follows `libsignal`, not an SDK invention
|
|
693
693
|
|
|
694
694
|
Despite the module name, `deriveAccessKey`
|
|
695
695
|
(`internal/protocol/sealed-sender/delivery-token.ts:52-91`) is `libsignal`'s
|
|
696
696
|
`ProfileKey::derive_access_key` — AES-256-GCM over 16 zero bytes with a zero
|
|
697
|
-
nonce, truncated to 16 bytes — and it reproduces `libsignal`
|
|
698
|
-
|
|
697
|
+
nonce, truncated to 16 bytes — and it reproduces the values `libsignal`
|
|
698
|
+
publishes for that derivation. It is a 16-byte value derived from the
|
|
699
|
+
recipient's profile key
|
|
699
700
|
that proves to the relay that the sender knows that profile key, gating anonymous
|
|
700
701
|
delivery to contacts. It never enters the sealed-sender wire format; it is
|
|
701
702
|
presented out of band.
|
|
@@ -705,7 +706,7 @@ construction that no code implements. That description is wrong and is corrected
|
|
|
705
706
|
in the PR accompanying this file.
|
|
706
707
|
|
|
707
708
|
Certificate signatures use Ed25519 rather than XEdDSA, per §1.2, so SDK
|
|
708
|
-
certificates cannot validate against a Signal trust root or vice versa. The
|
|
709
|
+
certificates cannot validate against a Signal Messenger trust root or vice versa. The
|
|
709
710
|
revocation list is empty where `libsignal` revokes one key ID, which is
|
|
710
711
|
appropriate for a different trust root but worth noting.
|
|
711
712
|
|
|
@@ -760,11 +761,11 @@ is incorrect. Flagged for correction.
|
|
|
760
761
|
### 7.3 Groups v2 is an independent design
|
|
761
762
|
|
|
762
763
|
The zero-knowledge primitives underneath are real and faithful (§7.4). The group
|
|
763
|
-
system built on them is not Signal
|
|
764
|
+
system built on them is not the Signal Private Group System.
|
|
764
765
|
|
|
765
|
-
What is faithful: role and access-control enum values match
|
|
766
|
+
What is faithful: role and access-control enum values match `libsignal`'s exactly,
|
|
766
767
|
group ID derivation from the master key is correct, the `__signal_group__v2__!`
|
|
767
|
-
identifier encoding
|
|
768
|
+
identifier encoding follows `libsignal`, authentication genuinely uses zkgroup
|
|
768
769
|
credentials, and member identifiers and profile keys are encrypted with real
|
|
769
770
|
`UidCiphertext` and `ProfileKeyCiphertext`.
|
|
770
771
|
|
|
@@ -772,7 +773,7 @@ What differs, and it is structural:
|
|
|
772
773
|
|
|
773
774
|
**The client is the state authority.** The SDK's client applies a change,
|
|
774
775
|
re-encrypts the entire group state, and uploads it
|
|
775
|
-
(`internal/groups-v2/manager.ts:1176-1193`). Signal's client submits only a set of
|
|
776
|
+
(`internal/groups-v2/manager.ts:1176-1193`). Signal Messenger's client submits only a set of
|
|
776
777
|
change actions, each carrying zero-knowledge presentations, and the **server**
|
|
777
778
|
validates every action and signs the result.
|
|
778
779
|
|
|
@@ -783,21 +784,21 @@ no zero-knowledge presentations for it to check. Any authenticated member can
|
|
|
783
784
|
rewrite roles, membership, and the ban list. Server signatures are returned but
|
|
784
785
|
never verified on receipt.
|
|
785
786
|
|
|
786
|
-
This is a materially weaker trust model than Signal
|
|
787
|
+
This is a materially weaker trust model than the Signal Private Group System, and
|
|
787
788
|
anyone deploying group messaging on this SDK needs to know it: group membership
|
|
788
789
|
and roles are enforced by cooperating clients, not by the server, and not
|
|
789
790
|
cryptographically against a malicious member. It is a reasonable position for an
|
|
790
791
|
SDK that ships without a validating server component, and it is not what a reader
|
|
791
|
-
of Signal
|
|
792
|
+
of the Signal Private Group System documentation would assume.
|
|
792
793
|
|
|
793
794
|
**Serialization is JSON**, not protobuf, both for group state
|
|
794
795
|
(`internal/groups-v2/manager.ts:1229-1236`) and for the blob payloads inside the
|
|
795
796
|
AES-256-GCM-SIV envelope (`internal/groups-v2/encrypted-state.ts:70-81`). Every
|
|
796
|
-
encrypted group title and description is undecryptable by Signal even with the
|
|
797
|
+
encrypted group title and description is undecryptable by Signal Messenger even with the
|
|
797
798
|
correct master key.
|
|
798
799
|
|
|
799
800
|
**Invite links** use `https://join.open-e2ee.dev/#` with a 49-byte raw payload
|
|
800
|
-
(`internal/groups-v2/invite-link.ts:36`, `:78-85`), where
|
|
801
|
+
(`internal/groups-v2/invite-link.ts:36`, `:78-85`), where `libsignal` uses
|
|
801
802
|
`https://signal.group/#` with a protobuf. This is labelled accurately in source as
|
|
802
803
|
the package's own format.
|
|
803
804
|
|
|
@@ -820,7 +821,7 @@ One deviation: server secret parameters are derived under four SDK-specific labe
|
|
|
820
821
|
rather than `libsignal`'s single seeded derivation
|
|
821
822
|
(`internal/protocol/zk/groups/server-params.ts:43-54`). The same randomness
|
|
822
823
|
therefore yields different server keys, and credentials are not interchangeable
|
|
823
|
-
with Signal's. That follows from the SDK being its own trust root.
|
|
824
|
+
with Signal Messenger's. That follows from the SDK being its own trust root.
|
|
824
825
|
|
|
825
826
|
Credential serialization is also ad hoc and carries no version byte, where
|
|
826
827
|
`libsignal` uses a leading version byte. That is a forward-compatibility gap
|
|
@@ -851,9 +852,9 @@ within this review.
|
|
|
851
852
|
are correct and unit tests exist, but the outputs were not diffed against
|
|
852
853
|
`libsignal`'s. A subtle error here would silently corrupt every `UidStruct`.
|
|
853
854
|
- **SPQR state-machine transition equivalence.** State names, message types, and
|
|
854
|
-
chunk counts match
|
|
855
|
+
chunk counts match `libsignal`'s; the eleven-state transition table was not diffed
|
|
855
856
|
transition by transition.
|
|
856
|
-
- **Whether the SPQR decoder enforces a bound on stored points.**
|
|
857
|
+
- **Whether the SPQR decoder enforces a bound on stored points.** `libsignal` caps
|
|
857
858
|
stored points per polynomial; no equivalent bound was located in the SDK's
|
|
858
859
|
decoder.
|
|
859
860
|
- **Whether SPQR state mutations are rolled back when message authentication
|