From owner-freebsd-current Sat Jan 4 14: 8:42 2003 Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DF78E37B401; Sat, 4 Jan 2003 14:08:39 -0800 (PST) Received: from cheer.mahoroba.org (flets19-106.kamome.or.jp [218.45.19.106]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7E81243E4A; Sat, 4 Jan 2003 14:08:32 -0800 (PST) (envelope-from ume@mahoroba.org) Received: from mille.mahoroba.org (IDENT:LXK+gj+RTCTP9uaFvBh7JB1Q4EAVpEy0eEAtMJJprmplgIV+WRG4WXfSPkcrfFTX@mille.mahoroba.org [IPv6:2001:200:301:0:202:2dff:fe0a:6bee]) (user=ume mech=CRAM-MD5 bits=0) by cheer.mahoroba.org (8.12.6/8.12.6) with ESMTP/inet6 id h04M8CAN024600 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=NO); Sun, 5 Jan 2003 07:08:15 +0900 (JST) (envelope-from ume@mahoroba.org) Date: Sun, 05 Jan 2003 07:08:11 +0900 Message-ID: From: Hajimu UMEMOTO To: Terry Lambert Cc: Gregory Neil Shapiro , "Gary W. Swearingen" , freebsd-current@FreeBSD.ORG Subject: Re: [resolution] Re: sendmail (Re: 5.0-RC2 informal PR: 90 sec sendmail delay) In-Reply-To: <3E174861.97A1584C@mindspring.com> References: <3E1352BC.4043921B@mindspring.com> <20030101145232.A391@zardoc.esmtp.org> <3E13D095.FC52B758@mindspring.com> <3E163C0A.C0CF8146@mindspring.com> <8p4r8pwgl6.r8p@localhost.localdomain> <15895.766.628111.450121@horsey.gshapiro.net> <3E174861.97A1584C@mindspring.com> User-Agent: xcite1.38> Wanderlust/2.11.0 (Wonderwall) SEMI/1.14.4 (Hosorogi) FLIM/1.14.4 (=?ISO-8859-4?Q?Kashiharajing=FE-mae?=) APEL/10.4 Emacs/21.2 (i386--freebsd) MULE/5.0 (=?ISO-2022-JP?B?GyRCOC1MWhsoQg==?=) X-Operating-System: FreeBSD 4.7-STABLE MIME-Version: 1.0 (generated by SEMI 1.14.4 - "Hosorogi") Content-Type: text/plain; charset=US-ASCII X-Virus-Scanned: by AMaViS-perl11-milter (http://amavis.org/) X-Spam-Status: No, hits=-1.0 required=5.0 tests=IN_REP_TO,REFERENCES,SPAM_PHRASE_00_01,USER_AGENT version=2.43 Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi, >>>>> On Sat, 04 Jan 2003 12:47:29 -0800 >>>>> Terry Lambert said: tlambert2> The FreeBSD library bug is that the /etc/hosts file entry: tlambert2> ::1 tlambert2> is not canonized before being compared, for the reverse lookup. No, it does. I've tested it with following program: #include #include #include #include #include main() { struct sockaddr_in6 sin6; struct hostent *ht; int error; char hbuf[NI_MAXHOST]; ht = gethostbyaddr((char *)&in6addr_loopback, sizeof(struct in6_addr), AF_INET6); if (!ht) errx(1, "gethostbyaddr: lookup faild"); printf("gethostbyaddr: %s\n", ht->h_name); ht = getipnodebyaddr((char *)&in6addr_loopback, sizeof(struct in6_addr), AF_INET6, &error); if (!ht) errx(1, "getipnodebyaddr: lookup faild %d", error); printf("getipnodebyaddr: %s\n", ht->h_name); memset(&sin6, 0, sizeof(sin6)); memcpy(&sin6.sin6_addr, &in6addr_loopback, sizeof(struct in6_addr)); sin6.sin6_family = AF_INET6; sin6.sin6_len = sizeof(sin6); if (getnameinfo((struct sockaddr *)&sin6, sizeof(sin6), hbuf, sizeof(hbuf), NULL, 0, 0) != 0) errx(1, "getnameinfo: lookup faild"); printf("getnameinfo: %s\n", hbuf); } Then, it returned as expected: ume@mille:1082% ./revtest gethostbyaddr: localhost getipnodebyaddr: localhost getnameinfo: localhost where my /etc/host.conf is: hosts #bind and my /etc/hosts contains: ::1 localhost localhost.mahoroba.org 127.0.0.1 localhost localhost.mahoroba.org When I commented the ::1 line out in /etc/hosts, the test program returned: me@mille:1087% ./revtest revtest: gethostbyaddr: lookup faild So, I cannot understand what you say. tlambert2> It can probably be worked around by spcifying: tlambert2> 0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.1 tlambert2> as the left hand side for the IPv6 loopback address, instead of ::1, tlambert2> in the /etc/hosts file. I don't recommend this, since it would not tlambert2> encourage the author of the IPv6 resovler code to fix the bug they tlambert2> introduced. You don't need to do it at all. Sincerely, -- Hajimu UMEMOTO @ Internet Mutual Aid Society Yokohama, Japan ume@mahoroba.org ume@bisd.hitachi.co.jp ume@{,jp.}FreeBSD.org http://www.imasy.org/~ume/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message