No, why should it? You have specified DNS only for the HTTPSClient which you use to send a request.

In your code snippet ValidateForSSL probably sends a CRL or OCSP request during validation, and this goes with default DNS of course. You can handle TElX509CertificateValidator's events, namely OnBefore*Use, and tune-up HTTP client used in CRL retriever and OCSP responder. Or you can create your own CRL retriever and OCSP responder - the sample for doing this is present in SecureBlackbox 9.1.213 in \Samples\Delphi\PKI\CertValidator sample (I've copied our classes' source code there and simplified it a bit).

Ok, thank you. I will do that. And last question. Does HTTPSClient DNS support caching? Like if I read data from www.google.com. Three times in 10 seconds. Then it won't ask DNS server three times (and it will save some time)?

Not at the moment. You can add an idea to the wishlist to see how popular it is, but since it's first time the question about using custom DNS servers is asked, I believe this is not a widespread feature. But who knows ...

We use cookies to help provide you with the best possible online experience. By using this site, you agree that we may store and access cookies on your device. You can find out more about and set your own preferences here.