From owner-freebsd-questions@FreeBSD.ORG Tue Aug 7 22:37:51 2007 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F18CF16A419 for ; Tue, 7 Aug 2007 22:37:51 +0000 (UTC) (envelope-from cswiger@mac.com) Received: from mail-out4.apple.com (mail-out4.apple.com [17.254.13.23]) by mx1.freebsd.org (Postfix) with ESMTP id E3C7913C442 for ; Tue, 7 Aug 2007 22:37:51 +0000 (UTC) (envelope-from cswiger@mac.com) Received: from relay8.apple.com (relay8.apple.com [17.128.113.38]) by mail-out4.apple.com (Postfix) with ESMTP id 96163E293BC; Tue, 7 Aug 2007 15:37:51 -0700 (PDT) Received: from relay8.apple.com (unknown [127.0.0.1]) by relay8.apple.com (Symantec Mail Security) with ESMTP id 6CA9E40053; Tue, 7 Aug 2007 15:37:51 -0700 (PDT) X-AuditID: 11807126-a7c49bb0000007e3-00-46b8f43fbf13 Received: from [17.214.13.96] (cswiger1.apple.com [17.214.13.96]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by relay8.apple.com (Apple SCV relay) with ESMTP id 5E291400B1; Tue, 7 Aug 2007 15:37:51 -0700 (PDT) In-Reply-To: <46B8EE80.7000905@crackmonkey.us> References: <64c038660708071210w1950ccccwda1bb8464587d1de@mail.gmail.com> <46B8EE80.7000905@crackmonkey.us> Mime-Version: 1.0 (Apple Message framework v752.2) Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: <86731548-011A-4BFF-8D52-25819C00735B@mac.com> Content-Transfer-Encoding: 7bit From: Chuck Swiger Date: Tue, 7 Aug 2007 15:37:50 -0700 To: Adam J Richardson X-Mailer: Apple Mail (2.752.2) X-Brightmail-Tracker: AAAAAA== Cc: freebsd-questions@freebsd.org, Modulok Subject: Re: Bizzare routing table entry. X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 07 Aug 2007 22:37:52 -0000 On Aug 7, 2007, at 3:13 PM, Adam J Richardson wrote: > Modulok wrote: >> 0&0xc0a80132 link#1 UCS 0 0 bge0 > >> 1. The first entry, it's not IPv4, IPv6 or a MAC address that I've >> ever seen, what format is it? > > Hi Modulok, > > It's possible to represent IPv4 addresses as a single number. I > don't recall the algorithm for converting that four byte dot- > delimited group into an integer, though, so I can't tell you what > number it is. Perhaps you can Google the algorithm and do the math > to figure out what it is. aaa.bbb.ccc.ddd => 0xAABBCCDD, where AA = hex(aaa), BB = hex(bbb), etc. In particular, 0xc0a80132 is the hex equivalent of 192.168.1.50. An IP address + netmask can normally be represented in the routing table via the slash notation-- say 192.168.1.50/24 meaning a 255.255.255.0 (or 0xffffff00) netmask. Non-contiguous netmasks are represented by "address & netmask", but since no normal network ever uses such a netmask, they almost always represent a misconfiguration-- someone confused the arguments such that the route command interpreted the gateway IP as a netmask instead. -- -Chuck