method DiffieHellman.prototype.computeSecret
Jump to headingDiffieHellman.prototype.computeSecret(otherPublicKey: ArrayBufferView,inputEncoding?: null,outputEncoding?: null,): BufferComputes the shared secret using otherPublicKey as the other
party's public key and returns the computed shared secret. The supplied
key is interpreted using the specified inputEncoding, and secret is
encoded using specified outputEncoding.
If the inputEncoding is not
provided, otherPublicKey is expected to be a Buffer, TypedArray, or DataView.
If outputEncoding is given a string is returned; otherwise, a Buffer is returned.
Parameters Jump to heading
Jump to headingotherPublicKey: ArrayBufferViewoptional
Jump to headinginputEncoding: nullThe encoding of an otherPublicKey string.
optional
Jump to headingoutputEncoding: nullThe encoding of the return value.
Return Type Jump to heading
BufferJump to headingDiffieHellman.prototype.computeSecret(): BufferParameters Jump to heading
Jump to headingotherPublicKey: stringJump to headinginputEncoding: BinaryToTextEncodingoptional
Jump to headingoutputEncoding: nullReturn Type Jump to heading
BufferJump to headingDiffieHellman.prototype.computeSecret(): stringParameters Jump to heading
Jump to headingotherPublicKey: ArrayBufferViewJump to headinginputEncoding: nullJump to headingoutputEncoding: BinaryToTextEncodingReturn Type Jump to heading
stringJump to headingDiffieHellman.prototype.computeSecret(): stringParameters Jump to heading
Jump to headingotherPublicKey: stringJump to headinginputEncoding: BinaryToTextEncodingJump to headingoutputEncoding: BinaryToTextEncodingReturn Type Jump to heading
string