Re: [TLS] Closing on 0-RTT

Colm MacCárthaigh <colm@allcosts.net> Mon, 12 June 2017 18:12 UTC

Return-Path: <colm@allcosts.net>
X-Original-To: tls@ietfa.amsl.com
Delivered-To: tls@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id D8C9012EB4E for <tls@ietfa.amsl.com>; Mon, 12 Jun 2017 11:12:30 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.899
X-Spam-Level:
X-Spam-Status: No, score=-1.899 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, HTML_MESSAGE=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=allcosts-net.20150623.gappssmtp.com
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id gIZnjqtmtqyb for <tls@ietfa.amsl.com>; Mon, 12 Jun 2017 11:12:28 -0700 (PDT)
Received: from mail-yw0-x229.google.com (mail-yw0-x229.google.com [IPv6:2607:f8b0:4002:c05::229]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 7C65F12EACE for <tls@ietf.org>; Mon, 12 Jun 2017 11:12:28 -0700 (PDT)
Received: by mail-yw0-x229.google.com with SMTP id e142so31044085ywa.1 for <tls@ietf.org>; Mon, 12 Jun 2017 11:12:28 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=allcosts-net.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=Rzx+qlFE2xPUtIsaSEsELLR2AZq4un4fRKymsXCvSqc=; b=CoKIV7Dc4VGO5rFWFEBh+5Ig7hPNuK6ieBq95SInRtPQgLRBK3EvmyjSq/HQYKIb3y WZ/uUvSM7ixaK4U7eFfSTEwVusY/ddZRSTLQp9IH+bIjwDpV0CIMLmXPMsPonkz1towk ambhxkZK/SE7aO2nh4afXmqYCUD6VvZ6eJFc74q1N5x2EbW/2guM7adn73yxGkhUP+pB +52+h6FXOkj9PCpW8BJKkEiF1hAh0NdyTbosIWv+4AOlY3j47GLk5jra0svMtsorVo4j cfroJknz4anOHwnnC1Wg86HpXUmFMtZnjSP76h5evdK1ntsENoGi8p2AdAGhk17EFHZX EUzw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=Rzx+qlFE2xPUtIsaSEsELLR2AZq4un4fRKymsXCvSqc=; b=CtIZr5HubDxdbz/E+UNgFqUiZltQ2PZJSU/KHnkQMzBi//ujya5YgE3UVBeRtQh2SI XKDyjB0HSMJdiENDr4nskafhOuooMJucQ4BkjGYV/qXel/OjpFISJWAAGFzawfZ5+hPZ bxtKRSQQLnqALLKsRolk8PeCClWMKsRHo/ZJ9cGDqTIBmOk+DzKaHCCGuPjT91bYVib4 GokruT6D3/+pwpNjLVdu8ty8pnGtdNcz1Oge88aF8C29lUZT+q/qol7KN+GmuddEVxa0 nWl/6l78/YY4PmqEKiMPU8kqdqh9zCdi58ii4DiapxNUcG+jrEE1aYsCe9IbdZnI7k7Y Y0ZQ==
X-Gm-Message-State: AKS2vOyiz6tlKJ8S/d6NyoHrq4B+27sFfChQ70Ac82HoSzL8FczjtzvN PXytRppFZ4hzKwM32Mep6FfvDTwPaXUJ
X-Received: by 10.129.172.39 with SMTP id k39mr203414ywh.74.1497291147591; Mon, 12 Jun 2017 11:12:27 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.129.93.70 with HTTP; Mon, 12 Jun 2017 11:12:27 -0700 (PDT)
In-Reply-To: <CABcZeBNLo51y4-MYS6NTQn9OWg5jTYYpwxn1fiKKNL5bWA37TA@mail.gmail.com>
References: <CABcZeBNLo51y4-MYS6NTQn9OWg5jTYYpwxn1fiKKNL5bWA37TA@mail.gmail.com>
From: Colm MacCárthaigh <colm@allcosts.net>
Date: Mon, 12 Jun 2017 11:12:27 -0700
Message-ID: <CAAF6GDe58QwbSvYG__fbtT5z6Co5h6AN=PFnD1pz9R8R0XN7hg@mail.gmail.com>
To: Eric Rescorla <ekr@rtfm.com>
Cc: "tls@ietf.org" <tls@ietf.org>
Content-Type: multipart/alternative; boundary="f403045e56acfa57b00551c742a5"
Archived-At: <https://mailarchive.ietf.org/arch/msg/tls/V8IJ0QqHxcKo7t5jVOykLtdVupk>
Subject: Re: [TLS] Closing on 0-RTT
X-BeenThere: tls@ietf.org
X-Mailman-Version: 2.1.22
Precedence: list
List-Id: "This is the mailing list for the Transport Layer Security working group of the IETF." <tls.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/tls>, <mailto:tls-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/tls/>
List-Post: <mailto:tls@ietf.org>
List-Help: <mailto:tls-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/tls>, <mailto:tls-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 12 Jun 2017 18:12:31 -0000

On Sun, Jun 11, 2017 at 8:18 AM, Eric Rescorla <ekr@rtfm.com> wrote:

> Here's what I propose to do:
>
> - Describe the attacks that Colm described.
>
> - Distinguish between replay and retransmission
>
> - Mandate (SHOULD-level) that servers do some sort of bounded
>   (at-most-N times) anti-replay mechanism and emphasize that
>   implementations that forbid replays entirely (only allowing
>   retransmission) are superior.
>
> - Describe the stateless mechanism as a recommended behavior but not
>   as a substitute for the other mechanisms. As Martin Thomson has
>   pointed out, it's a nice pre-filter for either of these other
>   mechanisms.
>
> - Clarify the behavior you need to get PFS.
>
> - Require (MUST) that clients only send and servers only accept "safe"
>   requests in 0-RTT, but allow implementations to determine what is
>   safe.
>
> Note: there's been a lot of debate about exactly where this stuff
> should go in the document and how it should be phrased.  I think these
> are editorial questions and so largely my discretion.
>

First of all, thanks for doing this, that all sounds great! The TLS spec is
obviously monumentally important to the internet, and years of hard work
aren't made easier by late-coming changes, that shouldn't be thankless.


> Here's what I do not intend to do.
>
> - Mandate (MUST-level) any anti-replay mechanism. I do not believe
>   there is any WG consensus for this.
>

The one case here where I'd really argue for a "MUST" is middle-boxes like
CDNs. The concern I have is if someone has an application that uses
throttling or is vulnerable to a resource-exhaustion problem and goes and
puts a CDN in front of it, it's not obvious that enabling TLS 1.3 could
open them to a new kind of DOS attack.

We've already seen CDNs enable TLS 1.3 with unintentionally broken 0-RTT
mitigations, so that's clear evidence that the existing guidance isn't
sufficient. I think it would help manage the interoperability risks if we
can point out to their customers that the configuration is unambiguously
broken. Or at least, it helps to flag it as a security issue, which makes
it more likely to get fixed. Absent this, the operators of "backend"
applications would have to live with risk that is created by the upstream
CDN providers for their own convenience. That seems like a really bad
interoperability set up.

I'd argue for at-most-once protection here, since that's the only way a
client can make deterministic decisions, and it's also easier to audit and
GREASE. But there doesn't seem to be consensus around that. At the moment,
I feel that's a bit like the lack of consensus the "Clean coal" industry
has on global warming though, because it seems to be an argument rooted in
operational convenience rather than actual security. This is not the
standard we apply in other cases; we wouldn't listen to those who say that
it's ok to keep RC4 or MD5 in the standard because the problems are small
and the operational performance benefit is worth it. My spidey-sense is
that these attacks will get better and more refined over time.

Nevertheless, /some/ guaranteed replay protection would be better than
none. particularly in this case. So if it's at-most-N, and N is small
enough to at least avoid many throttling cases, that's something worth
taking, even though it does leave open the easier cache-analysis attacks.

- Design a mechanism to allow the server to tell the client that it
>   either (a) enforces strong anti-replay or (b) deletes PSKs after
>   first use. Either of these seem like OK ideas, but they can be added
>   to NST as extensions at some future time, and I haven't seen a lot
>   of evidence that existing clients would consume these.
>

This can happen totally outside of the protocol too; as-in an operator can
advertise it as a feature. Likely most useful for the forward secrecy case.

-- 
Colm