ecdh.getPublicKey([encoding][, format])
encoding<string> 返回值的编码。format<string> 默认值:'uncompressed'- 返回: <Buffer> | <string> 指定
encoding和format中的 EC Diffie-Hellman 公钥。
format 参数指定点编码,可以是 'compressed' 或 'uncompressed'。
如果未指定 format,该点将以 'uncompressed' 格式返回。
如果指定了 encoding,则返回字符串;否则返回 Buffer。
encoding<string> The encoding of the return value.format<string> Default:'uncompressed'- Returns: <Buffer> | <string> The EC Diffie-Hellman public key in the specified
encodingandformat.
The format argument specifies point encoding and can be 'compressed' or
'uncompressed'. If format is not specified the point will be returned in
'uncompressed' format.
If encoding is specified, a string is returned; otherwise a Buffer is
returned.