Commit 8dde5c51 authored by Piotr Caban's avatar Piotr Caban Committed by Alexandre Julliard

wininet: Combine certificate errors in HTTP_OpenConnection.

parent ee72094c
......@@ -4381,6 +4381,17 @@ static DWORD HTTP_OpenConnection(http_request_t *lpwhr)
if(res != ERROR_SUCCESS)
{
WARN("Couldn't connect securely to host\n");
if((lpwhr->hdr.ErrorMask&INTERNET_ERROR_MASK_COMBINED_SEC_CERT) && (
res == ERROR_INTERNET_SEC_CERT_DATE_INVALID
|| res == ERROR_INTERNET_INVALID_CA
|| res == ERROR_INTERNET_SEC_CERT_NO_REV
|| res == ERROR_INTERNET_SEC_CERT_REV_FAILED
|| res == ERROR_INTERNET_SEC_CERT_REVOKED
|| res == ERROR_INTERNET_SEC_INVALID_CERT
|| res == ERROR_INTERNET_SEC_CERT_CN_INVALID))
res = ERROR_INTERNET_SEC_CERT_ERRORS;
HTTPREQ_CloseConnection(&lpwhr->hdr);
goto lend;
}
......
......@@ -331,7 +331,9 @@ static int netconn_secure_verify(int preverify_ok, X509_STORE_CTX *ctx)
CertFreeCertificateContext(endCert);
CertCloseStore(store, 0);
}
}
} else
pSSL_set_ex_data(ssl, error_idx, (void *)ERROR_INTERNET_SEC_CERT_ERRORS);
return ret;
}
......
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