BN_hex2bn

Parse a hexadecimal ASCII string into a BIGNUM.

Synopsis

Declared in <openssl/bn.h>

int
BN_hex2bn(
    BIGNUM** a,
    char const* str);

Return Value

Number of characters consumed from str on success, or 0 on parse error.

Parameters

NameDescription
aLocation of the BIGNUM pointer; allocated if *a is NULL.
strHex digit string; a leading '-' sets the negative flag.