Lines Matching refs:NULL
51 OSSL_CRMF_ATTRIBUTETYPEANDVALUE *atav = NULL; \
53 if (msg == NULL || msg->certReq == NULL) \
54 return NULL; \
61 return NULL; \
66 OSSL_CRMF_ATTRIBUTETYPEANDVALUE *atav = NULL; \
68 if (msg == NULL || in == NULL) \
70 if ((atav = OSSL_CRMF_ATTRIBUTETYPEANDVALUE_new()) == NULL) \
72 if ((atav->type = OBJ_nid2obj(NID_id_##ctrlinf##_##atyp)) == NULL) \
74 if ((atav->value.atyp = valt##_dup(in)) == NULL) \
94 if (crm == NULL || crm->certReq == NULL || ctrl == NULL) { in OSSL_CRMF_MSG_push0_regCtrl()
99 if (crm->certReq->controls == NULL) { in OSSL_CRMF_MSG_push0_regCtrl()
101 if (crm->certReq->controls == NULL) in OSSL_CRMF_MSG_push0_regCtrl()
112 crm->certReq->controls = NULL; in OSSL_CRMF_MSG_push0_regCtrl()
127 if (spi == NULL in IMPLEMENT_CRMF_CTRL_FUNC()
145 if (pi == NULL || spi == NULL) { in OSSL_CRMF_MSG_PKIPublicationInfo_push0_SinglePubInfo()
149 if (pi->pubInfos == NULL) in OSSL_CRMF_MSG_PKIPublicationInfo_push0_SinglePubInfo()
151 if (pi->pubInfos == NULL) in OSSL_CRMF_MSG_PKIPublicationInfo_push0_SinglePubInfo()
160 if (pi == NULL in OSSL_CRMF_MSG_set_PKIPublicationInfo_action()
180 OSSL_CRMF_CERTID *cid = NULL; in IMPLEMENT_CRMF_CTRL_FUNC()
182 if (issuer == NULL || serial == NULL) { in IMPLEMENT_CRMF_CTRL_FUNC()
184 return NULL; in IMPLEMENT_CRMF_CTRL_FUNC()
187 if ((cid = OSSL_CRMF_CERTID_new()) == NULL) in IMPLEMENT_CRMF_CTRL_FUNC()
195 if ((cid->serialNumber = ASN1_INTEGER_dup(serial)) == NULL) in IMPLEMENT_CRMF_CTRL_FUNC()
202 return NULL; in IMPLEMENT_CRMF_CTRL_FUNC()
218 STACK_OF(OSSL_CRMF_ATTRIBUTETYPEANDVALUE) *info = NULL; in IMPLEMENT_CRMF_CTRL_FUNC()
220 if (crm == NULL || ri == NULL) { in IMPLEMENT_CRMF_CTRL_FUNC()
225 if (crm->regInfo == NULL) in IMPLEMENT_CRMF_CTRL_FUNC()
227 if (crm->regInfo == NULL) in IMPLEMENT_CRMF_CTRL_FUNC()
234 if (info != NULL) in IMPLEMENT_CRMF_CTRL_FUNC()
235 crm->regInfo = NULL; in IMPLEMENT_CRMF_CTRL_FUNC()
249 if (crm == NULL || crm->certReq == NULL) { in IMPLEMENT_CRMF_CTRL_FUNC()
251 return NULL; in IMPLEMENT_CRMF_CTRL_FUNC()
262 if (tmpl == NULL) { /* also crm == NULL implies this */ in OSSL_CRMF_MSG_set0_validity()
267 if ((vld = OSSL_CRMF_OPTIONALVALIDITY_new()) == NULL) in OSSL_CRMF_MSG_set0_validity()
277 if (crm == NULL || crm->certReq == NULL || crm->certReq->certReqId == NULL) { in OSSL_CRMF_MSG_set_certReqId()
307 if (crm == NULL || /* not really needed: */ crm->certReq == NULL) { in OSSL_CRMF_MSG_get_certReqId()
319 if (tmpl == NULL) { /* also crm == NULL implies this */ in OSSL_CRMF_MSG_set0_extensions()
326 exts = NULL; /* do not include empty extensions list */ in OSSL_CRMF_MSG_set0_extensions()
340 if (tmpl == NULL || ext == NULL) { /* also crm == NULL implies this */ in OSSL_CRMF_MSG_push0_extension()
345 if (tmpl->extensions == NULL) { in OSSL_CRMF_MSG_push0_extension()
346 if ((tmpl->extensions = sk_X509_EXTENSION_new_null()) == NULL) in OSSL_CRMF_MSG_push0_extension()
357 tmpl->extensions = NULL; in OSSL_CRMF_MSG_push0_extension()
370 if (ps == NULL || cr == NULL || pkey == NULL) { in create_popo_signature()
378 if (ps->poposkInput != NULL) { in create_popo_signature()
386 digest = NULL; in create_popo_signature()
390 NULL, ps->signature, /* sets the ASN1_BIT_STRING */ in create_popo_signature()
391 cr, NULL, pkey, digest, libctx, propq); in create_popo_signature()
398 OSSL_CRMF_POPO *pp = NULL; in OSSL_CRMF_MSG_create_popo()
399 ASN1_INTEGER *tag = NULL; in OSSL_CRMF_MSG_create_popo()
401 if (crm == NULL || (meth == OSSL_CRMF_POPO_SIGNATURE && pkey == NULL)) { in OSSL_CRMF_MSG_create_popo()
408 if ((pp = OSSL_CRMF_POPO_new()) == NULL) in OSSL_CRMF_MSG_create_popo()
414 if ((pp->value.raVerified = ASN1_NULL_new()) == NULL) in OSSL_CRMF_MSG_create_popo()
422 if (ps == NULL) in OSSL_CRMF_MSG_create_popo()
434 if ((pp->value.keyEncipherment = OSSL_CRMF_POPOPRIVKEY_new()) == NULL) in OSSL_CRMF_MSG_create_popo()
440 if (tag == NULL in OSSL_CRMF_MSG_create_popo()
465 OSSL_CRMF_MSG *req = NULL; in OSSL_CRMF_MSGS_verify_popo()
466 X509_PUBKEY *pubkey = NULL; in OSSL_CRMF_MSGS_verify_popo()
467 OSSL_CRMF_POPOSIGNINGKEY *sig = NULL; in OSSL_CRMF_MSGS_verify_popo()
471 if (reqs == NULL || (req = sk_OSSL_CRMF_MSG_value(reqs, rid)) == NULL) { in OSSL_CRMF_MSGS_verify_popo()
476 if (req->popo == NULL) { in OSSL_CRMF_MSGS_verify_popo()
490 if (pubkey == NULL) { in OSSL_CRMF_MSGS_verify_popo()
495 if (sig->poposkInput != NULL) { in OSSL_CRMF_MSGS_verify_popo()
501 if (sig->poposkInput->publicKey == NULL) { in OSSL_CRMF_MSGS_verify_popo()
518 if (req->certReq->certTemplate->subject == NULL) { in OSSL_CRMF_MSGS_verify_popo()
526 asn, NULL, X509_PUBKEY_get0(pubkey), libctx, in OSSL_CRMF_MSGS_verify_popo()
548 return tmpl != NULL ? tmpl->publicKey : NULL; in OSSL_CRMF_CERTTEMPLATE_get0_publicKey()
554 return tmpl != NULL ? tmpl->serialNumber : NULL; in OSSL_CRMF_CERTTEMPLATE_get0_serialNumber()
560 return tmpl != NULL ? tmpl->subject : NULL; in OSSL_CRMF_CERTTEMPLATE_get0_subject()
566 return tmpl != NULL ? tmpl->issuer : NULL; in OSSL_CRMF_CERTTEMPLATE_get0_issuer()
572 return tmpl != NULL ? tmpl->extensions : NULL; in OSSL_CRMF_CERTTEMPLATE_get0_extensions()
577 return cid != NULL && cid->issuer->type == GEN_DIRNAME ? in OSSL_CRMF_CERTID_get0_issuer()
578 cid->issuer->d.directoryName : NULL; in OSSL_CRMF_CERTID_get0_issuer()
584 return cid != NULL ? cid->serialNumber : NULL; in OSSL_CRMF_CERTID_get0_serialNumber()
597 if (tmpl == NULL) { in OSSL_CRMF_CERTTEMPLATE_fill()
601 if (subject != NULL && !X509_NAME_set((X509_NAME **)&tmpl->subject, subject)) in OSSL_CRMF_CERTTEMPLATE_fill()
603 if (issuer != NULL && !X509_NAME_set((X509_NAME **)&tmpl->issuer, issuer)) in OSSL_CRMF_CERTTEMPLATE_fill()
605 if (serial != NULL) { in OSSL_CRMF_CERTTEMPLATE_fill()
607 if ((tmpl->serialNumber = ASN1_INTEGER_dup(serial)) == NULL) in OSSL_CRMF_CERTTEMPLATE_fill()
610 if (pubkey != NULL && !X509_PUBKEY_set(&tmpl->publicKey, pubkey)) in OSSL_CRMF_CERTTEMPLATE_fill()
627 X509 *cert = NULL; /* decrypted certificate */ in OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert()
628 EVP_CIPHER_CTX *evp_ctx = NULL; /* context for symmetric encryption */ in OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert()
629 unsigned char *ek = NULL; /* decrypted symmetric encryption key */ in OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert()
631 EVP_CIPHER *cipher = NULL; /* used cipher */ in OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert()
633 unsigned char *iv = NULL; /* initial vector for symmetric encryption */ in OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert()
634 unsigned char *outbuf = NULL; /* decryption output buffer */ in OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert()
635 const unsigned char *p = NULL; /* needed for decoding ASN1 */ in OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert()
637 EVP_PKEY_CTX *pkctx = NULL; /* private key context */ in OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert()
640 if (ecert == NULL || ecert->symmAlg == NULL || ecert->encSymmKey == NULL in OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert()
641 || ecert->encValue == NULL || pkey == NULL) { in OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert()
643 return NULL; in OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert()
650 cipher = EVP_CIPHER_fetch(NULL, name, NULL); in OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert()
652 if (cipher == NULL) in OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert()
655 if (cipher == NULL) { in OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert()
665 if (pkctx == NULL || EVP_PKEY_decrypt_init(pkctx) <= 0 in OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert()
671 if ((iv = OPENSSL_malloc(EVP_CIPHER_get_iv_length(cipher))) == NULL) in OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert()
685 EVP_CIPHER_get_block_size(cipher))) == NULL in OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert()
686 || (evp_ctx = EVP_CIPHER_CTX_new()) == NULL) in OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert()
701 if ((cert = X509_new_ex(libctx, propq)) == NULL) in OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert()
703 if (d2i_X509(&cert, &p, outlen) == NULL) in OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert()