diff options
Diffstat (limited to 'src/lib/libcrypto/cms/cms_env.c')
-rw-r--r-- | src/lib/libcrypto/cms/cms_env.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/lib/libcrypto/cms/cms_env.c b/src/lib/libcrypto/cms/cms_env.c index 63b24b6374..e483c4539f 100644 --- a/src/lib/libcrypto/cms/cms_env.c +++ b/src/lib/libcrypto/cms/cms_env.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: cms_env.c,v 1.8 2014/10/18 17:20:40 jsing Exp $ */ | 1 | /* $OpenBSD: cms_env.c,v 1.9 2015/09/10 15:56:25 jsing Exp $ */ |
2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL | 2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL |
3 | * project. | 3 | * project. |
4 | */ | 4 | */ |
@@ -406,7 +406,7 @@ cms_RecipientInfo_ktri_decrypt(CMS_ContentInfo *cms, CMS_RecipientInfo *ri) | |||
406 | ret = 1; | 406 | ret = 1; |
407 | 407 | ||
408 | if (ec->key) { | 408 | if (ec->key) { |
409 | OPENSSL_cleanse(ec->key, ec->keylen); | 409 | explicit_bzero(ec->key, ec->keylen); |
410 | free(ec->key); | 410 | free(ec->key); |
411 | } | 411 | } |
412 | 412 | ||
@@ -654,7 +654,7 @@ cms_RecipientInfo_kekri_encrypt(CMS_ContentInfo *cms, CMS_RecipientInfo *ri) | |||
654 | err: | 654 | err: |
655 | if (!r && wkey) | 655 | if (!r && wkey) |
656 | free(wkey); | 656 | free(wkey); |
657 | OPENSSL_cleanse(&actx, sizeof(actx)); | 657 | explicit_bzero(&actx, sizeof(actx)); |
658 | 658 | ||
659 | return r; | 659 | return r; |
660 | } | 660 | } |
@@ -727,7 +727,7 @@ cms_RecipientInfo_kekri_decrypt(CMS_ContentInfo *cms, CMS_RecipientInfo *ri) | |||
727 | err: | 727 | err: |
728 | if (!r && ukey) | 728 | if (!r && ukey) |
729 | free(ukey); | 729 | free(ukey); |
730 | OPENSSL_cleanse(&actx, sizeof(actx)); | 730 | explicit_bzero(&actx, sizeof(actx)); |
731 | 731 | ||
732 | return r; | 732 | return r; |
733 | } | 733 | } |
@@ -806,7 +806,7 @@ cms_EnvelopedData_init_bio(CMS_ContentInfo *cms) | |||
806 | err: | 806 | err: |
807 | ec->cipher = NULL; | 807 | ec->cipher = NULL; |
808 | if (ec->key) { | 808 | if (ec->key) { |
809 | OPENSSL_cleanse(ec->key, ec->keylen); | 809 | explicit_bzero(ec->key, ec->keylen); |
810 | free(ec->key); | 810 | free(ec->key); |
811 | ec->key = NULL; | 811 | ec->key = NULL; |
812 | ec->keylen = 0; | 812 | ec->keylen = 0; |