Lines Matching refs:csr
167 X509_REQ *csr; member
200 X509_REQ_free(x509_request->csr); in php_openssl_request_free_obj()
2944 static int php_openssl_make_REQ(struct php_x509_request * req, X509_REQ * csr, zval * dn, zval * at… in php_openssl_make_REQ() argument
2970 if (X509_REQ_set_version(csr, 0L)) { in php_openssl_make_REQ()
2978 subj = X509_REQ_get_subject_name(csr); in php_openssl_make_REQ()
3086 if (X509_REQ_get_attr_by_NID(csr, nid, -1) >= 0) { in php_openssl_make_REQ()
3089 if (!X509_REQ_add1_attr_by_txt(csr, v->name, MBSTRING_UTF8, (unsigned char*)v->value, -1)) { in php_openssl_make_REQ()
3104 if (!X509_REQ_set_pubkey(csr, req->priv_key)) { in php_openssl_make_REQ()
3114 X509_REQ * csr = NULL; in php_openssl_csr_from_str() local
3132 csr = PEM_read_bio_X509_REQ(in, NULL,NULL,NULL); in php_openssl_csr_from_str()
3133 if (csr == NULL) { in php_openssl_csr_from_str()
3139 return csr; in php_openssl_csr_from_str()
3146 return php_openssl_request_from_obj(csr_obj)->csr; in php_openssl_csr_from_param()
3157 X509_REQ *csr; in PHP_FUNCTION() local
3175 csr = php_openssl_csr_from_param(csr_obj, csr_str, 1); in PHP_FUNCTION()
3176 if (csr == NULL) { in PHP_FUNCTION()
3187 if (!notext && !X509_REQ_print(bio_out, csr)) { in PHP_FUNCTION()
3190 if (!PEM_write_bio_X509_REQ(bio_out, csr)) { in PHP_FUNCTION()
3203 X509_REQ_free(csr); in PHP_FUNCTION()
3211 X509_REQ *csr; in PHP_FUNCTION() local
3227 csr = php_openssl_csr_from_param(csr_obj, csr_str, 1); in PHP_FUNCTION()
3228 if (csr == NULL) { in PHP_FUNCTION()
3236 if (!notext && !X509_REQ_print(bio_out, csr)) { in PHP_FUNCTION()
3240 if (PEM_write_bio_X509_REQ(bio_out, csr)) { in PHP_FUNCTION()
3252 X509_REQ_free(csr); in PHP_FUNCTION()
3261 X509_REQ *csr; in PHP_FUNCTION() local
3288 csr = php_openssl_csr_from_param(csr_obj, csr_str, 1); in PHP_FUNCTION()
3289 if (csr == NULL) { in PHP_FUNCTION()
3321 key = X509_REQ_get_pubkey(csr); in PHP_FUNCTION()
3327 i = X509_REQ_verify(csr, key); in PHP_FUNCTION()
3358 X509_set_subject_name(new_cert, X509_REQ_get_subject_name(csr)); in PHP_FUNCTION()
3377 X509V3_set_ctx(&ctx, cert, new_cert, csr, NULL, 0); in PHP_FUNCTION()
3406 X509_REQ_free(csr); in PHP_FUNCTION()
3421 X509_REQ *csr = NULL; in PHP_FUNCTION() local
3446 csr = X509_REQ_new(); in PHP_FUNCTION()
3447 if (csr) { in PHP_FUNCTION()
3448 if (php_openssl_make_REQ(&req, csr, dn, attribs) == SUCCESS) { in PHP_FUNCTION()
3451 X509V3_set_ctx(&ext_ctx, NULL, NULL, csr, NULL, 0); in PHP_FUNCTION()
3456 &ext_ctx, req.request_extensions_section, csr)) in PHP_FUNCTION()
3463 if (X509_REQ_sign(csr, req.priv_key, req.digest)) { in PHP_FUNCTION()
3466 x509_request_obj->csr = csr; in PHP_FUNCTION()
3467 csr = NULL; in PHP_FUNCTION()
3492 if (csr) { in PHP_FUNCTION()
3493 X509_REQ_free(csr); in PHP_FUNCTION()
3502 X509_REQ *csr; in PHP_FUNCTION() local
3514 csr = php_openssl_csr_from_param(csr_obj, csr_str, 1); in PHP_FUNCTION()
3515 if (csr == NULL) { in PHP_FUNCTION()
3519 subject = X509_REQ_get_subject_name(csr); in PHP_FUNCTION()
3525 X509_REQ_free(csr); in PHP_FUNCTION()
3533 X509_REQ *orig_csr, *csr; in PHP_FUNCTION() local
3558 csr = X509_REQ_dup(orig_csr); in PHP_FUNCTION()
3560 csr = orig_csr; in PHP_FUNCTION()
3564 tpubkey = X509_REQ_get_pubkey(csr); in PHP_FUNCTION()
3566 if (csr != orig_csr) { in PHP_FUNCTION()
3568 X509_REQ_free(csr); in PHP_FUNCTION()