On 5 May, 2012, at 17:55 , Darren Reed wrote:
Dennis Ferguson wrote:
I'm aware of both of those. I think you may be confused about
what IP_BOUND_IF does (hint: last I looked it only effects
where multicasts and broadcasts go). IP_NEXTHOP does help if
you think this is solved by having each application do its
own routing (maybe the application could run DHCP to find out
the next hop for that interface's default route too); if all
applications did this then the kernel could get even simpler
by eliminating all forwarding tables.
You want an application to send a packet back out the same
interface that the packet was received on. That amounts to
the application doing its own routing.
See RFC 1122, section 3.3.4.2, the Strong ES model. The routing
operation is well-defined, the application doesn't have to be
aware it is happening, but it needs a routing table per interface
to implement it.