From: Tobias Brunner Date: Tue, 11 Jul 2023 09:44:11 +0000 (+0200) Subject: pkcs12: Make sure to wipe potentially decrypted PKCS#7 data X-Git-Tag: android-2.4.2~13 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=bbbd15dd5c13d96ec09384a6e33db9220e3e3f8f;p=thirdparty%2Fstrongswan.git pkcs12: Make sure to wipe potentially decrypted PKCS#7 data --- diff --git a/src/libstrongswan/plugins/pkcs12/pkcs12_decode.c b/src/libstrongswan/plugins/pkcs12/pkcs12_decode.c index 6f8f06f271..bed02cc423 100644 --- a/src/libstrongswan/plugins/pkcs12/pkcs12_decode.c +++ b/src/libstrongswan/plugins/pkcs12/pkcs12_decode.c @@ -307,10 +307,10 @@ static bool parse_authenticated_safe(private_pkcs12_t *this, chunk_t blob) if (!parse_safe_contents(this, parser->get_level(parser)+1, data)) { - chunk_free(&data); + chunk_clear(&data); goto end; } - chunk_free(&data); + chunk_clear(&data); break; } }