ietf
[Top] [All Lists]

Re: Purpose of Port 0.

2017-02-20 13:35:13
On 21/02/2017 01:33, John C Klensin wrote:


--On Monday, February 20, 2017 10:07 PM +1100 Mark Andrews
<marka(_at_)isc(_dot_)org> wrote:


In message
<SG2PR06MB071061291C3DC252AA62FCB2C15E0@SG2PR06MB0710.apcprd06
.prod. outlook.com>, Danny Niu writes:
Questions:
Is "Berkerly Sockets API"  defined seperately from the BSD
manpages? Or is it just sections of the BSD manpages? What
happened to "Berkerly Sockets API"?

Proposal:
Folks at POSIX are a bit unwilling to dis-certify some
allegedly existing systems, and think it'd be better IETF
note the purpose of port 0, so that existing app/sys woudn't
break.
So is it too soon to start drafting?

Well UDP source port 0 means don't reply (RFC 768).   It's for
uni directional streams.

As for 0 to select a ephemeral port that is a BSD sockets
convention. That isn't something the IETF should specify.

While _assignment_ of a por is an IETF matter and I mostly agree
with Mark, recognition of how one is being used is is a little
different.

It seems to me that this is rather more an IANA registry matter
than a standardization one

Not quite though. Noting the RFC 768 usage as a source port, aren't
all these uses equivalent to saying 'Not valid on the wire as a
destination port'? That sounds like something the IETF should say,
as a protocol matter, and it leaves the value open for use by APIs
or other software.

This rings bells for me. Only yesterday I had to fix an unassigned
variable bug in my code for draft-ietf-anima-grasp by adding this:
    else:
        listen_port = 0

  Brian

and that, given practices today, it
would be reasonable to annotate the registry by adding "used
for" or "known to be used for" to "reserved".  

That should be mostly a housekeeping matter: could one of the
relevant ADs speak up and indicate whether they want an I-D, a
note (perhaps just this thread), a formal liaison request from
POSIX, or something else?

    john

.


<Prev in Thread] Current Thread [Next in Thread>