Re: [TLS] Unifying tickets and sessions

Brian Smith <brian@briansmith.org> Mon, 20 October 2014 23:34 UTC

Return-Path: <brian@briansmith.org>
X-Original-To: tls@ietfa.amsl.com
Delivered-To: tls@ietfa.amsl.com
Received: from localhost (ietfa.amsl.com [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 62AF21ACC84 for <tls@ietfa.amsl.com>; Mon, 20 Oct 2014 16:34:53 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.978
X-Spam-Level:
X-Spam-Status: No, score=-1.978 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, FM_FORGED_GMAIL=0.622, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-0.7, SPF_PASS=-0.001] autolearn=ham
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 xYh6_BVM-4n4 for <tls@ietfa.amsl.com>; Mon, 20 Oct 2014 16:34:51 -0700 (PDT)
Received: from mail-ob0-f178.google.com (mail-ob0-f178.google.com [209.85.214.178]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 0E0061A0673 for <tls@ietf.org>; Mon, 20 Oct 2014 16:34:51 -0700 (PDT)
Received: by mail-ob0-f178.google.com with SMTP id wn1so64626obc.23 for <tls@ietf.org>; Mon, 20 Oct 2014 16:34:50 -0700 (PDT)
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:date :message-id:subject:from:to:cc:content-type; bh=Nv1E8chEsB9kt1i48FIYHG+E9qdn9qJ6xWE3BOc5pQM=; b=ZSJm+OedLvXV8ndk7HqbQokWnjSagehIcoZfUoNbhTpCQ5eCz2hd63K8ULuPReR827 q5VeyHOJJFbtlmvVGcVwtts+aRcscgb55Uv6Quk9dEaUANy8h2gcb+GgbsgpxXqGxu/t V5IiSRO9le0p7OOKzMKoWE02ZBAk3SDnebtvrFS/WUhSqyY5B/BK3ZvrM1KIni8DsXuO c5Zm87eQbpvhHLiRQIXYakCGRatZbdjW3phYfVBpd2YnC/iBOHR8mq4zjoW0ARj7Z6gk lUoPy095J/QslM6+MkaNVC0LepLolPIhRnrUm9e3QTFAoO5wEhiCPWZ9fx/zD0q7wYdc mPfQ==
X-Gm-Message-State: ALoCoQlvhiM+NJzNVU3nljxvDSVXRqkxpNyvqdTboohhFTHeOUa+nq5KVVHRD15X5DRdpoyU5ais
MIME-Version: 1.0
X-Received: by 10.202.80.147 with SMTP id e141mr83856oib.80.1413848090527; Mon, 20 Oct 2014 16:34:50 -0700 (PDT)
Received: by 10.76.93.9 with HTTP; Mon, 20 Oct 2014 16:34:50 -0700 (PDT)
In-Reply-To: <2A0EFB9C05D0164E98F19BB0AF3708C71D3A8C48AF@USMBX1.msg.corp.akamai.com>
References: <2A0EFB9C05D0164E98F19BB0AF3708C71D3A8C48AF@USMBX1.msg.corp.akamai.com>
Date: Mon, 20 Oct 2014 16:34:50 -0700
Message-ID: <CAFewVt4txC_N7A8jPMT146+9MXbbS_0Vd9vkDXn7R-vjZyaQaQ@mail.gmail.com>
From: Brian Smith <brian@briansmith.org>
To: "Salz, Rich" <rsalz@akamai.com>
Content-Type: multipart/alternative; boundary="001a113d801833ded90505e329e1"
Archived-At: http://mailarchive.ietf.org/arch/msg/tls/el0t3t40EYh_7HXLP2A_M-PnP7s
Cc: "TLS@ietf.org (tls@ietf.org)" <tls@ietf.org>
Subject: Re: [TLS] Unifying tickets and sessions
X-BeenThere: tls@ietf.org
X-Mailman-Version: 2.1.15
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: <http://www.ietf.org/mail-archive/web/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, 20 Oct 2014 23:34:53 -0000

Rich,

I think your suggestion is a very good idea. In particular, note that
session tickets could be encrypted during the handshake, but
ServerHello.session_id
cannot. This is valuable because it allows for a level of unlinkability
between the initial connection for a session and a resumption of that
session. If the server rotates tickets for a session on every connection
(resumption or otherwise), this unlinkability would be maintained against
all connections for a session. This seems like a valuable privacy feature.

On Mon, Oct 20, 2014 at 1:11 PM, Salz, Rich <rsalz@akamai.com> wrote:

> For 1.3 we bring in the extension definitions from 5077. For the wire
> format, it doesn't matter if the information is a session identifier (a
> short string, referring to state maintained on the server) or a ticket (the
> actual crypto state, stored on the client). Perhaps to be general, we call
> it session token.
>

I suggest, to minimize changes from RFC 5077, and to minimize confusion,
that we continue to call it a session ticket.

A TLS 1.3 client MUST send an empty session_id field. It may send a ticket
> extension. If the server is willing to accept the crypto state, it sends a
> "1" in the returned session_id field, otherwise it sends an empty
> session_id. This is the only use of session_id in TLS 1.3.
>

This change from RFC5077 is not necessary. You just make this change
instead:

-  If a server is planning on issuing a session ticket to a client that
-  does not present one, it SHOULD include an empty Session ID in the
-  ServerHello.  If the server rejects the ticket and falls back to the
-  full handshake then it may include a non-empty Session ID to indicate
-  its support for stateful session resumption.  If the client receives
-  a session ticket from the server, then it discards any Session ID
-  that was sent in the ServerHello.

-

-  When presenting a ticket, the client MAY generate and include a
-  Session ID in the TLS ClientHello.  If the server accepts the ticket
-  and the Session ID is not empty, then it MUST respond with the same
-  Session ID present in the ClientHello.  This allows the client to
-  easily differentiate when the server is resuming a session from when
-  it is falling back to a full handshake.  Since the client generates a
-  Session ID, the server MUST NOT rely upon the Session ID having a
-  particular value when validating the ticket.  If a ticket is
-  presented by the client, the server MUST NOT attempt to use the
-  Session ID in the ClientHello for stateful session resumption.

-  Alternatively, the client MAY include an empty Session ID in the

-  ClientHello.  In this case, the client ignores the Session ID sent in

-  the ServerHello and determines if the server is resuming a session by

+  The client MUST always include an empty Session ID in the ClientHello.

+  The server MUST always include an empty Session ID in the ServerHello.

+  The client determines if the server is resuming a session by

the subsequent handshake messages.


This is a smaller change for implementations and leaks less
information in the plaintext part of the handshake. In particular, on
top of this change, you could in theory make it so that the full
handshake and the resumption handshake look the same on the wire
(modulo leaking the distinction via timing). As I said before [2], I
think that is worth trying to accomplish, both for maximizing interop
as well as improving privacy.


Cheers,

Brian

[1] https://tools.ietf.org/html/rfc5077#section-3.4
[2] http://www.ietf.org/mail-archive/web/tls/current/msg10903.html