kore-web-sdk 11.26.0 → 11.26.1

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/README.md CHANGED
@@ -71,7 +71,7 @@ include the following script in your html file and configure bot configurations
71
71
 
72
72
  ```js
73
73
 
74
- <script src="https://cdn.jsdelivr.net/npm/kore-web-sdk@11.26.0/dist/umd/kore-web-sdk-umd-chat.min.js"></script>
74
+ <script src="https://cdn.jsdelivr.net/npm/kore-web-sdk@11.26.1/dist/umd/kore-web-sdk-umd-chat.min.js"></script>
75
75
  <script>
76
76
  //chat window declaration
77
77
  var chatConfig=KoreChatSDK.chatConfig;
@@ -0,0 +1,75 @@
1
+ export default SecureChannel;
2
+ export namespace STATE {
3
+ const INIT: string;
4
+ const AWAITING_RESPONSE: string;
5
+ const AWAITING_ACK: string;
6
+ const SECURE: string;
7
+ const FAILED: string;
8
+ }
9
+ export namespace MSG {
10
+ const INIT_1: string;
11
+ export { INIT_1 as INIT };
12
+ export const RESPONSE: string;
13
+ export const COMPLETE: string;
14
+ export const ACK: string;
15
+ export const ENVELOPE: string;
16
+ export const REKEY_SIGNAL: string;
17
+ export const REKEY_ACK: string;
18
+ export const CAPABILITIES: string;
19
+ }
20
+ declare class SecureChannel {
21
+ constructor({ pinnedPublicKeyPem, sessionId, expectedSigningKeyId }?: {
22
+ pinnedPublicKeyPem: any;
23
+ sessionId: any;
24
+ expectedSigningKeyId: any;
25
+ });
26
+ pinnedPublicKeyPem: string;
27
+ expectedSigningKeyId: any;
28
+ sessionId: any;
29
+ state: string;
30
+ privateKey: CryptoKey | null;
31
+ publicKeyRaw: Uint8Array | null;
32
+ c2sNonce: Uint8Array | null;
33
+ s2cNonce: Uint8Array | null;
34
+ sharedSecret: Uint8Array | null;
35
+ salt: Uint8Array | null;
36
+ generation: number;
37
+ k_c2s: CryptoKey | null;
38
+ k_s2c: CryptoKey | null;
39
+ c2sSeq: bigint;
40
+ s2cSeq: bigint;
41
+ outboundLock: Promise<void>;
42
+ inboundLock: Promise<void>;
43
+ initiateHandshake(): Promise<{
44
+ type: string;
45
+ version: string;
46
+ clientPublicKey: string;
47
+ c2sNonce: string;
48
+ sessionId: any;
49
+ }>;
50
+ handleResponse(msg: any): Promise<{
51
+ type: string;
52
+ iv: string;
53
+ ciphertext: string;
54
+ tag: string;
55
+ }>;
56
+ handleAck(msg: any): Promise<void>;
57
+ encryptOutgoing(plainObj: any): Promise<{
58
+ type: string;
59
+ gen: number;
60
+ iv: string;
61
+ ciphertext: string;
62
+ tag: string;
63
+ }>;
64
+ decryptIncoming(envelope: any): Promise<any>;
65
+ handleRekeySignal(controlMsg: any): Promise<{
66
+ type: string;
67
+ gen: number;
68
+ iv: string;
69
+ ciphertext: string;
70
+ tag: string;
71
+ }>;
72
+ isSecure(): boolean;
73
+ isFailed(): boolean;
74
+ installGeneration(gen: any): Promise<void>;
75
+ }
@@ -0,0 +1,36 @@
1
+ export default SecureChannelController;
2
+ declare class SecureChannelController {
3
+ constructor({ config, rawSend }?: {
4
+ config: any;
5
+ rawSend: any;
6
+ });
7
+ config: any;
8
+ rawSend: any;
9
+ channel: SecureChannel | null;
10
+ handshakeTimer: NodeJS.Timeout | null;
11
+ _inbound: Promise<void>;
12
+ _outboundQueue: any[];
13
+ isSecure(): boolean;
14
+ isRelevant(message: any): boolean;
15
+ reset(reason: any): void;
16
+ _clearTimer(): void;
17
+ _armTimer(): void;
18
+ processOutgoing(frame: any): Promise<any>;
19
+ _isProtocolFrame(frame: any): boolean;
20
+ _flushOutbound(): void;
21
+ processIncoming(frame: any): Promise<{
22
+ handled: boolean;
23
+ plaintext?: undefined;
24
+ } | {
25
+ handled: boolean;
26
+ plaintext: any;
27
+ }>;
28
+ _handleIncoming(frame: any): Promise<{
29
+ handled: boolean;
30
+ plaintext?: undefined;
31
+ } | {
32
+ handled: boolean;
33
+ plaintext: any;
34
+ }>;
35
+ }
36
+ import SecureChannel from "./secureChannel.js";