IPv6/IPv4 DNS resolver source

JINMEI Tatuya / 神明達哉 Jinmei_Tatuya at isc.org
Tue May 27 18:53:27 UTC 2008


At Mon, 26 May 2008 18:49:35 -0400,
Steve Bertrand <iaccounts at ibctech.ca> wrote:

> Is there anyone here who can advise me where in the source tree I would 
> find the DNS resolver code that performs AAAA/A record lookups, and more 
> specifically, the fallback to A lookup if AAAA fails?

Assuming you're considering getaddrinfo(), see res_queryN() in
lib/libc/net/getaddrinfo.c.

BTW: "fallback" does not really accurately describe the behavior.
When AF_UNPSEC is specified, both AAAA and A queries are issued,
whether or not the AAAA query fails.

---
JINMEI, Tatuya
Internet Systems Consortium, Inc.


More information about the freebsd-net mailing list