diff options
author | Ted Unangst <tedu@cvs.openbsd.org> | 2014-06-15 22:53:22 +0000 |
---|---|---|
committer | Ted Unangst <tedu@cvs.openbsd.org> | 2014-06-15 22:53:22 +0000 |
commit | 86237c6f2c785107ae29608513b0fbe60b8c3fd1 (patch) | |
tree | c04e4180a66ef2464b0886fd794b97c0e635e273 /lib/libssl | |
parent | a92394fce55812a7215f98cc7109cd9cf547f15d (diff) |
free iv, then cleanse. from Cyril Jouve
Diffstat (limited to 'lib/libssl')
-rw-r--r-- | lib/libssl/src/crypto/evp/e_aes.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libssl/src/crypto/evp/e_aes.c b/lib/libssl/src/crypto/evp/e_aes.c index 8ee93c4bbd1..f40bcf8bd38 100644 --- a/lib/libssl/src/crypto/evp/e_aes.c +++ b/lib/libssl/src/crypto/evp/e_aes.c @@ -1,4 +1,4 @@ -/* $OpenBSD: e_aes.c,v 1.21 2014/06/15 15:41:25 jsing Exp $ */ +/* $OpenBSD: e_aes.c,v 1.22 2014/06/15 22:53:21 tedu Exp $ */ /* ==================================================================== * Copyright (c) 2001-2011 The OpenSSL Project. All rights reserved. * @@ -651,9 +651,9 @@ aes_gcm_cleanup(EVP_CIPHER_CTX *c) { EVP_AES_GCM_CTX *gctx = c->cipher_data; - OPENSSL_cleanse(gctx, sizeof(*gctx)); if (gctx->iv != c->iv) free(gctx->iv); + OPENSSL_cleanse(gctx, sizeof(*gctx)); return 1; } |