Skip to content
Snippets Groups Projects
Commit 56867328 authored by Nikolay Sivov's avatar Nikolay Sivov Committed by Alexandre Julliard
Browse files

crypt32: Fix key buffer leak (Coverity).

parent 5ae2b885
Branches
Tags
No related merge requests found
......@@ -2553,6 +2553,7 @@ static BOOL CNG_ImportECCPubKey(CERT_PUBLIC_KEY_INFO *pubKeyInfo, BCRYPT_KEY_HAN
memcpy(ecckey + 1, pubKeyInfo->PublicKey.pbData + 1, pubKeyInfo->PublicKey.cbData - 1);
status = BCryptImportKeyPair(alg, NULL, BCRYPT_ECCPUBLIC_BLOB, key, (BYTE*)ecckey, ecckey_len, 0);
CryptMemFree(ecckey);
done:
if (alg) BCryptCloseAlgorithmProvider(alg, 0);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment