Re: [TLS] Enforcing stronger server side signature/hash combinations in TLS 1.2
Eric Rescorla <ekr@rtfm.com> Thu, 23 March 2017 18:25 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 BA10D129B5D for <tls@ietfa.amsl.com>; Thu, 23 Mar 2017 11:25:30 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.598
X-Spam-Level:
X-Spam-Status: No, score=-2.598 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, URIBL_BLOCKED=0.001] 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 bvOwMjj2A4Ma for <tls@ietfa.amsl.com>; Thu, 23 Mar 2017 11:25:28 -0700 (PDT)
Received: from mail-yw0-x229.google.com (mail-yw0-x229.google.com [IPv6:2607:f8b0:4002:c05::229]) (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 B6A8F1294C4 for <tls@ietf.org>; Thu, 23 Mar 2017 11:25:20 -0700 (PDT)
Received: by mail-yw0-x229.google.com with SMTP id d191so26072217ywe.2 for <tls@ietf.org>; Thu, 23 Mar 2017 11:25:20 -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=MG6R5qHWle93oINHxrKgJylurn5s30R+f9bCv4PX8Ek=; b=LSxe3l0iMO0xXk3NTeZ0nzi42q0XCBZISRUUduTXWdxbqTEZwFszmbrn37vy414TDX WZlB6n3bqutv6ycbQJlUr8xcBBBp/ScKXr3dmJy7vvkB9T+YYmjVR89+Fh8nqhjTyUZ6 /ODdXtgH1av4y8H1SR6zLqST3doKKnUYUk+9JrtfZNnKs1/hAu8mhZ8mOI8fCxR4E5xe 52/foISxBQPdgF6Ep3I9+XNk9vEh1GcrVXz9f/zydwNEJqKVpNkNqSXUeSvVXbZ35egm LA6evtF4IXAP8wdITirWIZ7X3+myoDMYMCOssXM+IRCdEthin/GOjo7hhmsKKYEbFp/f hWWA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=MG6R5qHWle93oINHxrKgJylurn5s30R+f9bCv4PX8Ek=; b=pXSNbpWQz1OShSHyD3QtR9cA8WC7emdWi4wHCaneW6tSPEyK1DPFCiPY2KydWttanq 0grUo4nD1mKRJFd+ICmwm7gpHtdcCHdpktLTxDLuChnZP5fXnmulRwgjREfJtbl8PTH+ G7KtliqM7i/icb4JwLqYX1uH+j98CyEcAt9ogqDdpRD+3a0eWEvmyAM/YoSSedjrcIIo ph5zsxSs0NuVkVh3OB3p+vz4OT53WhNNznWCDLBI/TYmAyDYeJfh2fHlUXV9EqaNKRza blw0k092e638IMCaIvPiCGOZea4FZVnbuDstaHLZTxdGVO+Njc7ecwTeokvkxxpbIUPX DJRQ==
X-Gm-Message-State: AFeK/H17LPdQlUrHMk+y7oLUC/1rO1OhnxsXlOZr56V3WsGH1r7tSIZi6kO0FJ7/UOU24nYDzrRQPaW+paUIIQ==
X-Received: by 10.13.204.206 with SMTP id o197mr2982711ywd.87.1490293519959; Thu, 23 Mar 2017 11:25:19 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.129.154.210 with HTTP; Thu, 23 Mar 2017 11:24:39 -0700 (PDT)
In-Reply-To: <DM2PR21MB009190C73B515AFF6F1BF52C8C3F0@DM2PR21MB0091.namprd21.prod.outlook.com>
References: <E6C9F0E527F94F4692731382340B337846DD1B@DENBGAT9EH2MSX.ww902.siemens.net> <4DD1F233-D659-4F79-9ADA-BC31A49DA653@dukhovni.org> <CABcZeBNu_9EHKWFzWFvtcUZ5GA5SQ8DbjHqEvn4yjBLH6=yuXg@mail.gmail.com> <E6C9F0E527F94F4692731382340B337846DE14@DENBGAT9EH2MSX.ww902.siemens.net> <CABcZeBPfHWJDPWqtb9HcOi1714NF_xhQtLD1MwybAawgm_Xx5g@mail.gmail.com> <DM2PR21MB009190C73B515AFF6F1BF52C8C3F0@DM2PR21MB0091.namprd21.prod.outlook.com>
From: Eric Rescorla <ekr@rtfm.com>
Date: Thu, 23 Mar 2017 11:24:39 -0700
Message-ID: <CABcZeBP6goWGvCnaQw0V2DLvjQVCj=ANTDrwAVKc7x6j+YFzcQ@mail.gmail.com>
To: Andrei Popov <Andrei.Popov@microsoft.com>
Cc: "Fries, Steffen" <steffen.fries@siemens.com>, TLS WG <tls@ietf.org>
Content-Type: multipart/alternative; boundary="001a114e6b3cde5bd5054b69ff76"
Archived-At: <https://mailarchive.ietf.org/arch/msg/tls/jyZNXhJpwTT44fpSLe3cRV9xGeg>
Subject: Re: [TLS] Enforcing stronger server side signature/hash combinations in TLS 1.2
X-BeenThere: tls@ietf.org
X-Mailman-Version: 2.1.22
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, 23 Mar 2017 18:25:31 -0000
On Thu, Mar 23, 2017 at 10:11 AM, Andrei Popov <Andrei.Popov@microsoft.com> wrote: > Ø Note that any client which in fact supports > > Ø SHA-256 with TLS 1.2 but doesn't send signature_algorithms containing > it, > > Ø is noncomformant. It's not clear to me how many such clients in fact > exist. > > > > We saw enough TLS 1.2 clients that are non-compliant in this way that I > made the server-side change to accommodate them. > > Obviously, Martin Rex’s code is one example. > Thanks. That's interesting to know. -Ekr > I’ve also seen a number of embedded/IoT-oriented TLS stacks that had this > defect initially, when they first implemented TLS 1.2, although they were > quick to fix. > > Some of our customers in East Asia reported that the TLS stacks they used > had this defect; when pointed at the RFC, they took the issue to the > corresponding SW vendor(s). > > Overall, a small percentage, but it generated enough support calls that > the server change was worthwhile. > > > > Cheers, > > > > Andrei > > > > *From:* TLS [mailto:tls-bounces@ietf.org] *On Behalf Of *Eric Rescorla > *Sent:* Thursday, March 23, 2017 9:58 AM > *To:* Fries, Steffen <steffen.fries@siemens.com> > *Cc:* TLS WG <tls@ietf.org> > *Subject:* Re: [TLS] Enforcing stronger server side signature/hash > combinations in TLS 1.2 > > > > > > > > On Thu, Mar 23, 2017 at 8:37 AM, Fries, Steffen <steffen.fries@siemens.com> > wrote: > > Hi Erik, > > > > based on your reply my conclusion is that > > - there is no (standard compliant) way for a server to use a > SHA256 based certificate for server side authentication in cases where the > client does not provide the signature_algorithm extension > > Not quite. If the client offers TLS 1.1 or below, then you simply don't > know if it > > will accept SHA-256 and you should send whatever you have. If the client > offers > > TLS 1.2 and no signature_algorithm extension, then you technically are > forbidden > > from sending it a SHA-256 certificate. Note that any client which in fact > supports > > SHA-256 with TLS 1.2 but doesn't send signature_algorithms containing it, > > is noncomformant. It's not clear to me how many such clients in fact exist. > > > > - clients should always use the signature algorithm extension to > ensure the server can apply a certificate with the appropriate crypt > algorithms > > Yes. > > > > -Ekr > > > > > > Best regards > > Steffen > > > > On Thu, Mar 23, 2017 at 7:39 AM, Viktor Dukhovni <ietf-dane@dukhovni.org> > wrote: > > > > On Mar 23, 2017, at 10:31 AM, Fries, Steffen <steffen.fries@siemens.com> > wrote: > > > > According to TLS 1.2 section 7.4.1.4.1. a client may use the > > signature_algorithm extension to signal any combinations the > > client supports, listed in the order of preferences. > > The signature algorithm is primarily about signatures made as part > of the TLS handshake, and not so much signatures in certificates. > > > > This does not seem consistent with https://tools.ietf.org/ > rfcmarkup?doc=5246#section-7.4.2 > > > > "If the client provided a "signature_algorithms" extension, then all > certificates provided by > > the server MUST be signed by a hash/signature algorithm pair that appears > in that extension." > > > > I appreciate that there are people who feel that this rule is bad, and > > to some extent it has been relaxed in 1.3, but I think the text is > > pretty clear here. > > > > > > > If the client does not use this extension, the server must use the > > signature algorithm in combination with SHA1. > > For signing the TLS key exchange, however, it should still present > whatever certificate chain it has, even if that chain employs SHA256. > It is exceedingly unlikely these days that a client will not support > SHA256 signatures in the certificate chain. > > > > Yes, that's generally true. Though a TLS 1.2 client which does not offer > SHA-256 > > in its ClientHello but accepts SHA-256 is broken. So, this should generally > > only happen with TLS 1.1 and below. > > > > > > > > > Unfortunately the server is not allowed to use this extension, otherwise > > he could tell the client his preferences according to his security > policy. > > The protocol (as it should) lacks the additional round-trips necessary for > the server to initiate signature algorithm negotiation. > > > > I'm not sure quite what the OP Is trying to achieve here. For certificates > offered > > by the server, the client just tells you what algorithms it will accept > for no negotiation > > is needed. For certificates offered by the client, the server tells the > client > > what algorithms it will accept in the CertificateRequest. > > https://tools.ietf.org/rfcmarkup?doc=5246#section-7.4.4 > > > > -Ekr > > > _______________________________________________ > TLS mailing list > TLS@ietf.org > https://www.ietf.org/mailman/listinfo/tls > > >
- [TLS] Enforcing stronger server side signature/ha… Fries, Steffen
- Re: [TLS] Enforcing stronger server side signatur… Viktor Dukhovni
- Re: [TLS] Enforcing stronger server side signatur… Eric Rescorla
- Re: [TLS] Enforcing stronger server side signatur… Fries, Steffen
- Re: [TLS] Enforcing stronger server side signatur… Fries, Steffen
- Re: [TLS] Enforcing stronger server side signatur… Martin Rex
- Re: [TLS] Enforcing stronger server side signatur… Andrei Popov
- Re: [TLS] Enforcing stronger server side signatur… Eric Rescorla
- Re: [TLS] Enforcing stronger server side signatur… Eric Rescorla
- Re: [TLS] Enforcing stronger server side signatur… Andrei Popov
- Re: [TLS] Enforcing stronger server side signatur… Martin Rex
- Re: [TLS] Enforcing stronger server side signatur… Eric Rescorla
- Re: [TLS] Enforcing stronger server side signatur… Eric Rescorla
- Re: [TLS] Enforcing stronger server side signatur… Peter Gutmann
- Re: [TLS] Enforcing stronger server side signatur… Peter Gutmann
- Re: [TLS] Enforcing stronger server side signatur… Viktor Dukhovni
- Re: [TLS] Enforcing stronger server side signatur… Martin Thomson
- Re: [TLS] Enforcing stronger server side signatur… Viktor Dukhovni
- Re: [TLS] Enforcing stronger server side signatur… Fries, Steffen
- Re: [TLS] Enforcing stronger server side signatur… Martin Rex
- Re: [TLS] Enforcing stronger server side signatur… Salz, Rich
- Re: [TLS] Enforcing stronger server side signatur… Eric Rescorla
- Re: [TLS] Enforcing stronger server side signatur… Martin Rex
- Re: [TLS] Enforcing stronger server side signatur… Martin Rex
- Re: [TLS] Enforcing stronger server side signatur… Ryan Sleevi
- Re: [TLS] Enforcing stronger server side signatur… Martin Rex
- Re: [TLS] Enforcing stronger server side signatur… Ryan Sleevi
- Re: [TLS] Enforcing stronger server side signatur… Michael StJohns
- Re: [TLS] Enforcing stronger server side signatur… Martin Rex
- Re: [TLS] Enforcing stronger server side signatur… Eric Rescorla