mirror of
https://git.haproxy.org/git/haproxy.git/
synced 2026-05-04 12:41:00 +02:00
BUG/MINOR: ssl/acme: free EVP_PKEY upon error
Free the EPV_PKEY upon error when the X509_REQ generation failed. No backport needed.
This commit is contained in:
parent
12c7189bc8
commit
0897175d73
@ -2011,6 +2011,7 @@ static int cli_acme_renew_parse(char **args, char *payload, struct appctx *appct
|
||||
|
||||
EVP_PKEY_free(newstore->data->key);
|
||||
newstore->data->key = pkey;
|
||||
pkey = NULL;
|
||||
|
||||
ctx->req = acme_x509_req(pkey, store->conf.acme.domains);
|
||||
if (!ctx->req) {
|
||||
@ -2028,6 +2029,7 @@ static int cli_acme_renew_parse(char **args, char *payload, struct appctx *appct
|
||||
|
||||
err:
|
||||
HA_SPIN_UNLOCK(CKCH_LOCK, &ckch_lock);
|
||||
EVP_PKEY_free(pkey);
|
||||
ckch_store_free(newstore);
|
||||
EVP_PKEY_CTX_free(pkey_ctx);
|
||||
free(ctx);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user