Juan Lang : crypt32:
Use the caller-supplied encoding type when decoding certs.
Alexandre Julliard
julliard at wine.codeweavers.com
Tue May 16 13:54:31 CDT 2006
Module: wine
Branch: refs/heads/master
Commit: 9b589c3556b425455b17902ffe0f5f21aaeb8fe2
URL: http://source.winehq.org/git/?p=wine.git;a=commit;h=9b589c3556b425455b17902ffe0f5f21aaeb8fe2
Author: Juan Lang <juan_lang at yahoo.com>
Date: Tue May 16 11:11:15 2006 -0700
crypt32: Use the caller-supplied encoding type when decoding certs.
---
dlls/crypt32/store.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/dlls/crypt32/store.c b/dlls/crypt32/store.c
index 5ba176a..6fafc5a 100644
--- a/dlls/crypt32/store.c
+++ b/dlls/crypt32/store.c
@@ -1764,12 +1764,12 @@ static PWINE_CERT_CONTEXT CRYPT_CreateCe
cbCertEncoded);
/* First try to decode it as a signed cert. */
- ret = CryptDecodeObjectEx(X509_ASN_ENCODING, X509_CERT, pbCertEncoded,
+ ret = CryptDecodeObjectEx(dwCertEncodingType, X509_CERT, pbCertEncoded,
cbCertEncoded, CRYPT_DECODE_ALLOC_FLAG, NULL, (BYTE *)&signedCert, &size);
if (ret)
{
size = 0;
- ret = CryptDecodeObjectEx(X509_ASN_ENCODING, X509_CERT_TO_BE_SIGNED,
+ ret = CryptDecodeObjectEx(dwCertEncodingType, X509_CERT_TO_BE_SIGNED,
signedCert->ToBeSigned.pbData, signedCert->ToBeSigned.cbData,
CRYPT_DECODE_ALLOC_FLAG, NULL, (BYTE *)&certInfo, &size);
LocalFree(signedCert);
@@ -1778,7 +1778,7 @@ static PWINE_CERT_CONTEXT CRYPT_CreateCe
if (!ret)
{
size = 0;
- ret = CryptDecodeObjectEx(X509_ASN_ENCODING, X509_CERT_TO_BE_SIGNED,
+ ret = CryptDecodeObjectEx(dwCertEncodingType, X509_CERT_TO_BE_SIGNED,
pbCertEncoded, cbCertEncoded,
CRYPT_DECODE_ALLOC_FLAG | CRYPT_DECODE_NOCOPY_FLAG, NULL,
(BYTE *)&certInfo, &size);
More information about the wine-cvs
mailing list