From owner-freebsd-net@FreeBSD.ORG Wed Feb 13 04:21:58 2008 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8D28C16A417 for ; Wed, 13 Feb 2008 04:21:58 +0000 (UTC) (envelope-from ume@mahoroba.org) Received: from ameno.mahoroba.org (ent.mahoroba.org [IPv6:2001:2f0:104:8010::1]) by mx1.freebsd.org (Postfix) with ESMTP id 4E89513C459 for ; Wed, 13 Feb 2008 04:21:58 +0000 (UTC) (envelope-from ume@mahoroba.org) Received: from localhost (IDENT:FNC6kGDJKmAJ+BI2rTUy8qgObiQZia3+ysgkqmiG/BM460mdyi6cSUzeHFXccrV5@localhost [IPv6:::1]) (user=ume mech=CRAM-MD5 bits=0) by ameno.mahoroba.org (8.13.8/8.13.8) with ESMTP/inet6 id m1D4Ldqp063890 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 13 Feb 2008 13:21:43 +0900 (JST) (envelope-from ume@mahoroba.org) Date: Wed, 13 Feb 2008 13:21:38 +0900 Message-ID: From: Hajimu UMEMOTO To: d@delphij.net In-Reply-To: <47B2488D.70707@delphij.net> References: <47B2488D.70707@delphij.net> User-Agent: xcite1.57> Wanderlust/2.14.0 (Africa) SEMI/1.14.6 (Maruoka) FLIM/1.14.8 (=?ISO-8859-4?Q?Shij=F2?=) APEL/10.7 Emacs/22.1 (i386-pc-freebsd) MULE/5.0 (SAKAKI) X-Operating-System: FreeBSD 6.2-RELEASE-p10 X-PGP-Key: http://www.imasy.or.jp/~ume/publickey.asc X-PGP-Fingerprint: 1F00 0B9E 2164 70FC 6DC5 BF5F 04E9 F086 BF90 71FE Organization: Internet Mutual Aid Society, YOKOHAMA MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII X-Greylist: Sender succeeded SMTP AUTH authentication, not delayed by milter-greylist-3.0 (ameno.mahoroba.org [IPv6:::1]); Wed, 13 Feb 2008 13:21:43 +0900 (JST) X-Virus-Scanned: by amavisd-new X-Virus-Status: Clean X-Spam-Status: No, score=-0.4 required=5.0 tests=AWL,BAYES_00,HELO_LOCALHOST autolearn=no version=3.2.4 X-Spam-Checker-Version: SpamAssassin 3.2.4 (2008-01-01) on ameno.mahoroba.org Cc: freebsd-net@freebsd.org Subject: Re: Strange resolver behavior X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Feb 2008 04:21:58 -0000 Hi, >>>>> On Tue, 12 Feb 2008 17:31:57 -0800 >>>>> Xin LI said: delphij> [delphij@charlie] ~> host ps_other.a.shifen.com delphij> ps_other.a.shifen.com has address 202.108.22.46 delphij> Host ps_other.a.shifen.com not found: 3(NXDOMAIN) `_' is not allowed in hostname. Our resolver (BIND's resolver) rejects it. If you don't want this behavior, you can try the following patch, but I don't recommend: Index: lib/libc/resolv/res_comp.c diff -u -p lib/libc/resolv/res_comp.c.orig lib/libc/resolv/res_comp.c --- lib/libc/resolv/res_comp.c.orig 2006-07-17 19:09:58.000000000 +0900 +++ lib/libc/resolv/res_comp.c 2008-02-13 13:14:35.000000000 +0900 @@ -151,7 +151,7 @@ dn_skipname(const u_char *ptr, const u_c #define digitchar(c) ((c) >= 0x30 && (c) <= 0x39) #define borderchar(c) (alphachar(c) || digitchar(c)) -#define middlechar(c) (borderchar(c) || hyphenchar(c)) +#define middlechar(c) (borderchar(c) || hyphenchar(c) || ((c) == 0x5f)) #define domainchar(c) ((c) > 0x20 && (c) < 0x7f) int Sincerely, -- Hajimu UMEMOTO @ Internet Mutual Aid Society Yokohama, Japan ume@mahoroba.org ume@{,jp.}FreeBSD.org http://www.imasy.org/~ume/