Re: [TLS] Deprecate SHA1 for signatures in TLS 1.3 (was Re: TLS 1.3 draft-07 sneak peek)

Ilari Liusvaara <ilari.liusvaara@elisanet.fi> Sat, 11 July 2015 21:14 UTC

Return-Path: <ilari.liusvaara@elisanet.fi>
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 4DB071ACD00 for <tls@ietfa.amsl.com>; Sat, 11 Jul 2015 14:14:06 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.901
X-Spam-Level:
X-Spam-Status: No, score=-1.901 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001, 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 zunj7TNWd_1L for <tls@ietfa.amsl.com>; Sat, 11 Jul 2015 14:14:05 -0700 (PDT)
Received: from emh04.mail.saunalahti.fi (emh04.mail.saunalahti.fi [62.142.5.110]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 20D401ACCF6 for <tls@ietf.org>; Sat, 11 Jul 2015 14:14:05 -0700 (PDT)
Received: from LK-Perkele-VII (a91-155-194-207.elisa-laajakaista.fi [91.155.194.207]) by emh04.mail.saunalahti.fi (Postfix) with ESMTP id 83B041A2606 for <tls@ietf.org>; Sun, 12 Jul 2015 00:14:03 +0300 (EEST)
Date: Sun, 12 Jul 2015 00:14:03 +0300
From: Ilari Liusvaara <ilari.liusvaara@elisanet.fi>
To: tls@ietf.org
Message-ID: <20150711211403.GB19435@LK-Perkele-VII>
References: <CALuAYvbteowTeyWe9VneRHgyvzTRS3LfKdorWt=jmEy2k+wNqw@mail.gmail.com> <20150711190040.GS28047@mournblade.imrryr.org> <201507111536.50433.davemgarrett@gmail.com> <201507111605.01407.davemgarrett@gmail.com> <20150711204810.GU28047@mournblade.imrryr.org>
MIME-Version: 1.0
Content-Type: text/plain; charset="utf-8"
Content-Disposition: inline
In-Reply-To: <20150711204810.GU28047@mournblade.imrryr.org>
User-Agent: Mutt/1.5.23 (2014-03-12)
Sender: Ilari Liusvaara <ilari.liusvaara@elisanet.fi>
Archived-At: <http://mailarchive.ietf.org/arch/msg/tls/ZKwtfNxmcZiVRTzibYCHGBAdv_w>
Subject: Re: [TLS] Deprecate SHA1 for signatures in TLS 1.3 (was Re: TLS 1.3 draft-07 sneak peek)
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: Sat, 11 Jul 2015 21:14:06 -0000

On Sat, Jul 11, 2015 at 08:48:10PM +0000, Viktor Dukhovni wrote:
> 
>     The public key in the leaf certificate must of course be
>     compatible with the chosen cipher-suite, and the subsequent
>     ServerKeyExchange message must be signed via a mutually supported
>     hash/signature algorithm pair.

Actually, it only needs to be compatible with ciphersuite if client
did not send signature_algorithms. If it did, then it needs to be
compatible with any algorithm pair signaled in that.

It also worked this way in TLS 1.2.


E.g. if client advertised {sha256, ecdsa} + <others> in its
signature_algorithms and TLS_DHE_RSA_WITH_AES_128_GCM_SHA256
+ others in its ciphersuites, then the server MAY pick
TLS_DHE_RSA_WITH_AES_128_GCM_SHA256 and then proceed to
sign the handshake with ECDSA/SHA-256. Despite there being
no DHE_ECDSA ciphersuites.


Also, it occurs to me that analogous situation occurs with client
certificates. But there the rules are much less clear to me:

There are two fields that control supported certificate algorithms:
certificate_types and supported_signature_algorithms, both in
CertificateRequest.

Here's what TLS 1.2 says about interplay of those fields (and
TLS 1.3 wg-07 has very similar language, quite possibly exactly
the same):

"The end-entity certificate provided by the client MUST contain a
key that is compatible with certificate_types. If the key is a
signature key, it MUST be usable with some hash/signature
algorithm pair in supported_signature_algorithms."

Is say ECDSA key "compatible" with rsa_sign?


Also, it seems like TLS 1.3 draft allows fixed_dh certificate_types.
How would those even work? I thought only signature-capable ones
do. Which would mean that certificate_types could be deprecated
entierely. 


-Ilari