curl / Mailing Lists / curl-users / Single Mail
Buy commercial curl support from WolfSSL. We help you work out your issues, debug your libcurl applications, use the API, port to new platforms, add new features and more. With a team lead by the curl founder himself.

Confused about --doh/--resolve

From: Gisle Vanem via curl-users <curl-users_at_cool.haxx.se>
Date: Tue, 11 Aug 2020 13:01:59 +0200

I'm confused about what a command like this does:
   curl --ipv4 --resolve cloudflare-dns.com:443:104.16.248.249 \
     --doh-url https://cloudflare-dns.com/dns-query \
     https://clienttest.ssllabs.com:8443/ssltest/viewMyClient.html

First, I note curl connects to 'cloudflare-dns.com' using IPv6
even though I specified '--ipv4' and added 'cloudflare-dns.com's
IPv4 address to this "fake" DNS-cache.

Adding a '-v', I see this confusing trace:
   * family0 == v6, family1 == v4
   * Trying 2606:4700::6810:f8f9:443...

'curl -M' says this:
   -4, --ipv4
       This option tells curl to resolve names to IPv4 addresses only,
       and not for example try IPv6.

I would expect that to be valid for a '--doh-url' too.

Now, it's like curl won't use this DNS-cache at all.
I don't get it.

-- 
--gv
-----------------------------------------------------------
Unsubscribe: https://cool.haxx.se/list/listinfo/curl-users
Etiquette:   https://curl.haxx.se/mail/etiquette.html
Received on 2020-08-11