@awangxcode/qiro-baileys 7.0.0-rc26.2 → 7.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/lib/Defaults/index.d.ts +1 -1
- package/lib/Defaults/index.js +3 -3
- package/lib/Extensions/advanced.d.ts +1 -1
- package/lib/Extensions/experimental.d.ts +1 -1
- package/lib/MessageBuilder/index.d.ts +5 -5
- package/lib/MessageBuilder/index.js +2 -2
- package/lib/Signal/Group/group-session-builder.d.ts +3 -3
- package/lib/Signal/Group/group-session-builder.js +4 -4
- package/lib/Signal/Group/group_cipher.d.ts +2 -2
- package/lib/Signal/Group/group_cipher.js +4 -4
- package/lib/Signal/Group/index.d.ts +11 -11
- package/lib/Signal/Group/index.js +11 -11
- package/lib/Signal/Group/sender-chain-key.d.ts +1 -1
- package/lib/Signal/Group/sender-chain-key.js +1 -1
- package/lib/Signal/Group/sender-key-distribution-message.d.ts +1 -1
- package/lib/Signal/Group/sender-key-distribution-message.js +1 -1
- package/lib/Signal/Group/sender-key-message.d.ts +1 -1
- package/lib/Signal/Group/sender-key-message.js +1 -1
- package/lib/Signal/Group/sender-key-record.d.ts +1 -1
- package/lib/Signal/Group/sender-key-record.js +2 -2
- package/lib/Signal/Group/sender-key-state.d.ts +2 -2
- package/lib/Signal/Group/sender-key-state.js +2 -2
- package/lib/Signal/libsignal.d.ts +3 -3
- package/lib/Signal/libsignal.js +6 -6
- package/lib/Signal/lid-mapping.d.ts +2 -2
- package/lib/Signal/lid-mapping.js +1 -1
- package/lib/Socket/Client/index.d.ts +2 -2
- package/lib/Socket/Client/index.js +2 -2
- package/lib/Socket/Client/types.d.ts +1 -1
- package/lib/Socket/Client/websocket.d.ts +1 -1
- package/lib/Socket/Client/websocket.js +2 -2
- package/lib/Socket/business.d.ts +77 -77
- package/lib/Socket/business.js +5 -5
- package/lib/Socket/chats.d.ts +16 -16
- package/lib/Socket/chats.js +9 -9
- package/lib/Socket/communities.d.ts +56 -56
- package/lib/Socket/communities.js +5 -5
- package/lib/Socket/groups.d.ts +28 -28
- package/lib/Socket/groups.js +4 -4
- package/lib/Socket/index.d.ts +97 -97
- package/lib/Socket/index.js +4 -4
- package/lib/Socket/messages-recv.d.ts +42 -42
- package/lib/Socket/messages-recv.js +10 -10
- package/lib/Socket/messages-send.d.ts +45 -45
- package/lib/Socket/messages-send.js +9 -9
- package/lib/Socket/mex.d.ts +1 -1
- package/lib/Socket/mex.js +1 -1
- package/lib/Socket/newsletter.d.ts +34 -34
- package/lib/Socket/newsletter.js +5 -5
- package/lib/Socket/socket.d.ts +11 -11
- package/lib/Socket/socket.js +7 -7
- package/lib/Types/Auth.d.ts +2 -2
- package/lib/Types/Chat.d.ts +6 -6
- package/lib/Types/Events.d.ts +9 -9
- package/lib/Types/GroupMetadata.d.ts +2 -2
- package/lib/Types/Message.d.ts +5 -5
- package/lib/Types/Product.d.ts +1 -1
- package/lib/Types/Signal.d.ts +1 -1
- package/lib/Types/Socket.d.ts +5 -5
- package/lib/Types/Socket.js +1 -1
- package/lib/Types/State.d.ts +1 -1
- package/lib/Types/USync.d.ts +2 -2
- package/lib/Types/USync.js +1 -1
- package/lib/Types/index.d.ts +14 -14
- package/lib/Types/index.js +12 -12
- package/lib/Utils/auth-utils.d.ts +2 -2
- package/lib/Utils/auth-utils.js +4 -4
- package/lib/Utils/browser-utils.d.ts +1 -1
- package/lib/Utils/business.d.ts +2 -2
- package/lib/Utils/business.js +3 -3
- package/lib/Utils/chat-utils.d.ts +3 -3
- package/lib/Utils/chat-utils.js +7 -7
- package/lib/Utils/companion-reg-client-utils.d.ts +3 -3
- package/lib/Utils/companion-reg-client-utils.js +1 -1
- package/lib/Utils/crypto.d.ts +1 -1
- package/lib/Utils/crypto.js +1 -1
- package/lib/Utils/decode-wa-message.d.ts +4 -4
- package/lib/Utils/decode-wa-message.js +2 -2
- package/lib/Utils/event-buffer.d.ts +2 -2
- package/lib/Utils/event-buffer.js +4 -4
- package/lib/Utils/generics.d.ts +2 -2
- package/lib/Utils/generics.js +3 -3
- package/lib/Utils/history.d.ts +1 -1
- package/lib/Utils/history.js +5 -5
- package/lib/Utils/identity-change-handler.d.ts +2 -2
- package/lib/Utils/identity-change-handler.js +2 -2
- package/lib/Utils/index.d.ts +21 -21
- package/lib/Utils/index.js +21 -21
- package/lib/Utils/link-preview.d.ts +2 -2
- package/lib/Utils/link-preview.js +2 -2
- package/lib/Utils/message-retry-manager.d.ts +1 -1
- package/lib/Utils/messages-media.d.ts +4 -4
- package/lib/Utils/messages-media.js +4 -4
- package/lib/Utils/messages.d.ts +4 -4
- package/lib/Utils/messages.js +7 -7
- package/lib/Utils/noise-handler.d.ts +3 -3
- package/lib/Utils/noise-handler.js +3 -3
- package/lib/Utils/offline-node-processor.d.ts +1 -1
- package/lib/Utils/pre-key-manager.d.ts +2 -2
- package/lib/Utils/process-message.d.ts +2 -2
- package/lib/Utils/process-message.js +7 -7
- package/lib/Utils/reporting-utils.d.ts +2 -2
- package/lib/Utils/reporting-utils.js +1 -1
- package/lib/Utils/signal.d.ts +4 -4
- package/lib/Utils/signal.js +4 -4
- package/lib/Utils/stanza-ack.d.ts +1 -1
- package/lib/Utils/sync-action-utils.d.ts +2 -2
- package/lib/Utils/sync-action-utils.js +1 -1
- package/lib/Utils/tc-token-utils.d.ts +2 -2
- package/lib/Utils/tc-token-utils.js +1 -1
- package/lib/Utils/use-multi-file-auth-state.d.ts +1 -1
- package/lib/Utils/use-multi-file-auth-state.js +2 -2
- package/lib/Utils/validate-connection.d.ts +2 -2
- package/lib/Utils/validate-connection.js +5 -5
- package/lib/WABinary/decode.d.ts +1 -1
- package/lib/WABinary/decode.js +2 -2
- package/lib/WABinary/encode.d.ts +1 -1
- package/lib/WABinary/encode.js +2 -2
- package/lib/WABinary/generic-utils.d.ts +1 -1
- package/lib/WABinary/generic-utils.js +1 -1
- package/lib/WABinary/index.d.ts +5 -5
- package/lib/WABinary/index.js +5 -5
- package/lib/WABinary/types.d.ts +1 -1
- package/lib/WABinary/types.js +1 -1
- package/lib/WAM/BinaryInfo.d.ts +1 -1
- package/lib/WAM/encode.d.ts +1 -1
- package/lib/WAM/encode.js +2 -2
- package/lib/WAM/index.d.ts +3 -3
- package/lib/WAM/index.js +3 -3
- package/lib/WAUSync/Protocols/USyncContactProtocol.d.ts +3 -3
- package/lib/WAUSync/Protocols/USyncContactProtocol.js +2 -2
- package/lib/WAUSync/Protocols/USyncDeviceProtocol.d.ts +2 -2
- package/lib/WAUSync/Protocols/USyncDeviceProtocol.js +1 -1
- package/lib/WAUSync/Protocols/USyncDisappearingModeProtocol.d.ts +2 -2
- package/lib/WAUSync/Protocols/USyncDisappearingModeProtocol.js +1 -1
- package/lib/WAUSync/Protocols/USyncStatusProtocol.d.ts +2 -2
- package/lib/WAUSync/Protocols/USyncStatusProtocol.js +1 -1
- package/lib/WAUSync/Protocols/USyncUsernameProtocol.d.ts +3 -3
- package/lib/WAUSync/Protocols/USyncUsernameProtocol.js +2 -2
- package/lib/WAUSync/Protocols/UsyncBotProfileProtocol.d.ts +3 -3
- package/lib/WAUSync/Protocols/UsyncBotProfileProtocol.js +2 -2
- package/lib/WAUSync/Protocols/UsyncLIDProtocol.d.ts +3 -3
- package/lib/WAUSync/Protocols/index.d.ts +5 -5
- package/lib/WAUSync/Protocols/index.js +5 -5
- package/lib/WAUSync/USyncQuery.d.ts +3 -3
- package/lib/WAUSync/USyncQuery.js +5 -5
- package/lib/WAUSync/index.d.ts +3 -3
- package/lib/WAUSync/index.js +3 -3
- package/lib/index.d.ts +10 -10
- package/lib/index.js +11 -11
- package/package.json +2 -2
package/lib/Defaults/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { proto } from '../../WAProto/index.js';
|
|
2
|
-
import type { SocketConfig } from '../Types';
|
|
2
|
+
import type { SocketConfig } from '../Types/index.js';
|
|
3
3
|
export declare const UNAUTHORIZED_CODES: number[];
|
|
4
4
|
export declare const LIBRARY_NAME = "QIRO Baileys";
|
|
5
5
|
export declare const DONATE_URL = "https://www.npmjs.com/package/@awangxcode/qiro-baileys";
|
package/lib/Defaults/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { proto } from '../../WAProto/index.js';
|
|
2
|
-
import { makeLibSignalRepository } from '../Signal/libsignal';
|
|
3
|
-
import { Browsers } from '../Utils/browser-utils';
|
|
4
|
-
import logger from '../Utils/logger';
|
|
2
|
+
import { makeLibSignalRepository } from '../Signal/libsignal.js';
|
|
3
|
+
import { Browsers } from '../Utils/browser-utils.js';
|
|
4
|
+
import logger from '../Utils/logger.js';
|
|
5
5
|
const version = [2, 3000, 1056359382];
|
|
6
6
|
export const UNAUTHORIZED_CODES = [401, 403, 419];
|
|
7
7
|
export const LIBRARY_NAME = 'QIRO Baileys';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { proto } from '../../WAProto/index.js';
|
|
2
|
-
import type { AnyMessageContent, AuthenticationState, MiscMessageGenerationOptions, WAMediaUpload, WAMessage, WAMessageContent } from '../Types';
|
|
2
|
+
import type { AnyMessageContent, AuthenticationState, MiscMessageGenerationOptions, WAMediaUpload, WAMessage, WAMessageContent } from '../Types/index.js';
|
|
3
3
|
/** A conservative media item accepted by the high-level album sender. */
|
|
4
4
|
export type AlbumMediaItem = ({
|
|
5
5
|
image: WAMediaUpload;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { MessageRelayOptions } from '../Types/Message';
|
|
1
|
+
import type { MessageRelayOptions } from '../Types/Message.js';
|
|
2
2
|
import { proto } from '../../WAProto/index.js';
|
|
3
3
|
type RelaySocket = {
|
|
4
4
|
relayMessage: (jid: string, message: proto.IMessage, options: MessageRelayOptions) => Promise<string>;
|
|
@@ -186,8 +186,8 @@ export declare const MessageBuilder: {
|
|
|
186
186
|
}>;
|
|
187
187
|
checkNativeFlowButtons: (buttons: NativeFlowButtonInput[], platform?: NativeFlowPlatform, options?: NativeFlowValidationOptions) => NativeFlowButtonValidation;
|
|
188
188
|
isWebSupportedNativeFlowButton: (name: string) => boolean;
|
|
189
|
-
readRichMessage: (input: unknown) => import("
|
|
190
|
-
readSocialPreview: (input: unknown) => import("
|
|
189
|
+
readRichMessage: (input: unknown) => import("../index.js").ReadRichMessageResult | null;
|
|
190
|
+
readSocialPreview: (input: unknown) => import("../index.js").SocialPreviewResult | null;
|
|
191
191
|
};
|
|
192
192
|
export declare const MB: {
|
|
193
193
|
Button: typeof Button;
|
|
@@ -203,8 +203,8 @@ export declare const MB: {
|
|
|
203
203
|
}>;
|
|
204
204
|
checkNativeFlowButtons: (buttons: NativeFlowButtonInput[], platform?: NativeFlowPlatform, options?: NativeFlowValidationOptions) => NativeFlowButtonValidation;
|
|
205
205
|
isWebSupportedNativeFlowButton: (name: string) => boolean;
|
|
206
|
-
readRichMessage: (input: unknown) => import("
|
|
207
|
-
readSocialPreview: (input: unknown) => import("
|
|
206
|
+
readRichMessage: (input: unknown) => import("../index.js").ReadRichMessageResult | null;
|
|
207
|
+
readSocialPreview: (input: unknown) => import("../index.js").SocialPreviewResult | null;
|
|
208
208
|
};
|
|
209
209
|
export {};
|
|
210
210
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { generateMessageID } from '../Utils/generics';
|
|
1
|
+
import { generateMessageID } from '../Utils/generics.js';
|
|
2
2
|
import { proto } from '../../WAProto/index.js';
|
|
3
|
-
import { readRichMessage, readSocialPreview } from '../Extensions/advanced';
|
|
3
|
+
import { readRichMessage, readSocialPreview } from '../Extensions/advanced.js';
|
|
4
4
|
const COMMON_NATIVE_FLOW_BUTTONS = new Set([
|
|
5
5
|
'quick_reply',
|
|
6
6
|
'cta_url',
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { SenderKeyDistributionMessage } from './sender-key-distribution-message';
|
|
2
|
-
import { SenderKeyName } from './sender-key-name';
|
|
3
|
-
import { SenderKeyRecord } from './sender-key-record';
|
|
1
|
+
import { SenderKeyDistributionMessage } from './sender-key-distribution-message.js';
|
|
2
|
+
import { SenderKeyName } from './sender-key-name.js';
|
|
3
|
+
import { SenderKeyRecord } from './sender-key-record.js';
|
|
4
4
|
interface SenderKeyStore {
|
|
5
5
|
loadSenderKey(senderKeyName: SenderKeyName): Promise<SenderKeyRecord>;
|
|
6
6
|
storeSenderKey(senderKeyName: SenderKeyName, record: SenderKeyRecord): Promise<void>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import * as keyhelper from './keyhelper';
|
|
2
|
-
import { SenderKeyDistributionMessage } from './sender-key-distribution-message';
|
|
3
|
-
import { SenderKeyName } from './sender-key-name';
|
|
4
|
-
import { SenderKeyRecord } from './sender-key-record';
|
|
1
|
+
import * as keyhelper from './keyhelper.js';
|
|
2
|
+
import { SenderKeyDistributionMessage } from './sender-key-distribution-message.js';
|
|
3
|
+
import { SenderKeyName } from './sender-key-name.js';
|
|
4
|
+
import { SenderKeyRecord } from './sender-key-record.js';
|
|
5
5
|
export class GroupSessionBuilder {
|
|
6
6
|
constructor(senderKeyStore) {
|
|
7
7
|
this.senderKeyStore = senderKeyStore;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { SenderKeyName } from './sender-key-name';
|
|
2
|
-
import { SenderKeyRecord } from './sender-key-record';
|
|
1
|
+
import { SenderKeyName } from './sender-key-name.js';
|
|
2
|
+
import { SenderKeyRecord } from './sender-key-record.js';
|
|
3
3
|
export interface SenderKeyStore {
|
|
4
4
|
loadSenderKey(senderKeyName: SenderKeyName): Promise<SenderKeyRecord>;
|
|
5
5
|
storeSenderKey(senderKeyName: SenderKeyName, record: SenderKeyRecord): Promise<void>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { decrypt, encrypt } from 'libsignal/src/crypto.js';
|
|
2
|
-
import { SenderKeyMessage } from './sender-key-message';
|
|
3
|
-
import { SenderKeyName } from './sender-key-name';
|
|
4
|
-
import { SenderKeyRecord } from './sender-key-record';
|
|
5
|
-
import { SenderKeyState } from './sender-key-state';
|
|
2
|
+
import { SenderKeyMessage } from './sender-key-message.js';
|
|
3
|
+
import { SenderKeyName } from './sender-key-name.js';
|
|
4
|
+
import { SenderKeyRecord } from './sender-key-record.js';
|
|
5
|
+
import { SenderKeyState } from './sender-key-state.js';
|
|
6
6
|
export class GroupCipher {
|
|
7
7
|
constructor(senderKeyStore, senderKeyName) {
|
|
8
8
|
this.senderKeyStore = senderKeyStore;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
export { GroupSessionBuilder } from './group-session-builder';
|
|
2
|
-
export { SenderKeyDistributionMessage } from './sender-key-distribution-message';
|
|
3
|
-
export { SenderKeyRecord } from './sender-key-record';
|
|
4
|
-
export { SenderKeyName } from './sender-key-name';
|
|
5
|
-
export { GroupCipher } from './group_cipher';
|
|
6
|
-
export { SenderKeyState } from './sender-key-state';
|
|
7
|
-
export { SenderKeyMessage } from './sender-key-message';
|
|
8
|
-
export { SenderMessageKey } from './sender-message-key';
|
|
9
|
-
export { SenderChainKey } from './sender-chain-key';
|
|
10
|
-
export { CiphertextMessage } from './ciphertext-message';
|
|
11
|
-
export * as keyhelper from './keyhelper';
|
|
1
|
+
export { GroupSessionBuilder } from './group-session-builder.js';
|
|
2
|
+
export { SenderKeyDistributionMessage } from './sender-key-distribution-message.js';
|
|
3
|
+
export { SenderKeyRecord } from './sender-key-record.js';
|
|
4
|
+
export { SenderKeyName } from './sender-key-name.js';
|
|
5
|
+
export { GroupCipher } from './group_cipher.js';
|
|
6
|
+
export { SenderKeyState } from './sender-key-state.js';
|
|
7
|
+
export { SenderKeyMessage } from './sender-key-message.js';
|
|
8
|
+
export { SenderMessageKey } from './sender-message-key.js';
|
|
9
|
+
export { SenderChainKey } from './sender-chain-key.js';
|
|
10
|
+
export { CiphertextMessage } from './ciphertext-message.js';
|
|
11
|
+
export * as keyhelper from './keyhelper.js';
|
|
12
12
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
export { GroupSessionBuilder } from './group-session-builder';
|
|
2
|
-
export { SenderKeyDistributionMessage } from './sender-key-distribution-message';
|
|
3
|
-
export { SenderKeyRecord } from './sender-key-record';
|
|
4
|
-
export { SenderKeyName } from './sender-key-name';
|
|
5
|
-
export { GroupCipher } from './group_cipher';
|
|
6
|
-
export { SenderKeyState } from './sender-key-state';
|
|
7
|
-
export { SenderKeyMessage } from './sender-key-message';
|
|
8
|
-
export { SenderMessageKey } from './sender-message-key';
|
|
9
|
-
export { SenderChainKey } from './sender-chain-key';
|
|
10
|
-
export { CiphertextMessage } from './ciphertext-message';
|
|
11
|
-
export * as keyhelper from './keyhelper';
|
|
1
|
+
export { GroupSessionBuilder } from './group-session-builder.js';
|
|
2
|
+
export { SenderKeyDistributionMessage } from './sender-key-distribution-message.js';
|
|
3
|
+
export { SenderKeyRecord } from './sender-key-record.js';
|
|
4
|
+
export { SenderKeyName } from './sender-key-name.js';
|
|
5
|
+
export { GroupCipher } from './group_cipher.js';
|
|
6
|
+
export { SenderKeyState } from './sender-key-state.js';
|
|
7
|
+
export { SenderKeyMessage } from './sender-key-message.js';
|
|
8
|
+
export { SenderMessageKey } from './sender-message-key.js';
|
|
9
|
+
export { SenderChainKey } from './sender-chain-key.js';
|
|
10
|
+
export { CiphertextMessage } from './ciphertext-message.js';
|
|
11
|
+
export * as keyhelper from './keyhelper.js';
|
|
12
12
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { calculateMAC } from 'libsignal/src/crypto.js';
|
|
2
|
-
import { SenderMessageKey } from './sender-message-key';
|
|
2
|
+
import { SenderMessageKey } from './sender-message-key.js';
|
|
3
3
|
export class SenderChainKey {
|
|
4
4
|
constructor(iteration, chainKey) {
|
|
5
5
|
this.MESSAGE_KEY_SEED = Buffer.from([0x01]);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { proto } from '../../../WAProto/index.js';
|
|
2
|
-
import { CiphertextMessage } from './ciphertext-message';
|
|
2
|
+
import { CiphertextMessage } from './ciphertext-message.js';
|
|
3
3
|
export class SenderKeyDistributionMessage extends CiphertextMessage {
|
|
4
4
|
constructor(id, iteration, chainKey, signatureKey, serialized) {
|
|
5
5
|
super();
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { calculateSignature, verifySignature } from 'libsignal/src/curve.js';
|
|
2
2
|
import { proto } from '../../../WAProto/index.js';
|
|
3
|
-
import { CiphertextMessage } from './ciphertext-message';
|
|
3
|
+
import { CiphertextMessage } from './ciphertext-message.js';
|
|
4
4
|
export class SenderKeyMessage extends CiphertextMessage {
|
|
5
5
|
constructor(keyId, iteration, ciphertext, signatureKey, serialized) {
|
|
6
6
|
super();
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { BufferJSON } from '../../Utils/generics';
|
|
2
|
-
import { SenderKeyState } from './sender-key-state';
|
|
1
|
+
import { BufferJSON } from '../../Utils/generics.js';
|
|
2
|
+
import { SenderKeyState } from './sender-key-state.js';
|
|
3
3
|
export class SenderKeyRecord {
|
|
4
4
|
constructor(serialized) {
|
|
5
5
|
this.MAX_STATES = 5;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { SenderChainKey } from './sender-chain-key';
|
|
2
|
-
import { SenderMessageKey } from './sender-message-key';
|
|
1
|
+
import { SenderChainKey } from './sender-chain-key.js';
|
|
2
|
+
import { SenderMessageKey } from './sender-message-key.js';
|
|
3
3
|
interface SenderChainKeyStructure {
|
|
4
4
|
iteration: number;
|
|
5
5
|
seed: Uint8Array;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { SenderChainKey } from './sender-chain-key';
|
|
2
|
-
import { SenderMessageKey } from './sender-message-key';
|
|
1
|
+
import { SenderChainKey } from './sender-chain-key.js';
|
|
2
|
+
import { SenderMessageKey } from './sender-message-key.js';
|
|
3
3
|
export class SenderKeyState {
|
|
4
4
|
constructor(id, iteration, chainKey, signatureKeyPair, signatureKeyPublic, signatureKeyPrivate, senderKeyStateStructure) {
|
|
5
5
|
this.MAX_MESSAGE_KEYS = 2000;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { LIDMapping, SignalAuthState } from '../Types';
|
|
2
|
-
import type { SignalRepositoryWithLIDStore } from '../Types/Signal';
|
|
3
|
-
import type { ILogger } from '../Utils/logger';
|
|
1
|
+
import type { LIDMapping, SignalAuthState } from '../Types/index.js';
|
|
2
|
+
import type { SignalRepositoryWithLIDStore } from '../Types/Signal.js';
|
|
3
|
+
import type { ILogger } from '../Utils/logger.js';
|
|
4
4
|
export declare function makeLibSignalRepository(auth: SignalAuthState, logger: ILogger, pnToLIDFunc?: (jids: string[]) => Promise<LIDMapping[] | undefined>): SignalRepositoryWithLIDStore;
|
|
5
5
|
//# sourceMappingURL=libsignal.d.ts.map
|
package/lib/Signal/libsignal.js
CHANGED
|
@@ -3,12 +3,12 @@ import * as libsignal from 'libsignal';
|
|
|
3
3
|
// @ts-ignore
|
|
4
4
|
import { PreKeyWhisperMessage } from 'libsignal/src/protobufs.js';
|
|
5
5
|
import { LRUCache } from 'lru-cache';
|
|
6
|
-
import { generateSignalPubKey } from '../Utils';
|
|
7
|
-
import { isHostedLidUser, isHostedPnUser, isLidUser, isPnUser, jidDecode, transferDevice, WAJIDDomains } from '../WABinary';
|
|
8
|
-
import { SenderKeyName } from './Group/sender-key-name';
|
|
9
|
-
import { SenderKeyRecord } from './Group/sender-key-record';
|
|
10
|
-
import { GroupCipher, GroupSessionBuilder, SenderKeyDistributionMessage } from './Group';
|
|
11
|
-
import { LIDMappingStore } from './lid-mapping';
|
|
6
|
+
import { generateSignalPubKey } from '../Utils/index.js';
|
|
7
|
+
import { isHostedLidUser, isHostedPnUser, isLidUser, isPnUser, jidDecode, transferDevice, WAJIDDomains } from '../WABinary/index.js';
|
|
8
|
+
import { SenderKeyName } from './Group/sender-key-name.js';
|
|
9
|
+
import { SenderKeyRecord } from './Group/sender-key-record.js';
|
|
10
|
+
import { GroupCipher, GroupSessionBuilder, SenderKeyDistributionMessage } from './Group/index.js';
|
|
11
|
+
import { LIDMappingStore } from './lid-mapping.js';
|
|
12
12
|
/** Extract identity key from PreKeyWhisperMessage for identity change detection */
|
|
13
13
|
function extractIdentityFromPkmsg(ciphertext) {
|
|
14
14
|
try {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { LIDMapping, SignalKeyStoreWithTransaction } from '../Types';
|
|
2
|
-
import type { ILogger } from '../Utils/logger';
|
|
1
|
+
import type { LIDMapping, SignalKeyStoreWithTransaction } from '../Types/index.js';
|
|
2
|
+
import type { ILogger } from '../Utils/logger.js';
|
|
3
3
|
export declare class LIDMappingStore {
|
|
4
4
|
private readonly mappingCache;
|
|
5
5
|
private readonly keys;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { LRUCache } from 'lru-cache';
|
|
2
|
-
import { isHostedPnUser, isLidUser, isPnUser, jidDecode, jidNormalizedUser, WAJIDDomains } from '../WABinary';
|
|
2
|
+
import { isHostedPnUser, isLidUser, isPnUser, jidDecode, jidNormalizedUser, WAJIDDomains } from '../WABinary/index.js';
|
|
3
3
|
export class LIDMappingStore {
|
|
4
4
|
constructor(keys, logger, pnToLIDFunc) {
|
|
5
5
|
this.mappingCache = new LRUCache({
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export * from './types';
|
|
2
|
-
export * from './websocket';
|
|
1
|
+
export * from './types.js';
|
|
2
|
+
export * from './websocket.js';
|
|
3
3
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export * from './types';
|
|
2
|
-
export * from './websocket';
|
|
1
|
+
export * from './types.js';
|
|
2
|
+
export * from './websocket.js';
|
|
3
3
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { EventEmitter } from 'events';
|
|
2
2
|
import { URL } from 'url';
|
|
3
|
-
import type { SocketConfig } from '../../Types';
|
|
3
|
+
import type { SocketConfig } from '../../Types/index.js';
|
|
4
4
|
export declare abstract class AbstractSocketClient extends EventEmitter {
|
|
5
5
|
url: URL;
|
|
6
6
|
config: SocketConfig;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import WebSocket from 'ws';
|
|
2
|
-
import { DEFAULT_ORIGIN } from '../../Defaults';
|
|
3
|
-
import { AbstractSocketClient } from './types';
|
|
2
|
+
import { DEFAULT_ORIGIN } from '../../Defaults/index.js';
|
|
3
|
+
import { AbstractSocketClient } from './types.js';
|
|
4
4
|
export class WebSocketClient extends AbstractSocketClient {
|
|
5
5
|
constructor() {
|
|
6
6
|
super(...arguments);
|