ecdh.setPrivateKey()

ecdh.setPrivateKey(private_key[, encoding])

Sets the EC Diffie-Hellman private key. The encoding can be 'binary', 'hex' or 'base64'. If encoding is provided, private_key is expected to be a string; otherwise private_key is expected to be a Buffer. If private_key is not valid for the curve specified when the ECDH object was created, an error is thrown. Upon setting the private key, the associated public point (key) is also generated and set in the ECDH object.

doc_Nodejs
2016-04-30 04:39:07
Comments
Leave a Comment

Please login to continue.