nvat_nonce_from_hex#

nvat_rc_t nvat_nonce_from_hex(
nvat_nonce_t *out_nonce,
const char *hex_string,
)#

Create a nonce from a hex-encoded string.

Accepts optional “0x” or “0X” prefix. The hex string must contain an even number of hex digits and decode to at least 32 bytes.

Parameters:
  • out_nonce – On success, set to a newly allocated nonce. Caller owns it; free with nvat_nonce_free().

  • hex_string – The hex-encoded string representation of the nonce.