Re: [TLS] TLS 1.2 clarification requested

Yoav Nir <> Tue, 01 October 2013 21:37 UTC

Return-Path: <>
Received: from localhost (localhost []) by (Postfix) with ESMTP id D092F21F9FED for <>; Tue, 1 Oct 2013 14:37:45 -0700 (PDT)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -8.999
X-Spam-Status: No, score=-8.999 tagged_above=-999 required=5 tests=[AWL=1.000, BAYES_00=-2.599, J_CHICKENPOX_52=0.6, RCVD_IN_DNSWL_HI=-8]
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id OroNAL0jNjBP for <>; Tue, 1 Oct 2013 14:37:34 -0700 (PDT)
Received: from ( []) by (Postfix) with ESMTP id 6350521F9F50 for <>; Tue, 1 Oct 2013 14:37:26 -0700 (PDT)
Received: from ([]) by (8.13.8/8.13.8) with ESMTP id r91LbO6W015162; Wed, 2 Oct 2013 00:37:24 +0300
X-CheckPoint: {524B4094-0-1B221DC2-1FFFF}
Received: from ([]) by ([]) with mapi id 14.02.0347.000; Wed, 2 Oct 2013 00:37:24 +0300
From: Yoav Nir <>
To: "<>" <>
Thread-Topic: [TLS] TLS 1.2 clarification requested
Thread-Index: Ac6+19Gy7ubypu9bSN6R9OEEKLlUhP//6jQAgAAQwoA=
Date: Tue, 1 Oct 2013 21:37:23 +0000
Message-ID: <>
References: <>
In-Reply-To: <>
Accept-Language: en-US
Content-Language: en-US
x-originating-ip: []
x-kse-antivirus-interceptor-info: protection disabled
Content-Type: text/plain; charset="us-ascii"
Content-ID: <>
Content-Transfer-Encoding: quoted-printable
MIME-Version: 1.0
Cc: "" <>
Subject: Re: [TLS] TLS 1.2 clarification requested
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." <>
List-Unsubscribe: <>, <>
List-Archive: <>
List-Post: <>
List-Help: <>
List-Subscribe: <>, <>
X-List-Received-Date: Tue, 01 Oct 2013 21:37:46 -0000

On Oct 1, 2013, at 11:37 PM, Martin Rex <> wrote:

> Kain, Michael T wrote:
>> I'm trying to understand the TLS 1.2 restrictions and signature
>> algorithms and how they interact.
> The semantics of the TLS signature algorithms extension as specified
> in TLSv1.2 (rfc5246):
> and the specified interaction with the ServerCertificate chain as 
> described in the last paragraph in page 49
> is fubar'ed (as in the ...beyond recognition sense).
> I don't know whether implementations of TLSv1.2 actually do/enforce any
> of that crap, but Murphy's Law says that the implementation that your
> customer/consumer wants to interop with, does so -- and that will
> cause of lot of grey hair in the long run.

No. Murphy's law says that that implementation is a perfect implementation of a misreading of RFC 5246. Except that perfect implementations don't crash so much.

>> Does that affect the hash algorithm of TLS 1.2 - or is that always SHA256?
> Beware !  there are two distinct types of default hash algorithms
> in TLSv1.2:
>   1.  SHA256  for the PRF plus the handshake message hash that goes
>       into the Finished handshake message computation
>   2.  either MD5 or SHA1 **alone** for "digitally_signed struct"
>       as used in the ServerKeyExchange or CertificateVerify
>       handshake messages.
> (2) is a huge step backwards in security from all prior versions of
> TLS and even from SSLv3.  Essentially, a client that is proposing TLSv1.2
> and not including a TLS signature extension, is subjecting itself
> to a downgrade attack that is worse than a fallback reconnect to SSLv3.

How so? Section 7.4.8 says :
                                        RSA keys MAY be used with any
      permitted hash algorithm, subject to restrictions in the
      certificate, if any.

So if the client has an RSA certificate, the signature can be done with SHA-256. Yes, the client has to "advertise" this in a ClientHello extension. What of it?

> The "default" digital signature algorithm is the most ridiculous
> breakage in TLSv1.2.  Had the TLS WG waited for FIPS 186-3 to complete
> then there could have been SHA-256 everywhere in TLSv1.2, resulting
> in less complex and faster code, and more secure implementations.
>> For example, if I've got a server configured with a server certificate
>> signed with SHA256, can it still establish a connection using the
> With implementations of SSLv3 through TLSv1.1, this typically just works.
> rfc5246 would "officially" require both server and client to fatally
> abort the handshake, unless the client allowed the use of a server
> certificate with a sha256WithRSAEncryption signature by including a TLS
> signature extension to that effect in ClientHello -- which is ridiculous.
>> Does the signature algorithm for a certificate affect which Ciphersuites can
>> be negotiated and used?
> I can not currently think of a situation where the signature algorithm
> on the server's certificate would matter.

RFC 4492 said so. I now see that RFC 5246 relaxed that rule, but who reads all the way to appendix A.7, right?

> It is the public key in the server's certificate (plus the keyUsage attribute)
> that determines which key exchange algorithms can be used, and that limits
> the cipher suites from those proposed by the client in ClientHello
> from which the server can choose.

That is the case for TLS 1.2, but for TLS 1.0 and 1.1, using ECDHE requires that the public key in the cert match the signature algorithm.