Subject: [core] HTTP Header Parameters in draft-ietf-core-http-mapping-07

From: Hannes Tschofenig <[email-masked]>
Date: Mon, 28 Sep 2015 16:36:10 +0200

Dear authors,

I was wondering what the story for mapping HTTP header fields to CoAP
is. I didn't see anything on that topic in your document (based on
briefly scanning through it).

Ciao
Hannes

---

From: "FOSSATI, Thomas (Thomas)" <[email-masked]>
Date: Mon, 28 Sep 2015 16:40:49 +0000

Hi Hannes,

>briefly scanning through it).

The idea is that quite a few HTTP request headers are either not really
interesting on the CoAP side and as such they are removed by the proxy
(e.g. User-Agent, Host), or have an implicit mapping (e.g. Content-Length).

The exception are headers that have to do with representation description
& negotiation: Content-Type, Content-Encoding, and the various Accept-*.
Those are discussed quite extensively in section 6.

Please, tell us if you think there is a need for a specific header mapping
that is not in the document already, or if the current mappings are
insufficiently described.

Cheers, t

---

From: Hannes Tschofenig <[email-masked]>
Date: Tue, 29 Sep 2015 11:50:49 +0200

Hi Thomas,

thanks for your reply.

I believe you should state this assumption in the document (if not done
already and I failed to notice it).

Whether this assumption is justified or not I don't know but there are
certainly HTTP headers that are used, for example those related to
security. As an example, consider the WWW-Authenticate header.

So, in practical terms it means that those deploying CoAP-HTTP proxies
have to carefully determine how the protocol structure looks like and
how the translation works otherwise they may encounter some unpleasant
surprises.

I guess the reason for not copying the HTTP header into CoAP header is
the size limitation of the header parameters. Correct?

Is there a size limitation of the URI length in CoAP?

Ciao
Hannes

---

From: Carsten Bormann <[email-masked]>
Date: Tue, 29 Sep 2015 12:55:38 +0200

On 29 Sep 2015 at 11:51:23, Hannes Tschofenig ([email-masked]) wrote:
Is there a size limitation of the URI length in CoAP? 
As a hard (“artificial”) limitation, CoAP limits the size of each path component and query element to 255 bytes (percent-decoding has already been done at this level).  But you can have any number of these.

Practically, the whole thing (other options and, possibly, payload included) needs to fit into a UDP packet that still gets good delivery probability, so, if adaptation layer fragmentation is involved, you want to stay within an order of 100 bytes (for most applications, I would say ≤ 80) for most of your messages.  But how relevant that consideration is, is highly deployment dependent.

Grüße, Carsten

---

From: "FOSSATI, Thomas (Thomas)" <[email-masked]>
Date: Tue, 29 Sep 2015 11:55:59 +0000

Hi Hannes,

>already and I failed to notice it).

Noted, thanks.

>security. As an example, consider the WWW-Authenticate header.

There is no feature parity between HTTP and CoAP, so translation is not
always possible.

In particular, we've not (yet) standardised a way for doing basic/digest
auth in CoAP, so setting an ACL on a CoAP resource and having the HTTP
side enforce would be completely application specific.

>how the translation works otherwise they may encounter some unpleasant

I think we'd be on the safe side saying that the document describes the
translations that are possible and make sense at the moment?  Future CoAP
feature that can be mapped to HTTP would update it.

What do you think?

Cheers, t