Subject: Re: Multiple defaultroutes
To: Jared D. McNeill <jmcneill@invisible.yi.org>
From: None <itojun@iijlab.net>
List: current-users
Date: 02/09/2001 10:27:57
	maybe I don't have enough context, sorry if i'm confused with some
	other issue.

>> Thats a whole new can o' worms you're opening up.  "Default Route" means
>> "send it here if I don't know where else to send it".  You have to somehow
>> teach the kernel which destinations to route over what interface.  That's
>> usually done by static routes and/or learned routes through the routed &
>> gated daemons.
>
>Basically what I want to do is to be able to accept incoming connections
>on the PPP over TCP assigned IP address without having to add static
>routes to every host that wants to connect. Anyway I can do this without
>diving into routed?

	BSD networking stack uses weak host model.  consider the
	following configuration:

	  |
	  | interface A, address A1 and A2
	machine
	  | interface B, address B1 and B2
	  |

	under weak host model, when a packet comes in from interface A,
	with destination address B1 and B2, the packet gets accepted
	correctly.  so if you are talking about inbound traffic, it is
	already okay.

	for outgoing traffic, it is just matter of routing configuration.
	even if the source address is B1 or B2 (because you specified it
	with bind(2), or you are TCP listener side nad have no choice)
	if routing table suggests to go out from interface A, outgoing
	traffic goes out from interface A.

itojun