@signalapp/libsignal-client 0.73.1 → 0.73.3

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/Native.d.ts CHANGED
@@ -609,6 +609,7 @@ export function TESTING_ChatResponseConvert(bodyPresent: boolean): ChatResponse;
609
609
  export function TESTING_ChatSendErrorConvert(errorDescription: string): void;
610
610
  export function TESTING_ConnectionManager_isUsingProxy(manager: Wrapper<ConnectionManager>): number;
611
611
  export function TESTING_ConnectionManager_newLocalOverride(userAgent: string, chatPort: number, cdsiPort: number, svr2Port: number, rootCertificateDer: Buffer): ConnectionManager;
612
+ export function TESTING_ConvertOptionalUuid(present: boolean): Uuid | null;
612
613
  export function TESTING_ErrorOnBorrowAsync(_input: null): Promise<void>;
613
614
  export function TESTING_ErrorOnBorrowIo(asyncRuntime: Wrapper<NonSuspendingBackgroundThreadRuntime>, _input: null): CancellablePromise<void>;
614
615
  export function TESTING_ErrorOnBorrowSync(_input: null): void;
@@ -639,6 +640,9 @@ export function TESTING_FutureProducesPointerType(asyncRuntime: Wrapper<NonSuspe
639
640
  export function TESTING_FutureSuccess(asyncRuntime: Wrapper<NonSuspendingBackgroundThreadRuntime>, input: number): CancellablePromise<number>;
640
641
  export function TESTING_InputStreamReadIntoZeroLengthSlice(capsAlphabetInput: InputStream): Promise<Buffer>;
641
642
  export function TESTING_JoinStringArray(array: string[], joinWith: string): string;
643
+ export function TESTING_KeyTransChatSendError(): void;
644
+ export function TESTING_KeyTransFatalVerificationFailure(): void;
645
+ export function TESTING_KeyTransNonFatalVerificationFailure(): void;
642
646
  export function TESTING_NonSuspendingBackgroundThreadRuntime_New(): NonSuspendingBackgroundThreadRuntime;
643
647
  export function TESTING_OtherTestingHandleType_getValue(handle: Wrapper<OtherTestingHandleType>): string;
644
648
  export function TESTING_PanicInBodyAsync(_input: null): Promise<void>;
package/dist/Errors.d.ts CHANGED
@@ -39,7 +39,9 @@ export declare enum ErrorCode {
39
39
  ConnectionInvalidated = 35,
40
40
  ConnectedElsewhere = 36,
41
41
  BackupValidation = 37,
42
- Cancelled = 38
42
+ Cancelled = 38,
43
+ KeyTransparencyError = 39,
44
+ KeyTransparencyVerificationFailed = 40
43
45
  }
44
46
  export declare class LibSignalErrorBase extends Error {
45
47
  readonly code: ErrorCode;
@@ -179,4 +181,10 @@ export type BackupValidationError = LibSignalErrorCommon & {
179
181
  export type CancellationError = LibSignalErrorCommon & {
180
182
  code: ErrorCode.Cancelled;
181
183
  };
182
- export type LibSignalError = GenericError | DuplicatedMessageError | SealedSenderSelfSendError | UntrustedIdentityError | InvalidRegistrationIdError | VerificationFailedError | InvalidSessionError | InvalidSenderKeySessionError | NicknameCannotBeEmptyError | CannotStartWithDigitError | MissingSeparatorError | BadNicknameCharacterError | NicknameTooShortError | NicknameTooLongError | DiscriminatorCannotBeEmptyError | DiscriminatorCannotBeZeroError | DiscriminatorCannotBeSingleDigitError | DiscriminatorCannotHaveLeadingZerosError | BadDiscriminatorCharacterError | DiscriminatorTooLargeError | InputDataTooLong | InvalidEntropyDataLength | InvalidUsernameLinkEncryptedData | IoError | CdsiInvalidTokenError | InvalidUriError | InvalidMediaInputError | SvrDataMissingError | SvrRestoreFailedError | SvrRequestFailedError | UnsupportedMediaInputError | ChatServiceInactive | AppExpiredError | DeviceDelinkedError | ConnectionInvalidatedError | ConnectedElsewhereError | RateLimitedError | BackupValidationError | CancellationError;
184
+ export type KeyTransparencyError = LibSignalErrorCommon & {
185
+ code: ErrorCode.KeyTransparencyError;
186
+ };
187
+ export type KeyTransparencyVerificationFailed = LibSignalErrorCommon & {
188
+ code: ErrorCode.KeyTransparencyVerificationFailed;
189
+ };
190
+ export type LibSignalError = GenericError | DuplicatedMessageError | SealedSenderSelfSendError | UntrustedIdentityError | InvalidRegistrationIdError | VerificationFailedError | InvalidSessionError | InvalidSenderKeySessionError | NicknameCannotBeEmptyError | CannotStartWithDigitError | MissingSeparatorError | BadNicknameCharacterError | NicknameTooShortError | NicknameTooLongError | DiscriminatorCannotBeEmptyError | DiscriminatorCannotBeZeroError | DiscriminatorCannotBeSingleDigitError | DiscriminatorCannotHaveLeadingZerosError | BadDiscriminatorCharacterError | DiscriminatorTooLargeError | InputDataTooLong | InvalidEntropyDataLength | InvalidUsernameLinkEncryptedData | IoError | CdsiInvalidTokenError | InvalidUriError | InvalidMediaInputError | SvrDataMissingError | SvrRestoreFailedError | SvrRequestFailedError | UnsupportedMediaInputError | ChatServiceInactive | AppExpiredError | DeviceDelinkedError | ConnectionInvalidatedError | ConnectedElsewhereError | RateLimitedError | BackupValidationError | CancellationError | KeyTransparencyError | KeyTransparencyVerificationFailed;
package/dist/Errors.js CHANGED
@@ -47,6 +47,8 @@ var ErrorCode;
47
47
  ErrorCode[ErrorCode["ConnectedElsewhere"] = 36] = "ConnectedElsewhere";
48
48
  ErrorCode[ErrorCode["BackupValidation"] = 37] = "BackupValidation";
49
49
  ErrorCode[ErrorCode["Cancelled"] = 38] = "Cancelled";
50
+ ErrorCode[ErrorCode["KeyTransparencyError"] = 39] = "KeyTransparencyError";
51
+ ErrorCode[ErrorCode["KeyTransparencyVerificationFailed"] = 40] = "KeyTransparencyVerificationFailed";
50
52
  })(ErrorCode || (exports.ErrorCode = ErrorCode = {}));
51
53
  class LibSignalErrorBase extends Error {
52
54
  constructor(message, name, operation, extraProps) {
@@ -669,7 +669,7 @@ For more information on this, and how to apply and follow the GNU AGPL, see
669
669
 
670
670
  ```
671
671
 
672
- ## libsignal-account-keys, attest, libsignal-ffi, libsignal-jni, libsignal-jni-impl, libsignal-jni-testing, libsignal-node, signal-neon-futures, signal-neon-futures-tests, libsignal-bridge, libsignal-bridge-macros, libsignal-bridge-testing, libsignal-bridge-types, libsignal-core, signal-crypto, device-transfer, libsignal-keytrans, signal-media, libsignal-message-backup, libsignal-message-backup-macros, libsignal-net, libsignal-net-infra, poksho, libsignal-protocol, usernames, zkcredential, zkgroup
672
+ ## libsignal-account-keys, attest, libsignal-ffi, libsignal-jni, libsignal-jni-impl, libsignal-jni-testing, libsignal-node, signal-neon-futures, signal-neon-futures-tests, libsignal-bridge, libsignal-bridge-macros, libsignal-bridge-testing, libsignal-bridge-types, libsignal-cli-utils, libsignal-core, signal-crypto, device-transfer, libsignal-keytrans, signal-media, libsignal-message-backup, libsignal-message-backup-macros, libsignal-net, libsignal-net-chat, libsignal-net-infra, poksho, libsignal-protocol, usernames, zkcredential, zkgroup
673
673
 
674
674
  ```
675
675
  GNU AFFERO GENERAL PUBLIC LICENSE
@@ -3541,7 +3541,7 @@ DEALINGS IN THE SOFTWARE.
3541
3541
 
3542
3542
  ```
3543
3543
 
3544
- ## neon-macros 1.0.0, neon 1.0.0
3544
+ ## neon-macros 1.1.1, neon 1.1.1
3545
3545
 
3546
3546
  ```
3547
3547
  Copyright (c) 2015 David Herman
@@ -7229,7 +7229,7 @@ SOFTWARE.
7229
7229
 
7230
7230
  ```
7231
7231
 
7232
- ## curve25519-dalek-derive 0.1.1, adler2 2.0.0, anyhow 1.0.97, async-trait 0.1.88, atomic-waker 1.1.2, auto_enums 0.8.7, derive_utils 0.15.0, displaydoc 0.2.5, dyn-clone 1.0.19, fastrand 2.3.0, home 0.5.9, itoa 1.0.15, linkme-impl 0.3.32, linkme 0.3.32, linux-raw-sys 0.4.15, linux-raw-sys 0.9.3, minimal-lexical 0.2.1, once_cell 1.21.3, paste 1.0.15, pin-project-internal 1.1.10, pin-project-lite 0.2.16, pin-project 1.1.10, prettyplease 0.2.32, proc-macro2 1.0.94, quote 1.0.40, rustc-hash 1.1.0, rustix 0.38.44, rustix 1.0.5, rustversion 1.0.20, semver 1.0.26, send_wrapper 0.6.0, serde 1.0.219, serde_derive 1.0.219, serde_json 1.0.140, syn-mid 0.6.0, syn 2.0.100, thiserror-impl 1.0.69, thiserror-impl 2.0.12, thiserror 1.0.69, thiserror 2.0.12, unicode-ident 1.0.18, utf-8 0.7.6
7232
+ ## curve25519-dalek-derive 0.1.1, adler2 2.0.0, anyhow 1.0.97, async-trait 0.1.88, atomic-waker 1.1.2, auto_enums 0.8.7, derive_utils 0.15.0, displaydoc 0.2.5, dyn-clone 1.0.19, fastrand 2.3.0, home 0.5.9, itoa 1.0.15, linkme-impl 0.3.33, linkme 0.3.33, linux-raw-sys 0.4.15, linux-raw-sys 0.9.3, minimal-lexical 0.2.1, once_cell 1.21.3, paste 1.0.15, pin-project-internal 1.1.10, pin-project-lite 0.2.16, pin-project 1.1.10, prettyplease 0.2.32, proc-macro2 1.0.94, quote 1.0.40, rustc-hash 1.1.0, rustix 0.38.44, rustix 1.0.5, rustversion 1.0.20, semver 1.0.26, send_wrapper 0.6.0, serde 1.0.219, serde_derive 1.0.219, serde_json 1.0.140, syn-mid 0.6.0, syn 2.0.100, thiserror-impl 1.0.69, thiserror-impl 2.0.12, thiserror 1.0.69, thiserror 2.0.12, unicode-ident 1.0.18, utf-8 0.7.6
7233
7233
 
7234
7234
  ```
7235
7235
  Permission is hereby granted, free of charge, to any
@@ -96,7 +96,18 @@ export interface Client {
96
96
  * @returns A promise that resolves if the search succeeds and the local state has been updated
97
97
  * to reflect the latest changes. If the promise is rejected, the UI should be updated to notify
98
98
  * the user of the failure.
99
- */
99
+ *
100
+ * @throws {KeyTransparencyError} for errors related to key transparency logic, which
101
+ * includes missing required fields in the serialized data. Retrying the search without
102
+ * changing any of the arguments (including the state of the store) is unlikely to yield a
103
+ * different result.
104
+ * @throws {KeyTransparencyVerificationFailed} when it fails to
105
+ * verify the data in key transparency server response, such as an incorrect proof or a
106
+ * wrong signature.
107
+ * @throws {ChatServiceInactive} if the chat connection has been closed.
108
+ * @throws {IoError} if an error occurred while commuicating with the
109
+ * server.
110
+ * */
100
111
  search(request: Request, store: Store, options?: Readonly<Options>): Promise<void>;
101
112
  /**
102
113
  * Perform a monitor operation for an account previously searched for.
@@ -114,6 +125,17 @@ export interface Client {
114
125
  * @returns A promise that resolves if the monitor succeeds and the local state has been updated
115
126
  * to reflect the latest changes. If the promise is rejected, the UI should be updated to notify
116
127
  * the user of the failure.
128
+ *
129
+ * @throws {KeyTransparencyError} for errors related to key transparency logic, which
130
+ * includes missing required fields in the serialized data. Retrying the search without
131
+ * changing any of the arguments (including the state of the store) is unlikely to yield a
132
+ * different result.
133
+ * @throws {KeyTransparencyVerificationFailed} when it fails to
134
+ * verify the data in key transparency server response, such as an incorrect proof or a
135
+ * wrong signature.
136
+ * @throws {ChatServiceInactive} if the chat connection has been closed.
137
+ * @throws {IoError} if an error occurred while commuicating with the
138
+ * server.
117
139
  */
118
140
  monitor(request: Request, store: Store, options?: Readonly<Options>): Promise<void>;
119
141
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@signalapp/libsignal-client",
3
- "version": "0.73.1",
3
+ "version": "0.73.3",
4
4
  "license": "AGPL-3.0-only",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",