From owner-freebsd-net@FreeBSD.ORG Sat Dec 11 23:14:35 2004 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BBFD716A4CE for ; Sat, 11 Dec 2004 23:14:35 +0000 (GMT) Received: from acampi.inet.it (acampi.inet.it [213.92.1.165]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7B9B243D49 for ; Sat, 11 Dec 2004 23:14:35 +0000 (GMT) (envelope-from andrea@acampi.inet.it) Received: by acampi.inet.it (Postfix, from userid 1000) id 8D9A5A6; Sun, 12 Dec 2004 00:14:34 +0100 (CET) Date: Sun, 12 Dec 2004 00:14:34 +0100 From: Andrea Campi To: Chuck Swiger Message-ID: <20041211231434.GA17233@webcom.it> References: <20041211090235.GD11190@webcom.it> <41BAC0BD.7000706@mac.com> <20041211102825.GB12803@webcom.it> <41BB40B7.5000907@mac.com> <20041211202138.GC12803@webcom.it> <41BB5F01.2050108@mac.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <41BB5F01.2050108@mac.com> User-Agent: Mutt/1.5.6i cc: net@freebsd.org Subject: Re: Working on howl port X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 11 Dec 2004 23:14:35 -0000 On Sat, Dec 11, 2004 at 03:56:33PM -0500, Chuck Swiger wrote: > >Just to check my assumptions: is it reasonable to assume autoipd > >has total control over the 169.254 block? I don't want to have to > >bother about preserving any existing address in that range etc. > > No, it is not reasonable. Although if you make that assumption for the > first implementation, it's probably mostly harmless again. However, Ah no, I meant on the local machine. What I mean is that by running zeroconf the user is giving total control of that block, and in particular is going to avoid explicitely configuring an interface with such an address. I figure that's quite reasonable. > Anyway, perhaps my responses would be more helpful if you explained the use > case you are trying to get going, first? Unless I'm mistaken, using SIOCAIFADDR instead of SIOCSIFADDR means that I do need to bother about other addresses in the same network on the same or on another interface. My plan is to replace any such address as needed, as long as I can trust they are not of any special meaning to the user. Additionally, if I can expect the user not to set a 169.254 address, I can assume RTM_ADD/RTM_NEWADDR messages for such an address come from dhclient failing to get a lease. Think of this scenario: - unconnected laptop on a bus, I get an addess by zeroconf; - I arrive at the office and the DHCP server gives out an address, zeroconf goes to sleep; - the DHCP server dies and come renew time dhclient notices and sets a 169.254 address. I'd like to be able to notice this case and decide it's really dhclient trying to tell me something, and not have to worry about a user trying to set a random IP address. Anyway, thinking again, this is probably less important than I first thought. I'm mostly thinking out aloud here. It just occurred to me that the second part can probably be better dealt with by having an useful set of scripts for dhclient. I think I should now get some more steps and expecially tests done, and come back when I have a clearer idea of how they interact. I'll still post some interim steps for feedback on the implementation. Bye, Andrea -- Give a man a fish and you feed him for a day; teach him to use the Net and he won't bother you for weeks.