/** * @prettier * * Utility methods for Ellipic-Curve Diffie-Hellman (ECDH) shared secret generation * * > Elliptic-curve Diffie–Hellman (ECDH) is a key agreement protocol that allows two parties, each having an * > elliptic-curve public–private key pair, to establish a shared secret over an insecure channel. * > This shared secret may be directly used as a key, or to derive another key. The key, or the derived key, can then * > be used to encrypt subsequent communications using a symmetric-key cipher. It is a variant of the Diffie–Hellman * > protocol using elliptic-curve cryptography. * * https://en.wikipedia.org/wiki/Elliptic-curve_Diffie%E2%80%93Hellman */ /// import { ECPairInterface, BIP32Interface } from '@bitgo-beta/utxo-lib'; /** * Calculate the Elliptic Curve Diffie Hellman * @param privateKey HDNode of private key * @param publicKey [neutered] HDNode of public key * @returns Buffer public key buffer that can be used as shared secret (see note) */ export declare function getSharedSecret(privateKey: BIP32Interface | ECPairInterface | Buffer, publicKey: BIP32Interface | Buffer): Buffer; //# sourceMappingURL=ecdh.d.ts.map