asn1_der_coding3
Api function
Usage
#include <libtasn1.h>
int asn1_der_coding(asn1_node_const element, const char * name, void * ider, int * len, char * ErrorDescription);
Arguments
- asn1_node_const element
-
pointer to an ASN1 element
- const char * name
-
the name of the structure you want to encode (it must be inside *POINTER).
- void * ider
-
vector that will contain the DER encoding. DER must be a pointer to memory cells already allocated.
- int * len
-
number of bytes of * ider : ider [0].. ider [len-1], Initially holds the sizeof of der vector.
- char * ErrorDescription
-
return the error description or an empty string if success.
Overview
Creates the DER encoding for the NAME structure (inside *POINTER structure).
Returns
ASN1_SUCCESS if DER encoding OK, ASN1_ELEMENT_NOT_FOUND if name is not a valid element, ASN1_VALUE_NOT_FOUND if there is an element without a value, ASN1_MEM_ERROR if the ider vector isn't big enough and in this case len will contain the length needed.
Releases
11 releases since Debian 4.0 (Etch); the text changed 9 times.