Re: [TLS] 0-RTT encrypted data limits

Eric Rescorla <ekr@rtfm.com> Wed, 31 August 2016 18:23 UTC

Return-Path: <ekr@rtfm.com>
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 D2ED412D668 for <tls@ietfa.amsl.com>; Wed, 31 Aug 2016 11:23:54 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.599
X-Spam-Level:
X-Spam-Status: No, score=-2.599 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-0.7] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=rtfm-com.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 VXhLfDYQTh72 for <tls@ietfa.amsl.com>; Wed, 31 Aug 2016 11:23:53 -0700 (PDT)
Received: from mail-yw0-x230.google.com (mail-yw0-x230.google.com [IPv6:2607:f8b0:4002:c05::230]) (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 079E212D642 for <tls@ietf.org>; Wed, 31 Aug 2016 11:23:53 -0700 (PDT)
Received: by mail-yw0-x230.google.com with SMTP id r9so36088599ywg.0 for <tls@ietf.org>; Wed, 31 Aug 2016 11:23:52 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rtfm-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=PrRI+XvWxicrTwnQYRBzjNGlLRA61LJ4mWbkEhVl2Yc=; b=RJa/4pMc7onjDyQeZ93HozIUqIHKboYR5+wH4VlcNY+wDAQJlv14kizkXzIKh5y4iG Aw0iGQz4DBbKASZZwHc8oNajaZcuXoDrlEwjVqMdf1mUNBVgooW48+FskPuB7PDnGY+R /OIgj8ErZrzI2/pRv07fbJVolcd7mFW3aGYL3dZTevc3WrB+eUAf4sqvaYKx1QDEjnzj obJHAu6hWBf7UXHCRwYm/MmwRSTCibGZR6sJBLogi58dn081xHJbkOwM3RR3toYR0KaI QP4L8IK8slsvZGTfefX5+sV2gA2Pf4EWWHmh9h1OzKgH3QucfUjH69ExYrhcIjWOfe10 AtMA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=PrRI+XvWxicrTwnQYRBzjNGlLRA61LJ4mWbkEhVl2Yc=; b=nDleZEB5LrpLqK/9RULeHz3DoOf9QkzOtuYgPBPfEmhjCESXzOq/U/PeWpi+4rm6br gP70bJtJglJELs1L9llFnWp8mLOQDg3S/xKhSahAdUVvQYT6Gl1ja0hUZ/vVKCiFTZ2S G/v8GxojlWoGsfma0dK6MRJkzM+kVcPSFokrbKs6EtQs1EcK/B4WOxmyfbRQ5RbRKPWf V5h/ZM/4KNdxRWfpm/KCTWIyfF6La9fvdXjg+Zeb3HouSmL9Lb261gnkoFYBSYMBYW3C ozg4ITZ0cLu4p093f8UP0LzDXFAqxXtJgdL39r/FrR74UM532KNR6egDUUTRIgAhtCaG kI5A==
X-Gm-Message-State: AE9vXwOU3g/iGXi0t5zO8++4PnyfT8E9HoF1ZAUuoLyJBhvo8knBpmm7RGUVQ71/bAY+zo8NPcl71cPzOslO2g==
X-Received: by 10.13.221.198 with SMTP id g189mr9653193ywe.93.1472667832333; Wed, 31 Aug 2016 11:23:52 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.129.48.193 with HTTP; Wed, 31 Aug 2016 11:23:11 -0700 (PDT)
In-Reply-To: <6918283.boJRZ9WqjH@pintsize.usersys.redhat.com>
References: <6918283.boJRZ9WqjH@pintsize.usersys.redhat.com>
From: Eric Rescorla <ekr@rtfm.com>
Date: Wed, 31 Aug 2016 11:23:11 -0700
Message-ID: <CABcZeBMOyM2v3gt69gHzfW7k5w=OwFqCUiER-bPERfNkLGhpWQ@mail.gmail.com>
To: Hubert Kario <hkario@redhat.com>
Content-Type: multipart/alternative; boundary=94eb2c0779ce04eb65053b62337b
Archived-At: <https://mailarchive.ietf.org/arch/msg/tls/T2ha8zdAU8ZQYzMxtotgoYKSpsM>
Cc: "tls@ietf.org" <tls@ietf.org>
Subject: Re: [TLS] 0-RTT encrypted data limits
X-BeenThere: tls@ietf.org
X-Mailman-Version: 2.1.17
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: Wed, 31 Aug 2016 18:23:56 -0000

On Wed, Aug 31, 2016 at 11:14 AM, Hubert Kario <hkario@redhat.com> wrote:

> Current draft has the following text in it:
>
>     If any of these checks fail, the server MUST NOT respond
>     with the extension and must discard all the remaining first
>     flight data (thus falling back to 1-RTT). If the client attempts
>     a 0-RTT handshake but the server rejects it, it will generally
>     not have the 0-RTT record protection keys and must instead
>     trial decrypt each record with the 1-RTT handshake keys
>     until it finds one that decrypts properly, and then pick up
>     the handshake from that point.
>
> My understanding of that, in case client does 0-RTT but server rejects it
> (because the PSK is too old or its time is different enough) is that the
> server needs to keep on reading arbitrarily large amounts of data it has no
> idea what to do with. All using slow path (thinking exception handling in
> particular).
>
> Is my understanding correct?
>

It's not clear to me that it's particularly slow. You get a MAC failure and
rejecting
the packet is slightly faster than processing it.


Why is there no limit on the amount of data that can be encrypted using PSK
> keys (0-RTT)?
>

I don't think this would usefully improve things.

-Ekr

--
> Regards,
> Hubert Kario
> Senior Quality Engineer, QE BaseOS Security team
> Web: www.cz.redhat.com
> Red Hat Czech s.r.o., Purky┼łova 99/71, 612 45, Brno, Czech Republic
> _______________________________________________
> TLS mailing list
> TLS@ietf.org
> https://www.ietf.org/mailman/listinfo/tls
>
>