Re: [TLS] Next Protocol Negotiation 03

Marsh Ray <marsh@extendedsubset.com> Wed, 25 April 2012 15:58 UTC

Return-Path: <marsh@extendedsubset.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 B2B8821F875E for <tls@ietfa.amsl.com>; Wed, 25 Apr 2012 08:58:22 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.065
X-Spam-Level:
X-Spam-Status: No, score=-2.065 tagged_above=-999 required=5 tests=[AWL=0.535, BAYES_00=-2.599]
Received: from mail.ietf.org ([12.22.58.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id svD5-0lkNQJe for <tls@ietfa.amsl.com>; Wed, 25 Apr 2012 08:58:22 -0700 (PDT)
Received: from mho-01-ewr.mailhop.org (mho-01-ewr.mailhop.org [204.13.248.71]) by ietfa.amsl.com (Postfix) with ESMTP id 2947021F86A2 for <tls@ietf.org>; Wed, 25 Apr 2012 08:58:22 -0700 (PDT)
Received: from xs01.extendedsubset.com ([69.164.193.58]) by mho-01-ewr.mailhop.org with esmtpa (Exim 4.72) (envelope-from <marsh@extendedsubset.com>) id 1SN4bl-000GcY-Ki; Wed, 25 Apr 2012 15:58:21 +0000
Received: from [172.16.2.4] (localhost [127.0.0.1]) by xs01.extendedsubset.com (Postfix) with ESMTP id A42726081; Wed, 25 Apr 2012 15:58:20 +0000 (UTC)
X-Mail-Handler: MailHop Outbound by DynDNS
X-Originating-IP: 69.164.193.58
X-Report-Abuse-To: abuse@dyndns.com (see http://www.dyndns.com/services/mailhop/outbound_abuse.html for abuse reporting information)
X-MHO-User: U2FsdGVkX19VfpqCjJtRZWJfqNDKGEj/cDMuNM1IH0M=
Message-ID: <4F981F1B.3020101@extendedsubset.com>
Date: Wed, 25 Apr 2012 10:58:19 -0500
From: Marsh Ray <marsh@extendedsubset.com>
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:11.0) Gecko/20120410 Thunderbird/11.0.1
MIME-Version: 1.0
To: Adam Langley <agl@google.com>
References: <CAL9PXLy31VzxLidgOy64MnDAyRE=HU=hxyBXW1rgB+Xnd0vKjA@mail.gmail.com> <13435052-1245-4C37-A0D0-C5CBFFB1FE75@checkpoint.com> <CAL9PXLzOHA_5C16sQP3b5m75VMeCFHr8ivW7K4-+xW4qaj+40Q@mail.gmail.com>
In-Reply-To: <CAL9PXLzOHA_5C16sQP3b5m75VMeCFHr8ivW7K4-+xW4qaj+40Q@mail.gmail.com>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
Cc: "tls@ietf.org" <tls@ietf.org>
Subject: Re: [TLS] Next Protocol Negotiation 03
X-BeenThere: tls@ietf.org
X-Mailman-Version: 2.1.12
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: Wed, 25 Apr 2012 15:58:22 -0000

On 04/25/2012 08:09 AM, Adam Langley wrote:
>
> We're also looking at other extensions, for example encrypted client
> certs[1] (which have been suggested by others too), that also involve
> encrypted handshake messages. So that state machine change may be be
> useful for a range of needs.

So if we are going to change the state machine in a generally more 
useful way, why not make the change more general?

I.e., instead of

> struct {
>      opaque selected_protocol<0..255>;
>      opaque padding<0..255>;
>    } NextProtocol;

We could define something closely analogous to a Hello message extension 
area, records sent immediately after the CCS in their respective directions:

struct {
     Extension extensions<0..2^16-1>;
} ClientAdditionalExtensions;
struct {
     Extension extensions<0..2^16-1>;
} ServerAdditionalExtensions;

thus re-using the definition of 'Extension' from RFC 5246.

The use of these ClientServerAdditionalExtensions record could be 
negotiated with (what else?) a new extension. We could call it the 
AdditionalExtensionsNegotiationExtension, but maybe there's a better 
name. I envision this extension could be sent on the Client Hello and 
replied to on the Server Hello if this feature is negotiated.

We could define this Client Hello extension to be empty, or it might be 
useful to have it list the ExtensionTypes for which the actual data will 
be sent in the CAE and those for which the reply is required to be sent 
in the SAE record after the CCS.

The extension sent in reply on the Server Hello reply would indicate the 
feature was negotiated successfully. It could list the ExtensionTypes 
for which the use of was negotiated successfully, but the actual reply 
payload will be found in the SAE after the CCS.

There are considerations for resumed handshakes because the server CCS 
comes before the client CCS. But there are already such considerations: 
"Most current TLS extensions are relevant only when a session is 
initiated: when an older session is resumed, the server does not process 
these extensions in Client Hello, and does not include them in Server 
Hello.  However, some extensions may specify different behavior during 
session resumption." [RFC5246]

This would enable implementors to take the pain of modifying their state 
machines once while also enabling other extensions to benefit from the 
privacy enhancement.

Thus, the definition of next_protocol remains nearly the same, except 
that it is now the "extension data" field of a proper 
next_protocol_negotiation type extension.

We'd have to decide which (if any) of the currently defined extension 
types should be considered incompatible with this new feature, but it 
seems like most would transition smoothly. Few current extensions seem 
to affect handshake messages between the Hellos and the CCS. Nor does it 
seem likely that many will specify different behavior during session 
resumption."

- Marsh