Commit b5d1bfe5 authored by Juan Lang's avatar Juan Lang Committed by Alexandre Julliard

crypt32: Set the info status on the last element of a chain even if its issuer can't be found.

parent 913affe4
......@@ -995,8 +995,7 @@ static PCCERT_CONTEXT CRYPT_GetIssuer(HCERTSTORE store, PCCERT_CONTEXT subject,
issuer = CertFindCertificateInStore(store,
subject->dwCertEncodingType, 0, CERT_FIND_SUBJECT_NAME,
&subject->pCertInfo->Issuer, prevIssuer);
if (issuer)
*infoStatus = CERT_TRUST_HAS_NAME_MATCH_ISSUER;
*infoStatus = CERT_TRUST_HAS_NAME_MATCH_ISSUER;
}
return issuer;
}
......@@ -1013,12 +1012,13 @@ static BOOL CRYPT_BuildSimpleChain(PCertificateChainEngine engine,
while (ret && !CRYPT_IsSimpleChainCyclic(chain) &&
!CRYPT_IsCertificateSelfSigned(cert))
{
DWORD infoStatus;
PCCERT_CONTEXT issuer = CRYPT_GetIssuer(world, cert, NULL, &infoStatus);
PCCERT_CONTEXT issuer = CRYPT_GetIssuer(world, cert, NULL,
&chain->rgpElement[chain->cElement - 1]->TrustStatus.dwInfoStatus);
if (issuer)
{
ret = CRYPT_AddCertToSimpleChain(engine, chain, issuer, infoStatus);
ret = CRYPT_AddCertToSimpleChain(engine, chain, issuer,
chain->rgpElement[chain->cElement - 1]->TrustStatus.dwInfoStatus);
/* CRYPT_AddCertToSimpleChain add-ref's the issuer, so free it to
* close the enumeration that found it
*/
......
......@@ -1620,7 +1620,7 @@ static ChainCheck chainCheckNoStore[] = {
{ { 0, CERT_TRUST_HAS_PREFERRED_ISSUER },
{ CERT_TRUST_IS_PARTIAL_CHAIN, 0 },
1, simpleStatus8NoStore },
TODO_INFO },
0 },
};
/* Wednesday, Oct 1, 2007 */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment