[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: To the bind maintainer



On Tue, Jan 25, 2000 at 08:27:22PM +0100, Marek Habersack wrote:
> * Michael Stone said:
> > On Tue, Jan 25, 2000 at 06:03:10PM +0100, Marek Habersack wrote:
> > > > Every time I'm reminded of bind attaching itself to each interface
> > > > explicitly, I wonder why it does that (and doesn't simply bind to
> > > > 0.0.0.0). _Is_ there a valid reason?
> > > A router serving DNS for two LANs, for example.
> > 
> > That's not an answer.
> OK, I'll elaborate on that. One copy of bind is configured to server
> requests (by default) on every interface attached to the machine. That can
> be useful in many cases. For example if you have a machine that routes
> packets between two networks (say, it's a firewall like that one described
> by the famous AT&T paper). There's no need to setup two separate DNS
> servers, instead you can have one copy listening on all interfaces. Another
> example is bind ran on a machine with dynamic interfaces (dial-up, PCMCIA,
> tunnels etc.) and it is desirable that all interfaces have bind attached -
> for example the machine is a gateway for the local LAN, but connects to the
> net using PPP. Then the bind is used to forward the local requests over the
> PPP link to the forwarder on the other side - it must attach to the newly
> created interface for that to work. The default setup guarantees that all
> these scenarios will work. It's a trivial task to change the default.

Swing and a miss...

He understands why it should respond to all interfaces. His question
is, why do that by binding the interfaces explicitly, and requiring
other magic to detect new interfaces and such, when you can do it much
easier simply by binding to 0.0.0.0, which will work on every interface.

I think the reason it wouldn't work like that is because there's no way
to tell what interface you received a packet through via UDP unless the
listener is only binding a single interface (in which case you know 
it's the interface you bound :), and BIND needs to respond from the 
same address it got the packet on.

-- 
Elie Rosenblum                 That is not dead which can eternal lie,
http://www.cosanostra.net   And with strange aeons even death may die.
Admin / Mercenary / System Programmer             - _The Necronomicon_

Attachment: pgpuUqZ7aEW6F.pgp
Description: PGP signature


Reply to: