import { CryptoKey, CryptoKeyPair } from './types'; import { EncryptedData, RPCRequest, RPCResponse } from '../message'; export declare function generateKeyPair(): Promise; export declare function deriveSharedSecret(ownPrivateKey: CryptoKey, peerPublicKey: CryptoKey): Promise; export declare function encrypt(sharedSecret: CryptoKey, plainText: string): Promise; export declare function decrypt(sharedSecret: CryptoKey, { iv, cipherText }: EncryptedData): Promise; export declare function exportKeyToHexString(type: 'public' | 'private', key: CryptoKey): Promise; export declare function importKeyFromHexString(type: 'public' | 'private', hexString: string): Promise; export declare function encryptContent(content: RPCRequest | RPCResponse, sharedSecret: CryptoKey): Promise; export declare function decryptContent(encryptedData: { iv: Uint8Array; cipherText: Uint8Array; }, sharedSecret: CryptoKey): Promise;