From 797dae9d74aa7f02afe8669868ff9938ac38afba Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Kin=C4=8Dl?= Date: Fri, 17 May 2019 18:04:39 +0200 Subject: [PATCH] Fixed use of uninitialized value in wc_ecc_sig_to_rs. --- wolfcrypt/src/ecc.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/wolfcrypt/src/ecc.c b/wolfcrypt/src/ecc.c index 6a0a2c4bb..0e4954667 100644 --- a/wolfcrypt/src/ecc.c +++ b/wolfcrypt/src/ecc.c @@ -7043,6 +7043,9 @@ int wc_ecc_sig_to_rs(const byte* sig, word32 sigLen, byte* r, word32* rLen, } #endif + (void)XMEMSET(&rtmp, 0, sizeof(mp_int)); + (void)XMEMSET(&stmp, 0, sizeof(mp_int)); + err = DecodeECC_DSA_Sig(sig, sigLen, rtmp, stmp); /* extract r */