Re: [TLS] Extensions "supported_groups" and "key_share" in TLS 1.3

Ilari Liusvaara <ilariliusvaara@welho.com> Thu, 26 November 2015 14:26 UTC

Return-Path: <ilariliusvaara@welho.com>
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 423871B3A35 for <tls@ietfa.amsl.com>; Thu, 26 Nov 2015 06:26:48 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.2
X-Spam-Level:
X-Spam-Status: No, score=-1.2 tagged_above=-999 required=5 tests=[BAYES_05=-0.5, RCVD_IN_DNSWL_LOW=-0.7] 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 JTEShd5NYMdg for <tls@ietfa.amsl.com>; Thu, 26 Nov 2015 06:26:46 -0800 (PST)
Received: from filtteri2.pp.htv.fi (filtteri2.pp.htv.fi [213.243.153.185]) by ietfa.amsl.com (Postfix) with ESMTP id 15F9E1B3A34 for <tls@ietf.org>; Thu, 26 Nov 2015 06:26:45 -0800 (PST)
Received: from localhost (localhost [127.0.0.1]) by filtteri2.pp.htv.fi (Postfix) with ESMTP id 7233919BF49; Thu, 26 Nov 2015 16:26:44 +0200 (EET)
X-Virus-Scanned: Debian amavisd-new at pp.htv.fi
Received: from smtp5.welho.com ([213.243.153.39]) by localhost (filtteri2.pp.htv.fi [213.243.153.185]) (amavisd-new, port 10024) with ESMTP id UrGKXGfnozHF; Thu, 26 Nov 2015 16:26:33 +0200 (EET)
Received: from LK-Perkele-V2 (87-92-35-116.bb.dnainternet.fi [87.92.35.116]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp5.welho.com (Postfix) with ESMTPSA id A37ED5BC005; Thu, 26 Nov 2015 16:26:33 +0200 (EET)
Date: Thu, 26 Nov 2015 16:26:32 +0200
From: Ilari Liusvaara <ilariliusvaara@welho.com>
To: Xuelei Fan <xuelei.fan@vimino.com>
Message-ID: <20151126142632.GA3582@LK-Perkele-V2.elisa-laajakaista.fi>
References: <CAAgBOhuOPB=jxO=WWHmy_y7ARY5qfdK2x4xC9t-Z-vn0UU5Paw@mail.gmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset="utf-8"
Content-Disposition: inline
In-Reply-To: <CAAgBOhuOPB=jxO=WWHmy_y7ARY5qfdK2x4xC9t-Z-vn0UU5Paw@mail.gmail.com>
User-Agent: Mutt/1.5.24 (2015-08-30)
Sender: ilariliusvaara@welho.com
Archived-At: <http://mailarchive.ietf.org/arch/msg/tls/QCDt94M8ZSac2eBobPxgJ_7qVw4>
Cc: "tls@ietf.org" <tls@ietf.org>
Subject: Re: [TLS] Extensions "supported_groups" and "key_share" in TLS 1.3
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: <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: Thu, 26 Nov 2015 14:26:48 -0000

On Thu, Nov 26, 2015 at 09:52:37PM +0800, Xuelei Fan wrote:
> Hi,
> 
> Per the latest draft of TLS 1.3, both "supported_groups" and "key_share"
> extensions are REQUIRED for DHE or ECDHE cipher suites (Section 8.2).  Both
> extension need to provide the supported named groups in preference order.
> Looks like the functions are overlapped.  I was wondering, it may be nice
> to obsolete the "supported_groups" extension, and use "key_share" extension
> for both the supported named groups and the key exchange information for
> each group.

This wouldn't work if one had to downnegotiate TLS 1.2. That is going to
happen A LOT.

Also, one can support curve, but not prefer to send share on it (the
server can call for it, at cost of extra RTT).

Plus, some of the curves are of special purpose and won't ever have
shares.

Also, IIRC, if client has no shares, it omits key_share. If server wants
FS cipher suite, it then has to signal retry.

> The "supported_groups" extension defines the groups, while the "key_share"
> extension defines both the groups and the key exchange information.  Both
> extension has its own preferences for the supported named groups.  It's
> easy to get conflicted if the two preferences are not consistent.  The
> "key_share" extension contains the information of the supported named
> groups.  So, the information can be used to indicate the client supported
> named groups.  Maybe, for TLS 1.3, it is not necessary to use the
> "supported_groups" extension any more.

The only way to be conflicted would be to send key share for group not in
supported_groups. Sending supported_group for group not in key_shares is
not a conflict[1].


[1] In fact, I expect many clients to send shares for P-256 and X25519,
plus offer P-384 and X448 (without shares unless requested).


-Ilari