libressl-X509_get1_email3
Utilities for stacks of strings
Usage
Crypto Library (libcrypto, -lcrypto)
#include <openssl/x509v3.h>
typedef char *OPENSSL_STRING;
STACK_OF(OPENSSL_STRING) *
X509_get1_email(X509 *certificate);
STACK_OF(OPENSSL_STRING) *
X509_get1_ocsp(X509 *certificate);
void
X509_email_free(STACK_OF(OPENSSL_STRING) *stack);
Overview
X509_get1_email() retrieves all email addresses from the subject field and from any Subject Alternative Name extension of the certificate.
X509_get1_ocsp() retrieves all uniform resource identifiers from all AccessDescription objects having an accessMethod of OCSP which are contained in the Authority Information Access extension of the certificate.
X509_email_free() frees all strings stored in the stack as well as the stack itself. If stack is a NULL pointer, no action occurs.
Return values
X509_REQ_get1_email() and X509_get1_ocsp() return newly allocated stacks of char * containing copies of the addresses in question, or NULL if there are no addresses or if an error occurs.