Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
jajbshjahavahh
GitHub Repository: jajbshjahavahh/Gojo-Satoru
Path: blob/master/node_modules/@adiwajshing/baileys/lib/Utils/noise-handler.d_1.ts
2593 views
1
/// <reference types="node" />
2
import { proto } from '../../WAProto';
3
import { KeyPair } from '../Types';
4
import { BinaryNode } from '../WABinary';
5
export declare const makeNoiseHandler: ({ public: publicKey, private: privateKey }: KeyPair) => {
6
encrypt: (plaintext: Uint8Array) => Buffer;
7
decrypt: (ciphertext: Uint8Array) => Buffer;
8
authenticate: (data: Uint8Array) => void;
9
mixIntoKey: (data: Uint8Array) => void;
10
finishInit: () => void;
11
processHandshake: ({ serverHello }: proto.HandshakeMessage, noiseKey: KeyPair) => Buffer;
12
encodeFrame: (data: Buffer | Uint8Array) => Uint8Array;
13
decodeFrame: (newData: Buffer | Uint8Array, onFrame: (buff: Uint8Array | BinaryNode) => void) => void;
14
};
15
16