*BSD News Article 90956


Return to BSD News archive

Path: euryale.cc.adfa.oz.au!newshost.carno.net.au!harbinger.cc.monash.edu.au!munnari.OZ.AU!news.Hawaii.Edu!ames!purdue!ector.cs.purdue.edu!dhir
From: Anshul Dhir <dhir@cs.purdue.edu>
Newsgroups: comp.unix.bsd.netbsd.misc
Subject: Question on ipintr function
Date: Thu, 13 Mar 1997 15:38:47 -0500
Organization: Department of Computer Sciences, Purdue University
Lines: 22
Message-ID: <Pine.SOL.3.95.970313152838.28603A-100000@ector.cs.purdue.edu>
NNTP-Posting-Host: ector.cs.purdue.edu
Mime-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
Xref: euryale.cc.adfa.oz.au comp.unix.bsd.netbsd.misc:5617


Hi,

I was looking at the source code of ipintr() ( BSD4.4.lite  ipinput.c ),
which gets the packets from the link level queues and processes them if 
they are for the itself else forwards them if it is configured to be a
router.

I am not able to understand how the router will deal with a packet that it
is supposed to broadcast on one of its local h/w networks, because acc. to
the code, as soon as it finds out that the packet is for itself ( by
comparing the packet's ip destination address to its interface addresses
, then the network addresses and finally with the 255.255.255.255 ) it
sends that packet to the upper layers and goes on to get the next packet.

Thus it never broadcasts the packet on the destination network.

Please let me know, where the broadcasts are taken care of.

thanks,
ad