Go to the documentation of this file.
71 #include "../internal.h"
72 #include "../x509/internal.h"
78 int crit,
const char *
value);
83 int ext_nid,
int crit,
void *ext_struc);
123 int crit,
const char *
value)
143 if (nval == NULL || sk_CONF_VALUE_num(nval) <= 0) {
160 if (!
ctx->db || !
ctx->db_meth) {
176 method->ext_free(ext_struc);
182 int ext_nid,
int crit,
void *ext_struc)
184 unsigned char *ext_der;
197 ext_len =
method->i2d(ext_struc, NULL);
205 ext_oct->
data = ext_der;
206 ext_oct->
length = ext_len;
237 if ((strlen(
p) < 9) || strncmp(
p,
"critical,", 9))
240 while (isspace((
unsigned char)*
p))
251 if ((strlen(
p) >= 4) && !strncmp(
p,
"DER:", 4)) {
254 }
else if ((strlen(
p) >= 5) && !strncmp(
p,
"ASN1:", 5)) {
260 while (isspace((
unsigned char)*
p))
268 int crit,
int gen_type,
271 unsigned char *ext_der = NULL;
284 else if (gen_type == 2)
287 if (ext_der == NULL) {
317 unsigned char *ext_der = NULL;
340 for (
i = 0;
i < sk_CONF_VALUE_num(nval);
i++) {
341 val = sk_CONF_VALUE_value(nval,
i);
371 sk = &crl->
crl->extensions;
396 if (!
ctx->db || !
ctx->db_meth || !
ctx->db_meth->get_string) {
400 if (
ctx->db_meth->get_string)
407 if (!
ctx->db || !
ctx->db_meth || !
ctx->db_meth->get_section) {
411 if (
ctx->db_meth->get_section)
420 if (
ctx->db_meth->free_string)
428 if (
ctx->db_meth->free_section)
463 ctx->issuer_cert = issuer;
464 ctx->subject_cert = subj;
int X509V3_EXT_REQ_add_nconf(CONF *conf, X509V3_CTX *ctx, const char *section, X509_REQ *req)
static X509_EXTENSION * do_ext_i2d(const X509V3_EXT_METHOD *method, int ext_nid, int crit, void *ext_struc)
OPENSSL_EXPORT const ASN1_OBJECT * obj
static int v3_check_critical(const char **value)
#define X509V3_R_UNKNOWN_EXTENSION
char * X509V3_get_string(X509V3_CTX *ctx, const char *name, const char *section)
#define X509V3_EXT_get_nid
OPENSSL_EXPORT int i2d_ASN1_TYPE(const ASN1_TYPE *in, uint8_t **outp)
const Descriptor::ReservedRange const EnumValueDescriptor const MethodDescriptor extension
#define X509V3_R_EXTENSION_SETTING_NOT_SUPPORTED
#define OPENSSL_PUT_ERROR(library, reason)
#define x509v3_hex_to_bytes
#define X509V3_get_section
#define ASN1_ITEM_ptr(iptr)
static X509_EXTENSION * v3_generic_extension(const char *ext, const char *value, int crit, int type, X509V3_CTX *ctx)
#define X509_EXTENSION_create_by_NID
int X509V3_EXT_add_nconf_sk(CONF *conf, X509V3_CTX *ctx, const char *section, STACK_OF(X509_EXTENSION) **sk)
#define X509V3_R_OPERATION_NOT_DEFINED
OPENSSL_EXPORT ASN1_OCTET_STRING * ASN1_OCTET_STRING_new(void)
#define NCONF_get_section
void X509V3_set_ctx(X509V3_CTX *ctx, X509 *issuer, X509 *subj, X509_REQ *req, X509_CRL *crl, int flags)
OPENSSL_EXPORT void ASN1_TYPE_free(ASN1_TYPE *a)
#define X509V3_R_INVALID_EXTENSION_STRING
static char * nconf_get_string(void *db, const char *section, const char *value)
static X509_EXTENSION * do_ext_nconf(CONF *conf, X509V3_CTX *ctx, int ext_nid, int crit, const char *value)
#define X509_EXTENSION_create_by_OBJ
#define X509_EXTENSION_free
X509_EXTENSION * X509V3_EXT_nconf(CONF *conf, X509V3_CTX *ctx, const char *name, const char *value)
X509_EXTENSION * X509V3_EXT_nconf_nid(CONF *conf, X509V3_CTX *ctx, int ext_nid, const char *value)
int X509V3_EXT_add_nconf(CONF *conf, X509V3_CTX *ctx, const char *section, X509 *cert)
#define X509V3_R_UNKNOWN_EXTENSION_NAME
#define X509V3_parse_list
static int v3_check_generic(const char **value)
#define X509V3_R_ERROR_IN_EXTENSION
#define X509V3_R_NO_CONFIG_DATABASE
#define X509_REQ_add_extensions
UniquePtr< SSL_SESSION > ret
#define X509V3_R_EXTENSION_NAME_ERROR
#define X509V3_R_EXTENSION_VALUE_ERROR
#define ERR_add_error_data
int X509V3_EXT_CRL_add_nconf(CONF *conf, X509V3_CTX *ctx, const char *section, X509_CRL *crl)
void X509V3_string_free(X509V3_CTX *ctx, char *str)
void X509V3_section_free(X509V3_CTX *ctx, STACK_OF(CONF_VALUE) *section)
static unsigned char * generic_asn1(const char *value, X509V3_CTX *ctx, long *ext_len)
X509_EXTENSION * X509V3_EXT_i2d(int ext_nid, int crit, void *ext_struc)
void X509V3_set_nconf(X509V3_CTX *ctx, CONF *conf)
static const X509V3_CONF_METHOD nconf_method
OPENSSL_EXPORT void ASN1_OCTET_STRING_free(ASN1_OCTET_STRING *str)
#define ERR_R_MALLOC_FAILURE
grpc
Author(s):
autogenerated on Fri May 16 2025 03:00:50