EC_POINT_point2hex

Encode an EC point as a newly allocated hexadecimal octet string.

Synopsis

Declared in <openssl/ec.h>

char*
EC_POINT_point2hex(
    EC_GROUP const* group,
    EC_POINT const* point,
    point_conversion_form_t form,
    BN_CTX* ctx);

Return Value

NUL-terminated hex string (caller must OPENSSL_free), or NULL on error.

Parameters

NameDescription
groupCurve that defines the point encoding.
pointPoint to encode.
formConversion form such as POINT_CONVERSION_UNCOMPRESSED.
ctxBN_CTX for temporary values, or NULL to allocate internally.