From owner-freebsd-net Sun Feb 24 10:36:20 2002 Delivered-To: freebsd-net@freebsd.org Received: from rwcrmhc51.attbi.com (rwcrmhc51.attbi.com [204.127.198.38]) by hub.freebsd.org (Postfix) with ESMTP id 411B137B402; Sun, 24 Feb 2002 10:36:17 -0800 (PST) Received: from blossom.cjclark.org ([12.234.91.48]) by rwcrmhc51.attbi.com (InterMail vM.4.01.03.27 201-229-121-127-20010626) with ESMTP id <20020224183616.RXKE2626.rwcrmhc51.attbi.com@blossom.cjclark.org>; Sun, 24 Feb 2002 18:36:16 +0000 Received: (from cjc@localhost) by blossom.cjclark.org (8.11.6/8.11.6) id g1OIaG433766; Sun, 24 Feb 2002 10:36:16 -0800 (PST) (envelope-from cjc) Date: Sun, 24 Feb 2002 10:36:16 -0800 From: "Crist J. Clark" To: Ruslan Ermilov Cc: net@FreeBSD.ORG Subject: Re: TCP Connections to a Broadcast Address Message-ID: <20020224103616.S16048@blossom.cjclark.org> Reply-To: cjclark@alum.mit.edu References: <20020222022626.A83807@blossom.cjclark.org> <20020223115033.GB47437@sunbay.com> <20020223042828.E16048@blossom.cjclark.org> <20020223124535.GB52291@sunbay.com> <20020223072520.J16048@blossom.cjclark.org> <20020224084702.GB31243@sunbay.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20020224084702.GB31243@sunbay.com>; from ru@FreeBSD.ORG on Sun, Feb 24, 2002 at 10:47:02AM +0200 X-URL: http://people.freebsd.org/~cjc/ Sender: owner-freebsd-net@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org On Sun, Feb 24, 2002 at 10:47:02AM +0200, Ruslan Ermilov wrote: > On Sat, Feb 23, 2002 at 07:25:20AM -0800, Crist J. Clark wrote: [snip] > > If you are correct, and you can cross interfaces, this is a much > > bigger problem. I didn't mention it in your first mail, but the > > in_broadcast() function as used in the patch you sent is different > > than the current implementation. in_broadacast() currently takes an > > address and an interface. If you are correct, we'd have to loop > > through the interface list... which makes this uglier. > > > No, I can't cross interfaces, /* Check for broadcast addresses. */ > in ip_input() doesn't allow this. Exactly, I found that code early on. I had considered possibly dropping all TCP right then and there, but decided that was not the right place to do it. > I'm talking about a different > scenario here, multiple IP networks per interface: > > host# netstat -rn -finet | grep -w default > default 192.168.4.65 UGSc 4 387 rl0 > > gateway# ifconfig fxp0 inet > fxp0: flags=8843 mtu 1500 > inet 192.168.4.65 netmask 0xffffff00 broadcast 192.168.4.255 > inet 192.168.100.1 netmask 0xffffff00 broadcast 192.168.100.255 Right. But to me, that seems at best suboptimal and at worst slightly misconfigured. A host shouldn't be routing traffic over one interface. This is the kind of route that will generate ICMP redirects. But none of this really has anything to do with the problem. I am going to test the final revision I made after reviewing the patches you presented earlier in this thread and then make the commit. -- Crist J. Clark | cjclark@alum.mit.edu | cjclark@jhu.edu http://people.freebsd.org/~cjc/ | cjc@freebsd.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message