Encode an ASN.1 value described by it to DER.
Declared in <openssl/asn1.h>
int
ASN1_item_i2d(
ASN1_VALUE const* val,
unsigned char** out,
ASN1_ITEM const* it);
Number of bytes encoded, or a negative value on error.
| Name | Description |
|---|---|
| val | Value to encode (typed according to it). |
| out | Destination pointer updated like a standard i2d encoder, or NULL to measure length. |
| it | ASN.1 item descriptor for the type of val. |