Date: Fri, 16 Mar 2001 09:28:44 -0600 (CST) From: Nick Rogness <nick@rogness.net> To: Jeroen Ruigrok/Asmodai <asmodai@wxs.nl> Cc: freebsd-net@FreeBSD.ORG Subject: Re: same interface Route Cache Message-ID: <Pine.BSF.4.21.0103160904310.9691-100000@cody.jharris.com> In-Reply-To: <20010316110803.B12010@daemon.ninth-circle.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, 16 Mar 2001, Jeroen Ruigrok/Asmodai wrote: > -On [20010310 04:00], Nick Rogness (nick@rogness.net) wrote: > > > >Is anyone working on route caching functionality within FreeBSD? This > >would eliminate a lot of problems with using FreeBSD as a router...which > >seems to be a common role of which FreeBSD seems to fit. Especially for > >machine that are dual-homed. > > Correct me if wrong, but if I recall BSD natively already held a route > cache, although it might not be the best route cache which we could come > up with. Well, I'm sure it does have some route cache functionality but not what is considered to be useful. I'll clarify real quick for people who are asking 'why?'. Bare with me. As a packet comes in one interface, there should be a way when the packet comes back out to be sent out that same interface it was received on, regardless of what the default route says. For dual-homed hosts, this is a problem because your packet gets sent out the default gateway, which may or may not get filtered upstream. This is usually solved by running a routing deamon but most upstreams won't allow you to do that anyway (cable,dsl,etc). There is a workaround solution involving natd but it is a pain in the butt. > I'll add this to my todo as well. I've had some ideas on how someone would implement this. The more I think about it the more I think it should be similar to natd. The packet could be diverted like: ipfw divert route-cached ip from any to any in via ed0 or something similar. route-cached could be a userland program, like natd, with options: - setting different gateways for different interfaces - hold down timers ,etc Routes could be added into the routing table accordingly as packets come and go via this daemon. You or someone will have to validate this logic. I may be way off course here...but it was a stab. Maybe it belongs somewhere else. I've been preparing to write such a program, going off the base of natd. Please let me know if this is a good idea or not. Nick Rogness <nick@rogness.net> - Keep on routing in a Free World... "FreeBSD: The Power to Serve!" To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.21.0103160904310.9691-100000>