Authority Information Access extension helpers. More...
#include "qsccommon.h"Go to the source code of this file.
Functions | |
| QSC_EXPORT_API bool | qsc_x509_aia_get_ocsp_url (const uint8_t *ext, size_t extlen, char *url, size_t *urllen) |
| Extract the OCSP responder URI from an Authority Information Access extension. | |
Authority Information Access extension helpers.
| QSC_EXPORT_API bool qsc_x509_aia_get_ocsp_url | ( | const uint8_t * | ext, |
| size_t | extlen, | ||
| char * | url, | ||
| size_t * | urllen ) |
Extract the OCSP responder URI from an Authority Information Access extension.
Parses the DER-encoded Authority Information Access extension value and locates an id-ad-ocsp access descriptor. When present, the URI is copied to the caller-supplied buffer and NUL-terminated.
This function does not allocate memory. The caller must provide an output buffer and set urllen to the capacity of that buffer on entry. On success, urllen receives the URI byte length excluding the terminating NUL.
| ext | [const] Pointer to the DER-encoded Authority Information Access extension value. |
| extlen | The extension length in bytes. |
| url | Output buffer receiving the URI string. |
| urllen | [in,out] On input, the output buffer capacity; on output, the URI length excluding the terminating NUL. |