Re: [TLS] TLS v1.2 performance (was Re: TLSv1.2 with DSA client

Juho Vähä-Herttua <juhovh@iki.fi> Fri, 18 February 2011 22:39 UTC

Return-Path: <juhovh@iki.fi>
X-Original-To: tls@core3.amsl.com
Delivered-To: tls@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id CA7BC3A6DFD for <tls@core3.amsl.com>; Fri, 18 Feb 2011 14:39:23 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.299
X-Spam-Level:
X-Spam-Status: No, score=-2.299 tagged_above=-999 required=5 tests=[BAYES_00=-2.599, MIME_8BIT_HEADER=0.3]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 3xfTUYnD9VfI for <tls@core3.amsl.com>; Fri, 18 Feb 2011 14:39:23 -0800 (PST)
Received: from jenni1.inet.fi (mta-out.inet.fi [195.156.147.13]) by core3.amsl.com (Postfix) with ESMTP id ACAFC3A6DB1 for <tls@ietf.org>; Fri, 18 Feb 2011 14:39:22 -0800 (PST)
Received: from vagabond.lan (88.192.41.71) by jenni1.inet.fi (8.5.133) id 4D060B9403200286 for tls@ietf.org; Sat, 19 Feb 2011 00:39:56 +0200
From: Juho Vähä-Herttua <juhovh@iki.fi>
Mime-Version: 1.0 (Apple Message framework v1082)
Content-Type: multipart/signed; boundary="Apple-Mail-5--213467059"; protocol="application/pkcs7-signature"; micalg="sha1"
Date: Sat, 19 Feb 2011 00:39:56 +0200
In-Reply-To: <201102181928.p1IJSThD006475@fs4113.wdf.sap.corp>
To: tls@ietf.org
References: <201102181928.p1IJSThD006475@fs4113.wdf.sap.corp>
Message-Id: <7B07CE79-74A3-4CED-90E9-5910E67E90C7@iki.fi>
X-Mailer: Apple Mail (2.1082)
Subject: Re: [TLS] TLS v1.2 performance (was Re: TLSv1.2 with DSA client
X-BeenThere: tls@ietf.org
X-Mailman-Version: 2.1.9
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/listinfo/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: Fri, 18 Feb 2011 22:39:23 -0000

On 18.2.2011, at 21.28, Martin Rex wrote:
> So this part of rfc-5246 purports to solve a problem that actually
> does not exist in earlier versions of TLS.  The "solution" that
> TLSv1.2 alleges to provides looks more like a cumbersome
> limitation to me.  While there is zero problem of using certificate
> chains with arbitrary mixtures of signature algorithms in TLSv1.1
> and prior, this doesn't work anymore when negotiating TLSv1.2,
> in particular for signature algorithms which can not be represented
> with the code points of TLSv1.2.

This discussion has been going on for quite long, but I just want to mention that I support Martin here and I don't think I have seen a good response yet. I found the same issue a bit weird when I was going through the TLSv1.2 specification, but it wasn't relevant at the time so I just ignored and forgot it.

Forcing the TLS implementation to buffer all handshake messages is one thing that probably a performance problem in TLSv1.2, but it's not a compatibility issue and as someone said fixing it would require releasing TLSv1.3. However I don't see ANY sensible reasons why TLS would care about which signature algorithm is used for signing the actual certificate. As long as the certificate contains the keys necessary to sign the key exchange it should be fine just like it was before.

Yes, it might be possible for a client to for example only support one single hash and one single signature algorithm, which is most likely a combination included in signature_algorithms. In that case, I would support that the server SHOULD choose the certificate chain according to the sent signature_algorithms if possible. However if there is no such certificate chain available, it MUST continue the handshake by sending some valid certificate. The server has no way to know if the client can verify certificate chains outside the defined TLS signature algorithms, therefore it would be plain stupid for the server to abort the handshake just because it has a certificate which is signed with an algorithm not supported by TLS. (especially if both sides can handle it)

I don't think changing this from MUST to SHOULD would cause major compatibility issues, because for TLSv1.0 and TLSv1.1 the clients need to prepare for any kinds of certificates anyway. If someone has actually written code that rejects certificates that don't match the sent signature_algorithms it might cause an error, has anyone on this list written that kind of code or seen it anywhere? Personally I find the meddling with certificate signature hash and type annoying enough that I am inclined to ignore it, even if that means incompatibility....


Juho