From 0cd8b50bee96bcf51ab3bda33091fd41c66ea76f Mon Sep 17 00:00:00 2001 From: fengweihao Date: Fri, 11 Nov 2022 10:43:59 +0800 Subject: [PATCH] =?UTF-8?q?TSG-12599=20certstore=E9=80=82=E9=85=8D?= =?UTF-8?q?=E9=9D=9E=E5=8F=AF=E4=BF=A1=E8=AF=81=E4=B9=A6=E8=AF=BB=E5=8F=96?= =?UTF-8?q?keyring=5Fid?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- program/src/cert_session.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/program/src/cert_session.cpp b/program/src/cert_session.cpp index f541dfb..3ad22e6 100644 --- a/program/src/cert_session.cpp +++ b/program/src/cert_session.cpp @@ -1143,14 +1143,13 @@ static int x509_online_append(struct x509_object_ctx *def, struct tfe_http_reque STACK_OF(X509) **stack_ca) { X509* x509 = NULL; - int is_valid = request->is_valid; int keyring_id = request->keyring_id; + int is_valid = 1; int keyring_id = request->keyring_id; int expire_time = 0; char *serial = NULL; X509 *cacrt = NULL; EVP_PKEY *cakey = NULL; char *v3_ctl=NULL, *public_algo=NULL; struct config_bucket_t *rte = cfg_instanec(); - if (is_valid == 0 && keyring_id != 0) keyring_id = 0; if (is_valid == 1 && keyring_id == 0) keyring_id = 1; struct pxy_obj_keyring *pxy_obj = get_obj_for_id(keyring_id); @@ -1159,7 +1158,6 @@ static int x509_online_append(struct x509_object_ctx *def, struct tfe_http_reque if (!rte->local_debug) { if (1==is_valid) pxy_obj = get_obj_for_id(1); - if (0==is_valid) pxy_obj = get_obj_for_id(0); if (pxy_obj == NULL) { mesa_runtime_log(RLOG_LV_FATAL, MODULE_NAME, "Get the default keypair failed, EXIT!!!");