Re: [core] draft-ietf-core-coap-06 The CoAP/DTLS/CoAP Turkey Sandwich layer violation train wreck

Eric Rescorla <ekr@rtfm.com> Fri, 06 May 2011 07:49 UTC

Return-Path: <ekr@rtfm.com>
X-Original-To: core@ietfa.amsl.com
Delivered-To: core@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 7A3A7E069C for <core@ietfa.amsl.com>; Fri, 6 May 2011 00:49:44 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -101.327
X-Spam-Level:
X-Spam-Status: No, score=-101.327 tagged_above=-999 required=5 tests=[AWL=-0.649, BAYES_00=-2.599, FM_FORGED_GMAIL=0.622, MANGLED_BEST=2.3, RCVD_IN_DNSWL_LOW=-1, USER_IN_WHITELIST=-100]
Received: from mail.ietf.org ([64.170.98.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id TnLVuBTDDKEo for <core@ietfa.amsl.com>; Fri, 6 May 2011 00:49:43 -0700 (PDT)
Received: from mail-gw0-f44.google.com (mail-gw0-f44.google.com [74.125.83.44]) by ietfa.amsl.com (Postfix) with ESMTP id 2E0ECE0663 for <core@ietf.org>; Fri, 6 May 2011 00:49:43 -0700 (PDT)
Received: by gwb20 with SMTP id 20so1300909gwb.31 for <core@ietf.org>; Fri, 06 May 2011 00:49:42 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.91.63.8 with SMTP id q8mr220633agk.80.1304668182266; Fri, 06 May 2011 00:49:42 -0700 (PDT)
Received: by 10.91.162.16 with HTTP; Fri, 6 May 2011 00:49:42 -0700 (PDT)
In-Reply-To: <EAE9DFEE-01E9-4BE7-8CA2-136945CB6340@tzi.org>
References: <1FFCF0B6-2DF8-4776-BC6B-47069737AD50@cisco.com> <2ECE1C68-6650-43D4-97B6-2D405143C845@tzi.org> <BANLkTin_gwk+eGxwcRRPb8YcVpvQe1UgxQ@mail.gmail.com> <EAE9DFEE-01E9-4BE7-8CA2-136945CB6340@tzi.org>
Date: Fri, 06 May 2011 00:49:42 -0700
Message-ID: <BANLkTik0MYry5_skJo8CwLAeDAxTxjRFSA@mail.gmail.com>
From: Eric Rescorla <ekr@rtfm.com>
To: Carsten Bormann <cabo@tzi.org>
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: quoted-printable
Cc: core WG <core@ietf.org>
Subject: Re: [core] draft-ietf-core-coap-06 The CoAP/DTLS/CoAP Turkey Sandwich layer violation train wreck
X-BeenThere: core@ietf.org
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: "Constrained RESTful Environments \(CoRE\) Working Group list" <core.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/core>, <mailto:core-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/core>
List-Post: <mailto:core@ietf.org>
List-Help: <mailto:core-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/core>, <mailto:core-request@ietf.org?subject=subscribe>
X-List-Received-Date: Fri, 06 May 2011 07:49:44 -0000

On Thu, May 5, 2011 at 6:24 PM, Carsten Bormann <cabo@tzi.org> wrote:
> On May 6, 2011, at 02:51, Eric Rescorla wrote:
>
>> 1. Use STUN as-is.
>
> Yep, we are doing that.
> (The escaping stuff is insurance for a case that is rather unlikely.  We could take it out.)
>
> What is the status about STUN coexisting with DTLS?

As far as I know, there's no problem, since the leading bytes plus cookies make
collisions very unlikely.


>> 2. Use a leading framing byte to distinguish DTLS and CoAP from STUN.
>> If you're really worried
>> about compactiness,
>
> (Yes, we are.)
>
>> then pick only a single value to distinguish DTLS
>> (e.g., 0xffffffff)
>
> (That would be a bit long.)

Sorry, brain failure. 0xff


>> and use all
>> the remaining values to give you a little more room in the rest of the packet.
>
> Sure, we could do that.  It would mean spending another byte for all DTLS packets.

Right. My argument is that that's not that big a deal because it only
increases space
by ~5%.


> More importantly, it also means DTLS packets no longer look like DTLS packets, which complicates debugging.

Yes, I agree that that's suboptimal. That's why I prefer separate ports...
The material you're quoting above is just some other thoughts for dealing with
the same port if people insist.


> I would like to learn more about your plans to expand the DTLS ContentType space.
> This hasn't changed since 1996.  Of course, it could, next month.
> Again, the escaping stuff is insurance for this case.  We could take it out.

I don't think there are any immediate plans to do so--though note that
http://tools.ietf.org/html/draft-seggelmann-tls-dtls-heartbeat-01
does contemplate one addition. And I would assume that we intend to
assign the content-types towards the bottom of the range first. That said,
I don't think TLS-WG has by any means decided to commit to not
assigning a bunch more types.

Bes,t
-Ekr