[PATCH 2/7] bcrypt: Copy all fields in key_duplicate.
Hans Leidekker
hans at codeweavers.com
Mon Oct 19 04:24:11 CDT 2020
Signed-off-by: Hans Leidekker <hans at codeweavers.com>
---
dlls/bcrypt/bcrypt_main.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/dlls/bcrypt/bcrypt_main.c b/dlls/bcrypt/bcrypt_main.c
index b0ea7fce191..4eb1fc29e94 100644
--- a/dlls/bcrypt/bcrypt_main.c
+++ b/dlls/bcrypt/bcrypt_main.c
@@ -1476,8 +1476,11 @@ static NTSTATUS key_duplicate( struct key *key_orig, struct key *key_copy )
if (!(buffer = heap_alloc( key_orig->u.a.pubkey_len ))) return STATUS_NO_MEMORY;
memcpy( buffer, key_orig->u.a.pubkey, key_orig->u.a.pubkey_len );
+ key_copy->u.a.bitlen = key_orig->u.a.bitlen;
+ key_copy->u.a.flags = key_orig->u.a.flags;
key_copy->u.a.pubkey = buffer;
key_copy->u.a.pubkey_len = key_orig->u.a.pubkey_len;
+ key_copy->u.a.dss_seed = key_orig->u.a.dss_seed;
if ((status = key_funcs->key_asymmetric_duplicate( key_orig, key_copy ))) return status;
}
--
2.28.0
More information about the wine-devel
mailing list