nrfxlib API 3.3.99
Loading...
Searching...
No Matches

◆ cc3xx_asn1_get_len()

psa_status_t cc3xx_asn1_get_len ( unsigned char ** p,
const unsigned char * end,
size_t * len )

Get the length of an ASN.1 element. Updates the pointer to immediately behind the length.

Parameters
pOn entry, *p points to the first byte of the length, i.e. immediately after the tag. On successful completion, *p points to the first byte after the length, i.e. the first byte of the content. On error, the value of *p is undefined.
endEnd of data.
lenOn successful completion, *len contains the length read from the ASN.1 input.
Returns
PSA_SUCCESS if successful.
PSA_ERROR_BUFFER_TOO_SMALL if the buffer is too small.
PSA_ERROR_GENERIC_ERROR if any other error occured.