Subject: Re: netmasks and IP
To: Chuck McManis <cmcmanis@freegate.com>
From: Johnny Billquist <bqt@Update.UU.SE>
List: port-vax
Date: 03/18/1999 11:21:03
On Wed, 17 Mar 1999, Chuck McManis wrote:

Hi, Chuck. Pretty good description, but I'd like to add some comments...

> There are two "special" hosts, these are called the broadcast addresses and
> they were originally implemented, IIRC, as :
> 	host number 0 (old broadcast address)
> 	host number -1 (all ones, new broadcast address)
> There was some dispute about this in the early 80's and at Sun we did both
> some networks expected the host number to be all ones, others expected it
> to be all 0. Now most everyone accepts both. (But the RFC states that all
> ones is correct)

Actually, the all zero for broadcast was introduced by BSD4.2, and was
wrong even then. So that was a very unfortunate thing. It's probably
erronous to call it the old broadcast address. Only BSD4.2 and derived
systems used it, and the RFC have always said it was wrong.

> What it means is this, in the absence of any other data, the default
> netmask for an address 10.x.y.z is 0xff000000 (because it is a class A
> address). The default broadcast address is then 10.255.255.255. _However_
> if you set the netmask artificially (using ifconfig's netmask option for
> example) to be a "class C" netmask (ie 255.255.255.0) then the broadcast
> address on your class C network is 10.x.y.255.
> 
> Now the machine the is running bootparamd has gets a packet addressed to
> 10.255.255.255 and it is running with address 10.x.y.z and a netmask of
> 255.255.255.0. The server machine creates the broadcast address 10.x.y.255
> based on the netmask, compares 10.255.255.255 to that and to 10.x.y.z,
> since neither match it 
> NEVER SENDS THE PACKET UP THE STACK. And bootparamd sits there mute.

Which is wrong. The server should match against three addresses.

1) 10.255.255.255
2) 10.x.y.255
3) 10.x.y.z

Since all three are valid. Netmasks don't really make the standard
addresses illegal.

	Johnny

Johnny Billquist                  || "I'm on a bus
                                  ||  on a psychedelic trip
email: bqt@update.uu.se           ||  Reading murder books
pdp is alive!                     ||  tryin' to stay hip" - B. Idol