From owner-freebsd-isp Sun Jun 17 19:48:21 2001 Delivered-To: freebsd-isp@freebsd.org Received: from thehousleys.net (frenchknot.ne.mediaone.net [24.147.224.201]) by hub.freebsd.org (Postfix) with ESMTP id 99ABC37B401 for ; Sun, 17 Jun 2001 19:48:13 -0700 (PDT) (envelope-from jim@thehousleys.net) Received: (from root@localhost) by thehousleys.net (8.11.3/8.11.2) id f5I2m2w39312; Sun, 17 Jun 2001 22:48:02 -0400 (EDT) (envelope-from jim@thehousleys.net) Received: from thehousleys.net (baby.int.thehousleys.net [192.168.0.24]) (authenticated) by thehousleys.net (8.11.3/8.11.3) with ESMTP id f5I2lvr39301; Sun, 17 Jun 2001 22:47:57 -0400 (EDT) (envelope-from jim@thehousleys.net) Message-ID: <3B2D6BDD.A02291A@thehousleys.net> Date: Sun, 17 Jun 2001 22:47:57 -0400 From: James Housley X-Mailer: Mozilla 4.77 [en] (X11; U; Linux 2.2.12 i386) X-Accept-Language: en MIME-Version: 1.0 To: john@day-light.com Cc: freebsd-isp@freebsd.org Subject: Re: IP resolving to Octal References: <000501c0f79d$ff696fc0$0b00a8c0@dle> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Virus-Scanned: by AMaViS perl-10 Sender: owner-freebsd-isp@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org John Brooks wrote: > > I assisted a friend to setup a new FreeBSD4.3 box (the first in his > network). Network has 50+ linux boxes resolving from hosts files in this > format (don't ask me why, it's his format): > > 010.000.010.012 charity.cs.domain.edu > 010.000.010.013 patience.cs.domain.edu > 010.000.010.014 virtue.cs.domain.edu > ... > > On linux this apparently worked, on BSD it gets converted to octal and > returned in dotted decimal. "charity" resolved to an IP of 8.0.8.10 instead > of 10.0.10.12. Anyway, we worked through all issues first and then set up > DNS which is working properly - he now thinks BSD is "way cool". > > My question is why would BSD and Linux interpret the same hosts file in such > a different manner? Which should be considered the correct behavior? > For the 20+ years I have been programming, it has been standard to represent octal number with a leading zero. Seeing the FreeBSD's roots go back further then my 20 years. And if you check RFC-1035 section 3.5, it states ". . . one octet of an Internet address, and is expressed as a character string for a decimal value in the range 0-255 (with leading zeros omitted except in the case of a zero octet which is represented by a single zero)." This actually relates to IN-ADDR.ARPA domain. I stopped searching after finding this one. I am also sure there is an RFC for hosts files which are more pertinent. Jim -- /"\ ASCII Ribbon Campaign . \ / - NO HTML/RTF in e-mail . X - NO Word docs in e-mail . / \ ----------------------------------------------------------------- jeh@FreeBSD.org http://www.FreeBSD.org The Power to Serve jim@TheHousleys.Net http://www.TheHousleys.net --------------------------------------------------------------------- A Microsoft Certified Systems Engineer is to computing what a McDonalds Certified Food Specialist is to fine cuisine. -- Jack O'Neill To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-isp" in the body of the message