Fix leak in HMAC error path
authorMatt Caswell <matt@openssl.org>
Mon, 8 Jun 2015 08:29:56 +0000 (09:29 +0100)
committerMatt Caswell <matt@openssl.org>
Wed, 10 Jun 2015 10:06:05 +0000 (11:06 +0100)
commit3e8f9dc1a07df10dd52544efa269628744a40173
tree5678eda7e9406a5f88b7d4ae21076aa129a19904
parent7cb79c7afb043e80eb9a4f7ff36f5a7a80cdd8c9
Fix leak in HMAC error path

In the event of an error in the HMAC function, leaks can occur because the
HMAC_CTX does not get cleaned up.

Thanks to the BoringSSL project for reporting this issue.

Reviewed-by: Richard Levitte <levitte@openssl.org>
(cherry picked from commit e43a13c807e42688c72c4f3d001112bf0a110464)
crypto/hmac/hmac.c