EC_KEY_key2buf

Encodes an EC_KEY public key to an allocated octet string

Synopsis

Declared in <openssl/ec.h>

[[deprecated]]
size_t
EC_KEY_key2buf(
    EC_KEY const* key,
    point_conversion_form_t form,
    unsigned char** pbuf,
    BN_CTX* ctx);

WARNING

Deprecated. Use of this entity is allowed but discouraged.

Return Value

the length of the encoded octet string or 0 if an error occurred

Parameters

NameDescription
keykey to encode
formpoint conversion form
pbufreturns pointer to allocated buffer
ctxBN_CTX object (optional)