Re: [TLS] RSASSA-PSS in certificates and "signature_algorithms"

Nikos Mavrogiannopoulos <nmav@redhat.com> Tue, 12 September 2017 14:10 UTC

Return-Path: <nmav@redhat.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 AEF00132716 for <tls@ietfa.amsl.com>; Tue, 12 Sep 2017 07:10:54 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -4.201
X-Spam-Level:
X-Spam-Status: No, score=-4.201 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-2.8, RCVD_IN_SORBS_SPAM=0.5, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
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 WM1OAwjf2JFU for <tls@ietfa.amsl.com>; Tue, 12 Sep 2017 07:10:48 -0700 (PDT)
Received: from mail-wr0-f169.google.com (mail-wr0-f169.google.com [209.85.128.169]) (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 BF22F1326DF for <tls@ietf.org>; Tue, 12 Sep 2017 07:10:47 -0700 (PDT)
Received: by mail-wr0-f169.google.com with SMTP id k20so22932214wre.4 for <tls@ietf.org>; Tue, 12 Sep 2017 07:10:47 -0700 (PDT)
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:subject:from:to:date:in-reply-to :references:mime-version:content-transfer-encoding; bh=rNWzF2hpMG7uQYcz469wR7YhhlxWfp53YQ1tp0Hsoas=; b=sMpSwDatwP7yGAbM7hfL5XrRdq11Zy8FuUm6C13b+u48LFVxA9p8Abk48BIu0zzWVC f6oSGn9Fh2RbgueR/Dlnns8tV5nR7Lfqmg5rrc+4EuhVCYBP4c3EUzaaV8doJiBBFnEc fKKVOYyEMqNIH1xdOZ2HpSCqO/uFDsPvwZd40LZc/448TnrLnuKLH3bUbyEnAipkTLH6 2MIod56ruCxHt0Rx3Z3QcS7mxss88G7lXYUsvYwuIZUdSQmwIIxS25UucxcaKp0rIdIF yzlI1rTKdm8B6yBT6QPO+zcI2JMSwXr7Tw+m23wZtSkYTP9aDxVMb8a7HDTTi/LGvf7U wiCA==
X-Gm-Message-State: AHPjjUjkx83NTH9TR2QlnVT0jrL/1nawrhPG5VNQsvvXssmIWxsZTJnp xT18Gt+S5cijBTbRglz6qQ==
X-Google-Smtp-Source: ADKCNb5EqDQVvD4zsC6gYgdKpkS8pSvT2E1lhq10VnWu8pkoN9pvDmAkW9QY6jlYWdC6dCTknNkp1w==
X-Received: by 10.223.166.138 with SMTP id t10mr13772602wrc.64.1505225446142; Tue, 12 Sep 2017 07:10:46 -0700 (PDT)
Received: from dhcp-10-40-1-102.brq.redhat.com (nat-pool-brq-t.redhat.com. [213.175.37.10]) by smtp.gmail.com with ESMTPSA id v78sm7773146wmv.48.2017.09.12.07.10.45 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 12 Sep 2017 07:10:45 -0700 (PDT)
Message-ID: <1505225444.4161.35.camel@redhat.com>
From: Nikos Mavrogiannopoulos <nmav@redhat.com>
To: Dr Stephen Henson <lists@drh-consultancy.co.uk>, tls@ietf.org
Date: Tue, 12 Sep 2017 16:10:44 +0200
In-Reply-To: <cafe5f94-f2f8-98d7-c536-fbc59e94fb97@drh-consultancy.co.uk>
References: <20170908225948.GC31695@al> <CABcZeBNYoqpWx_3V42wut3FUUt3xELv5J5YayvcrhwzJKqgcyg@mail.gmail.com> <cafe5f94-f2f8-98d7-c536-fbc59e94fb97@drh-consultancy.co.uk>
Content-Type: text/plain; charset="UTF-8"
X-Mailer: Evolution 3.24.5 (3.24.5-1.fc26)
Mime-Version: 1.0
Content-Transfer-Encoding: 7bit
Archived-At: <https://mailarchive.ietf.org/arch/msg/tls/qpeefBaAMaEhiFyslCFOzf0NGfc>
Subject: Re: [TLS] RSASSA-PSS in certificates and "signature_algorithms"
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: Tue, 12 Sep 2017 14:10:55 -0000

On Tue, 2017-09-12 at 14:41 +0100, Dr Stephen Henson wrote:
> On 11/09/2017 19:42, Eric Rescorla wrote:
> > Ugh.
> > 
> > Generally, the idea with signature schemes is that they are
> > supposed to reflect
> > both the capabilities of your TLS stack and the capabilities of
> > your PKI
> > verifier [0]. So, yes, if you advertise this it is supposed to
> > work. So, ideally
> > we would just say that it's as Ilari says in his followup.
> > 
> > It seems like there are really two choices:
> > 
> > 1. Only advertise algorithm X if you support algorithm X in both
> > places
> > 2. Invent a new extension whose semantics are "if present, this
> > tells you what
> > the PKI validator accepts, otherwise look at signature schemes"
> > 
> > I hate to be suggesting #2 at this stage in the process, but maybe
> > it's right
> > anyway...
> > 
> 
> It's rather more than just certificate signatures.
> 
> The problem here is that there is no way to indicate an
> implementation supports
> rsaEncryption keys but not RSASSA-PSS keys and the current draft
> requires that
> implementations support both AFAICS.
> 
> RSASSA-PSS keys are pretty rare at the moment. There are some
> complications
> involved with supporting them not present with other key types: more
> complex parameter sets and key restrictions for example.

Right, that is indeed a significant complexity, and unfortunately the
RSASSA-PSS parameters in certificates/keys are quite uniquely in PKIX.
However, these are optional parameters, and one could support RSA-PSS
keys without such parameters/restrictions relatively easily. Moreover,
keys without paramters, are the keys which are typically expected to be
used by TLS. 

That is, because a TLS server would typically sign with whatever
algorithm the client supports and would very rarely be interested to
utilize the security advantages of including the parameters (which,
advantages, are quite unclear even to a crypto expert). Otherwise, a
certificate restricted to SHA-384 and 48-bytes of salt, will not be
able to serve a client which only supports RSASSA-PSS with SHA-256.

As such, it would make sense for TLS 1.3 to recommend no parameters for
such RSASSA-PSS certificates, to ease their deployment.

>  Implementors might feel
> (despite what the draft says) that the added complexity is not
> justified because no one will ever want to use RSASSA-PSS keys.

If an implementation does not support RSASSA-PSS-only keys, it means it
will (as a server) not be able to use separate keys for RSASSA-PSS and
RSA PKCS#1 v1.5 operations, right? That's quite a fundamental
limitation and if it exists in popular implementations it makes the TLS
1.3 move to RSASSA-PSS quite questionable. It may be better to support
RSA PKCS#1 v1.5 in TLS1.3 alongside RSASSA-PSS (for the implementations
that chose to opt-in), rather than forcing a move to RSASSA-PSS without
providing any of the benefits of using it. 

regards,
Nikos