Subject: Re: ifconfig and aliases
To: Christian E. Hopps <chopps@merit.edu>
From: Bill Sommerfeld <sommerfeld@orchard.arlington.ma.us>
List: tech-net
Date: 07/26/1999 14:19:13
> So we have no idea what IP gets written into a packet sent out a
> specific interface with more then 1 IP anymore?

It's not that bad...  Each route contains a pointer to an "ifaddr"
struct (there's one per alias; each one is essentially a
"sub-interface" if you believe in sub-interfaces).

Unless a socket is bound to a specific address, the kernel does a
lookup of the destination in the routing table and then uses the
address in the ifaddr attached to the route being used as the source
address.

Currently, there's no way to independantly set the ifaddr on a route
which is being created; I've got some changes in the pipeline to let
these be set independantly but I started work on them shortly before
v6 got merged and needless to say there were some conflicts.

					- Bill