diff --git a/ext/phar/util.c b/ext/phar/util.c index a1f9863ae3a98..fe177f9644436 100644 --- a/ext/phar/util.c +++ b/ext/phar/util.c @@ -1640,6 +1640,7 @@ zend_result phar_verify_signature(php_stream *fp, size_t end_of_phar, uint32_t s if (md_ctx) { EVP_MD_CTX_destroy(md_ctx); } + EVP_PKEY_free(key); if (error) { spprintf(error, 0, "openssl signature could not be verified"); }