bug-hurd
[Top][All Lists]
Advanced

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

Re: Networking design proposal


From: Niels Möller
Subject: Re: Networking design proposal
Date: 13 Nov 2002 13:00:43 +0100
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2

Michal 'hramrach' Suchanek <hramrach_l@centrum.cz> writes:

> I think you completely misunderstood my post as your comments seem to be
> shifted by one layer. Or I misunderstood the pictures in prevois post.

Sorry for the confusion. Our termonology is far from perfect.

> As I understansd the picture there is a layer L2 which has interface for
> sending/receiving frames (possibly w/o the frame headers) on one end and
> some ip interface on the other end.

Right, except that I prefer to call that component the "layer 3 code",
because the goal of that code is to offer layer 3 service (i.e. ip
packet transmission) to its users.

> The ip interface allows the L3 translators to register some ip:s.
> I do not see any use for distinction between ip numbers and port
> numbers.

Well, the difference is that the ip addresses are part of layer three,
and therefore the layer 3 code *must* know about them, and do the
right thing. Almost by definition, "layer 3" is the code that knows
about ip addresses.

On the other hand, port numbers are not essential for layer 3, so here
we have a design *choice* of either putting the handling into the
layer 3 code, or to put it elsewhere, in the layer 4 transport code.
And I've argued for the letter alternative, but I should not repat
those arguments again. To me, port numbers relate to the layer 3 code
in the same way that ip-addresses relate to the layer 2 code, which is
that they should both be regarded as the next upper layer's business.

> They were probably designed to have one ip on each interface(machine?).
> Multiple ports used to address different applications/services. But that
> is no longer true and you may want multiple ip:s on one interface or single
> port with any ip etc. That makes the distinction between ip numbers and 
> port numbers useless imho.

If for a moment we back to the "virtual interface" model, where each
interface has a single ip address, then it's simple: The ip address
tells the (distributed) layer 3 implementation which interface you
want to talk to, and the port number tells the layer 4 implementation,
which uses that interface, which application you want to talk to.

Now that's probably not how layer 3 will handle the relation between
interfaces and ip addresses, but it's still the way layer 4 usually
deals with them. For instance, it's simple to bind a port on a single
ip address, and it's simple to bind a port on all available
ip-addresses, but it's a lot harder to bind a port on all ip-addresses
associated with a particular interface. The basic socket API won't let
you deal with real interfaces at all, IIRC.

/Niels




reply via email to

[Prev in Thread] Current Thread [Next in Thread]