🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.nntp
Article #78645

Re: Regarding INN - name to address resolution for peers

#78645
From: Russ Allbery
Date: Tue, 05 Feb 2008 07:34
34 lines
2974 bytes
"D. Stussy" <spam@bde-arc.ampr.org> writes:
> "Russ Allbery" <rra@stanford.edu> wrote:

>> That sounds like a horribly broken getaddrinfo.  getaddrinfo
>> specifically looks up the address of a host.  It shouldn't be returning
>> random other DNS RRs, whether they be APL, MX, AFSDB, TXT, or anything
>> else.

> I'm not saying that it would return an APL or other RRs - just that
> there are other address families besides IPv4 and IPv6 and that it's
> possible that there COULD be a return of something not IP and that the
> code (as of January 1) ignores that multiple AFs can be returned.

I'm not sure what you think the code should do.  The intent of the
getaddrinfo interface is that, by using it, code can be AF-neutral and not
have to be constantly updated whenever new AFs show up (such as some
hypothetical IPv7), and more relevantly not have to care whether it gets
back IPv4 or IPv6.  I don't want to hard-code any address family
expectations; that's exactly counter to the whole point of the new
interfaces.

CURRENT provides more information via hints, such as telling getaddrinfo
that the address will be used for SOCK_STREAM.  I would be very surprised
if that's not sufficient.  CURRENT also correctly tries each address in
turn rather than giving up if the first one doesn't work.  The IPv6
support in 2.4 was sort of bolted on the side.  CURRENT uses the new
interfaces unconditionally and more cleanly and provides a compatibility
layer for systems that don't have them.

-- 
Russ Allbery (rra@stanford.edu)             <http://www.eyrie.org/~eagle/>

          Please post questions rather than mailing me directly.
     <http://www.eyrie.org/~eagle/faqs/questions.html> explains why.
Technical Details
Message-ID: <87prvbyhy9.fsf@windlord.stanford.edu>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.20141118.mbox.gz!number1.nntp.dca.giganews.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newshub.sdsu.edu!headwall.stanford.edu!newsfeed.stanford.edu!shelby.stanford.edu!not-for-mail
References: <fnqsnb$e8h$1@snarked.org> <fo82tr$14d$1@bongo.bofh.it> <fo8pcb$nkd$1@snarked.org> <87ejbs0ytv.fsf@windlord.stanford.edu> <fo8uhn$o2q$1@snarked.org> <87odavzzlq.fsf@windlord.stanford.edu> <fo93cm$oik$1@snarked.org>

Show Full Headers
Complete Article Headers
Message-ID: <87prvbyhy9.fsf@windlord.stanford.edu>
Subject: Re: Regarding INN - name to address resolution for peers
Date: Mon, 04 Feb 2008 23:34:54 -0800
From: Russ Allbery <rra@stanford.edu>
References: <fnqsnb$e8h$1@snarked.org> <fo82tr$14d$1@bongo.bofh.it> <fo8pcb$nkd$1@snarked.org> <87ejbs0ytv.fsf@windlord.stanford.edu> <fo8uhn$o2q$1@snarked.org> <87odavzzlq.fsf@windlord.stanford.edu> <fo93cm$oik$1@snarked.org>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.20141118.mbox.gz!number1.nntp.dca.giganews.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newshub.sdsu.edu!headwall.stanford.edu!newsfeed.stanford.edu!shelby.stanford.edu!not-for-mail
Newsgroups: news.software.nntp
Organization: The Eyrie
Lines: 34
NNTP-Posting-Host: windlord.stanford.edu
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
X-Trace: news.Stanford.EDU 1202196894 17954 171.64.19.147 (5 Feb 2008 07:34:55
 GMT)
X-Complaints-To: news@news.stanford.edu
User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.1 (gnu/linux)
Cancel-Lock: sha1:zJ9z1IPgYAi32POS9KgZXeBLgbQ=