Subject: [core] Uri-Port option really needed ?

From: Thomas Fossati <[email-masked]>
Date: Tue, 29 Nov 2011 15:11:38 +0100

I was wondering if the Uri-Port option is really needed, since it can always be inferred by the context.  

In fact, how could it be different from the port on which the server received the request PDU ?

---

From: "Dijk, Esko" <[email-masked]>
Date: Tue, 29 Nov 2011 14:42:02 +0000

Hi,

The Uri-Port number can be different from the UDP port, in which case the Uri-Port option overrides the UDP port value in the CoAP server.

Speculating on the possible uses of this feature:
 - protect the port number against modification attacks if DTLS security is used (while consuming the same nr of bytes in a 6LoWPAN packet)
 - re-use one and the same security context (which is bound to one UDP port, e.g. for coaps scheme) in accessing multiple ports on a CoAP server (in this case the CoAP server port that will in the end be used is the one encoded in the Uri-Port option)

Esko

-----Original Message-----
From: [email-masked] [mailto:[email-masked]] On Behalf Of Thomas Fossati
Sent: Tuesday 29 November 2011 15:12
To: [email-masked] WG
Subject: [core] Uri-Port option really needed ?

In fact, how could it be different from the port on which the server received the request PDU ?
_______________________________________________
core mailing list
[email-masked]
https://www.ietf.org/mailman/listinfo/core

________________________________
The information contained in this message may be confidential and legally protected under applicable law. The message is intended solely for the addressee(s). If you are not the intended recipient, you are hereby notified that any use, forwarding, dissemination, or reproduction of this message is strictly prohibited and may be unlawful. If you are not the intended recipient, please contact the sender by return e-mail and destroy all copies of the original message.

---

From: Thomas Fossati <[email-masked]>
Date: Tue, 29 Nov 2011 17:48:15 +0100

Hi Esko, thanks for the answer.

While searching more carefully into the spec for "Uri-Port" I could find a couple of references to "virtual hosting", which seems to be the base rationale for having a possibly different port value.  It seems that the port is retained for full analogy with the Host header in HTTP.